Scanner.st
changeset 1191 47011122e30e
parent 1181 6e8a54535097
child 1194 bc4172d26877
--- a/Scanner.st	Fri Sep 28 17:54:00 2001 +0200
+++ b/Scanner.st	Mon Oct 01 22:53:21 2001 +0200
@@ -1342,11 +1342,14 @@
             string := ''.
             [nextChar notNil 
              and:[nextChar isLetterOrDigit 
-                  or:[allowUnderscoreInIdentifier == true
-                      and:[nextChar == $_]]
+                  or:[allowUnderscoreInIdentifier == true and:[nextChar == $_]]
                  ]
             ] whileTrue:[
-                part := source nextAlphaNumericWord.
+                nextChar == $_ ifTrue:[
+                    part := nil.
+                ] ifFalse:[
+                    part := source nextAlphaNumericWord.
+                ].
                 part notNil ifTrue:[
                     string := string , part.
                 ].
@@ -2126,6 +2129,6 @@
 !Scanner class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libcomp/Scanner.st,v 1.125 2001-09-07 15:09:25 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libcomp/Scanner.st,v 1.126 2001-10-01 20:53:21 cg Exp $'
 ! !
 Scanner initialize!