This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] sim: use character classes rather than ranges
- From: "Joseph S. Myers" <joseph at codesourcery dot com>
- To: Mike Frysinger <vapier at gentoo dot org>
- Cc: gdb-patches at sourceware dot org
- Date: Mon, 19 Mar 2012 11:52:08 +0000 (UTC)
- Subject: Re: [PATCH] sim: use character classes rather than ranges
- References: <1332132828-4576-1-git-send-email-vapier@gentoo.org>
On Mon, 19 Mar 2012, Mike Frysinger wrote:
> A-Z ranges don't work in all locales, so use character classes instead.
Are these patterns really meant to depend on the user's locale (and
support locale-specific letters) or are they related to the checked-in
source code (in which case they should support just ASCII letters and
digits - either the relevant program should be run in the C locale, or as
in GCC's option-handling awk scripts the full sets of letters and digits
should be given explicitly somewhere)?
(Using character classes like you do is fine - *if* either the user's
locale is correct for this code or the programs explicitly run in the C
locale.)
--
Joseph S. Myers
joseph@codesourcery.com