Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Use rb_rescue2 to catch all exceptions instead of rb_rescue which onl…

…y catches StandardError

git-svn-id: svn://rubyforge.org/var/svn/tcl/trunk@10 017b7ecb-b1d0-4998-98d6-e9014aaf4887
  • Loading branch information...
commit 3f92d94caaeb36aeabd4f987df3a9e05d2a95595 1 parent fe5c3e6
@sstephenson sstephenson authored
Showing with 3 additions and 7 deletions.
  1. +2 −1  TODO
  2. +0 −5 script/console
  3. +1 −1  src/tcl.c
View
3  TODO
@@ -1,3 +1,4 @@
* Tcl::Interp#to_tcl should account for interpreter aliases (see http://wiki.tcl.tk/8766) and namespaces.
-* ConsoleInterp#exit crashes with "DeleteInterpProc called with active evals".
+* Implement ConsoleInterp#exit.
+
View
5 script/console
@@ -5,7 +5,6 @@ require File.join(File.dirname(__FILE__), *%w".. lib tcl")
class ConsoleInterp < Tcl::Interp
def initialize
super
- expose :exit
expose :ruby_eval
end
@@ -13,10 +12,6 @@ class ConsoleInterp < Tcl::Interp
Kernel.eval(script)
end
- def tcl_exit
- exit
- end
-
protected
def expose(name)
_!(:interp, :alias, nil, name, nil, :interp_send, name)
View
2  src/tcl.c
@@ -55,7 +55,7 @@ static int rb_tcl_interp_send(ClientData clientData, Tcl_Interp *interp, int obj
VALUE args = rb_ary_new3(2, (VALUE) clientData, interp_receive_args);
- if (rb_rescue(rb_tcl_interp_send_begin, args, rb_tcl_interp_send_rescue, args) == Qtrue) {
+ if (rb_rescue2(rb_tcl_interp_send_begin, args, rb_tcl_interp_send_rescue, args, rb_eException) == Qtrue) {
return TCL_RETURN;
} else {
return TCL_ERROR;
Please sign in to comment.
Something went wrong with that request. Please try again.