1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* eval.c (proc_invoke): format the message for localjump_error().

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@3950 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2003-06-16 08:03:03 +00:00
parent 51e7fc687e
commit 401805ec13
2 changed files with 8 additions and 3 deletions

View file

@ -1,3 +1,7 @@
Mon Jun 16 17:02:57 2003 Nobuyoshi Nakada <nobu.nokada@softhome.net>
* eval.c (proc_invoke): format the message for localjump_error().
Mon Jun 16 16:23:56 2003 NAKAMURA Usaku <usa@ruby-lang.org>
* ext/dl/dl.c (rb_dl_callback): use rb_block_proc() instead of

7
eval.c
View file

@ -6995,9 +6995,10 @@ proc_invoke(proc, args, self, klass)
result = prot_tag->retval;
}
else if (orphan) { /* orphan block */
localjump_error("%s from block-closure",
state == TAG_BREAK ? "break" : "return",
prot_tag->retval, state);
char mesg[32];
snprintf(mesg, sizeof mesg, "%s from block-closure",
state == TAG_BREAK ? "break" : "return");
localjump_error(mesg, prot_tag->retval, state);
}
else {
ruby_block->tag->dst = incoming_state;