Applied, thanks. Daniel Grunblatt.
On Tue, 23 Jul 2002, Andy Dougherty wrote: > # New Ticket Created by Andy Dougherty > # Please include the string: [perl #15401] > # in the subject line of all future correspondence about this issue. > # <URL: http://rt.perl.org/rt2/Ticket/Display.html?id=15401 > > > > This patch eliminates 69 warnings of the form > > debug.c:96: warning: subscript has type `char' > > from gcc-2.8.1 on Solaris 8. > > The isXXXX() functions take 'int' arguments (since they must operate > either on characters or EOF). On Solaris 8, under the default > compilation conditions for me with gcc, they are implemented as > lookup-tables, with the 'character' used as the index. Hence normal > type promotion isn't performed and the 'subscript has type char' > warning gets issued. > > Eventually, parrot may have to face some of the same issues with the > isXXXX() functions that perl5 did, and it may be appropriate to set up > various isALPHA() etc. macros or functions. See perl5's handy.h, > particularly the section starting with > > /* > * Character classes. > * > * Unfortunately, the introduction of locales means that we > * can't trust isupper(), etc. to tell the truth. And when > * it comes to /\w+/ with tainting enabled, we *must* be able > * to trust our character classes. > * > * Therefore, the default tests in the text of Perl will be > * independent of locale. Any code that wants to depend on > * the current locale will use the tests that begin with > "lc". > */ > > This is probably not a big issue in debug.c, however, so the following > should suffice for now. > >