Issue #7896 has been reported by naruse (Yui NARUSE).

----------------------------------------
Backport #7896: Can't test rb_iter_break with extensions
https://bugs.ruby-lang.org/issues/7896

Author: naruse (Yui NARUSE)
Status: Open
Priority: Normal
Assignee: 
Category: 
Target version: 


If you test rb_iter_break() with some extension library like trunk's ext/-test-/iter/break.c, it will cause SEGV on 1.9.3.
It won't happen on 2.0 because r34369 is accidentally fix it with below patch.

I noticed this because RubySpec added a test for rb_spec_iter (4db31b04954118e66ac1d6353ebf4106cb2b419b) and hit this.

% svn di
Index: vm.c
===================================================================
--- vm.c        (revision 39346)
+++ vm.c        (working copy)
@@ -1370,6 +1370,7 @@
                            *th->cfp->sp++ = (GET_THROWOBJ_VAL(err));
 #endif
                        }
+                       th->state = 0;
                        th->errinfo = Qnil;
                        goto vm_loop_start;
                    }


-- 
http://bugs.ruby-lang.org/