[#42] Re: possible bug: stack dump with <<-String, #{...} and large loops — ts <decoux@...>

32 messages 2002/05/25
[#43] Re: possible bug: stack dump with <<-String, #{...} and large loops — nobu.nokada@... 2002/05/26

Hi,

[#45] Re: possible bug: stack dump with <<-String, #{...} and large loops — ts <decoux@...> 2002/05/26

>>>>> "n" == nobu nokada <nobu.nokada@softhome.net> writes:

[#46] Re: possible bug: stack dump with <<-String, #{...} and large loops — nobu.nokada@... 2002/05/26

Hi,

[#47] Re: possible bug: stack dump with <<-String, #{...} and large loops — ts <decoux@...> 2002/05/26

>>>>> "n" == nobu nokada <nobu.nokada@softhome.net> writes:

[#48] Re: possible bug: stack dump with <<-String, #{...} and large loops — ts <decoux@...> 2002/05/26

>>>>> "t" == ts <decoux@moulon.inra.fr> writes:

[#49] Re: possible bug: stack dump with <<-String, #{...} and large loops — nobu.nokada@... 2002/05/27

Hi,

[#50] Re: possible bug: stack dump with <<-String, #{...} and large loops — ts <decoux@...> 2002/05/27

>>>>> "n" == nobu nokada <nobu.nokada@softhome.net> writes:

[#51] Re: possible bug: stack dump with <<-String, #{...} and large loops — nobu.nokada@... 2002/05/27

Hi,

[#52] Re: possible bug: stack dump with <<-String, #{...} and large loops — ts <decoux@...> 2002/05/27

>>>>> "n" == nobu nokada <nobu.nokada@softhome.net> writes:

[#53] Re: possible bug: stack dump with <<-String, #{...} and large loops — nobu.nokada@... 2002/05/27

Hi,

[#54] Re: possible bug: stack dump with <<-String, #{...} and large loops — ts <decoux@...> 2002/05/27

>>>>> "n" == nobu nokada <nobu.nokada@softhome.net> writes:

[#55] Re: possible bug: stack dump with <<-String, #{...} and large loops — nobu.nokada@... 2002/05/27

Hi,

[#56] Re: possible bug: stack dump with <<-String, #{...} and large loops — ts <decoux@...> 2002/05/27

>>>>> "n" == nobu nokada <nobu.nokada@softhome.net> writes:

[#57] Re: possible bug: stack dump with <<-String, #{...} and large loops — nobu.nokada@... 2002/05/28

Hi,

[#65] Re: possible bug: stack dump with <<-String, #{...} and large loops — ts <decoux@...> 2002/05/28

>>>>> "n" == nobu nokada <nobu.nokada@softhome.net> writes:

[#84] Re: possible bug: stack dump with <<-String, #{...} and large loops — nobu.nokada@... 2002/05/29

Hi,

[#92] Re: possible bug: stack dump with <<-String, #{...} and large loops — ts <decoux@...> 2002/05/29

>>>>> "n" == nobu nokada <nobu.nokada@softhome.net> writes:

[#67] The warns-a-thon continues... — Sean Chittenden <sean@...>

I'm feeling left out in this race to clobber warnings!!! Attached are

19 messages 2002/05/28

[#104] Re: possible bug: stack dump with <<-String, #{...} and large loops — ts <decoux@...>

>>>>> "n" == nobu nokada <nobu.nokada@softhome.net> writes:

29 messages 2002/05/30
[#105] Re: possible bug: stack dump with <<-String, #{...} and large loops — nobu.nokada@... 2002/05/30

Hi,

[#125] Re: possible bug: stack dump with <<-String, #{...} and large loops — ts <decoux@...> 2002/06/04

>>>>> "n" == nobu nokada <nobu.nokada@softhome.net> writes:

[#126] Re: possible bug: stack dump with <<-String, #{...} and large loops — nobu.nokada@... 2002/06/04

Hi,

[#127] Re: possible bug: stack dump with <<-String, #{...} and large loops — ts <decoux@...> 2002/06/04

>>>>> "n" == nobu nokada <nobu.nokada@softhome.net> writes:

[#130] Re: possible bug: stack dump with <<-String, #{...} and large loops — nobu.nokada@... 2002/06/04

Hi,

[#132] Re: possible bug: stack dump with <<-String, #{...} and large loops — nobu.nokada@... 2002/06/05

Hi,

[#134] Re: possible bug: stack dump with <<-String, #{...} and large loops — ts <decoux@...> 2002/06/05

>>>>> "n" == nobu nokada <nobu.nokada@softhome.net> writes:

Re: The warns-a-thon continues...

From: Sean Chittenden <sean@...>
Date: 2002-05-29 04:20:35 UTC
List: ruby-core #87
> > > And, why did you include <ctype.h> in util.c?
> > 
> > isdigit() is in ctyle.h.  Just another way of quieting -Wall during
> > the build.  -sc
> 
> Certainly.
> 
> $ nm -g i686-linux/util.o | grep is
>          U isdigit
>          U isspace
> 
> $ grep -n '\<is[a-z][a-z]*(' util.c
> 751:    while (isspace(*p)) {
> 773:	if (!isdigit(c)) {
> 851:	while (isdigit(*p)) {
> 
> Should be ISDIGIT() and ISSPACE()?

Yes.  ctype.h still needs to be included.  I'm a very BSD UNIX centric
guy, so I don't know if that exists on MS or other *NIX's and needs a
special test.  Does the attached look good?  -sc

-- 
Sean Chittenden

Attachments (1)

patch (1.11 KB, text/x-diff)
Index: util.c
===================================================================
RCS file: /src/ruby/util.c,v
retrieving revision 1.26
diff -u -r1.26 util.c
--- util.c	2002/05/28 18:11:07	1.26
+++ util.c	2002/05/29 04:18:51
@@ -748,7 +748,7 @@
      */
 
     p = string;
-    while (isspace(*p)) {
+    while (ISSPACE(*p)) {
 	p += 1;
     }
     if (*p == '-') {
@@ -770,7 +770,7 @@
     decPt = -1;
     for (mantSize = 0; ; mantSize += 1) {
 	c = *p;
-	if (!isdigit(c)) {
+	if (!ISDIGIT(c)) {
 	    if ((c != '.') || (decPt >= 0)) {
 		break;
 	    }
@@ -848,7 +848,7 @@
 	    }
 	    expSign = FALSE;
 	}
-	while (isdigit(*p)) {
+	while (ISDIGIT(*p)) {
 	    exp = exp * 10 + (*p - '0');
 	    p += 1;
 	}
Index: ruby.h
===================================================================
RCS file: /src/ruby/ruby.h,v
retrieving revision 1.66
diff -u -r1.66 ruby.h
--- ruby.h	2002/05/14 06:22:26	1.66
+++ ruby.h	2002/05/29 04:18:51
@@ -34,6 +34,7 @@
 #include <stddef.h>
 #include <stdio.h>
 
+#include <ctype.h>
 /* need to include <ctype.h> to use these macros */
 #ifndef ISPRINT
 #define ISASCII(c) isascii((unsigned char)(c))

In This Thread