diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | eval.c | 13 |
2 files changed, 17 insertions, 2 deletions
@@ -1,3 +1,9 @@ +Thu May 12 01:23:55 2005 Nobuyoshi Nakada <nobu@ruby-lang.org> + + * eval.c (unknown_node): ignore broken NODE to get rid of accessing + possibly inaccessible address. fixed: [ruby-dev:26122] + should emit more useful information like [ruby-dev:26126], though. + Wed May 11 15:58:39 2005 Yukihiro Matsumoto <matz@ruby-lang.org> * eval.c (break_jump): break should not cross functions. @@ -2760,6 +2760,15 @@ class_prefix(self, cpath) NORETURN(static void return_jump _((VALUE))); NORETURN(static void break_jump _((VALUE))); +NORETURN(static void unknown_node _((NODE *))); + +static void +unknown_node(node) + NODE *volatile node; +{ + ruby_current_node = 0; + rb_bug("unknown node type %d", nd_type(node)); +} static VALUE rb_eval(self, n) @@ -3993,7 +4002,7 @@ rb_eval(self, n) break; default: - rb_bug("unknown node type %d", nd_type(node)); + unknown_node(node); } finish: CHECK_INTS; @@ -5842,7 +5851,7 @@ rb_call0(klass, recv, id, oid, argc, argv, body, nosuper) break; default: - rb_bug("unknown node type %d", nd_type(body)); + unknown_node(body); break; } POP_FRAME(); |