aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog6
-rw-r--r--parse.y2
2 files changed, 4 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index 07ec4aad3a..88d1918760 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,7 +1,7 @@
-Thu Oct 15 16:57:38 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
+Thu Oct 15 18:26:12 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
- * parse.y (rb_intern3): check symbol table overflow.
- [ruby-core:26092]
+ * parse.y (rb_intern3): check symbol table overflow before generate
+ next id. [ruby-core:26092]
Thu Oct 15 15:14:15 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
diff --git a/parse.y b/parse.y
index 4005e7265f..ceaeed29a4 100644
--- a/parse.y
+++ b/parse.y
@@ -9498,7 +9498,7 @@ rb_intern3(const char *name, long len, rb_encoding *enc)
mbstr:;
}
new_id:
- if (!(global_symbols.last_id << (ID_SCOPE_SHIFT+RUBY_SPECIAL_SHIFT))) {
+ if (global_symbols.last_id >= ~(ID)0 >> (ID_SCOPE_SHIFT+RUBY_SPECIAL_SHIFT)) {
if (len > 20) {
rb_raise(rb_eRuntimeError, "symbol table overflow (symbol %.20s...)",
name);