Re: branch-1_4 allow C++ on Linux

Eric Blake <[email protected]>
Newsgroups gmane.comp.gnu.m4.patches
Message-ID <[email protected]>
Eric Blake <ebb9 <at> byu.net> writes:

> Well, this isn't a complete patch, but it gets closer.
> 
> 2006-11-11  Eric Blake  <ebb9 <at> byu.net>
> 
> 	One step closer to allowing C++ compilation - don't blindly
> 	convert between char* and unsigned char*.

Missed one.

2006-11-14  Eric Blake  <[email protected]>

	* m4/resyntax.c (m4_regexp_syntax_encode): Avoid bug with signed
	char.

Index: m4/resyntax.c
===================================================================
RCS file: /sources/m4/m4/m4/resyntax.c,v
retrieving revision 1.2
diff -u -r1.2 resyntax.c
--- m4/resyntax.c	26 Sep 2006 13:19:26 -0000	1.2
+++ m4/resyntax.c	14 Nov 2006 19:38:45 -0000
@@ -93,8 +93,8 @@
     {
       if ((*p == ' ') || (*p == '-'))
 	*p = '_';
-      else if (islower (*p))
-	*p = toupper (*p);
+      else if (islower (to_uchar (*p)))
+	*p = toupper (to_uchar (*p));
     }
 
   for (resyntax = m4_resyntax_map; resyntax->spec != NULL; ++resyntax)
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.