This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] sim: use character classes rather than ranges


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]