File tree Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Expand file tree Collapse file tree 1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -13,11 +13,14 @@ class InstructionSequence
1313 # pass a serialized iseq to Ruby and have it return a
1414 # RubyVM::InstructionSequence object.
1515 ISEQ_LOAD =
16- Fiddle ::Function . new (
17- Fiddle ::Handle ::DEFAULT [ "rb_iseq_load" ] ,
18- [ Fiddle ::TYPE_VOIDP ] * 3 ,
19- Fiddle ::TYPE_VOIDP
20- )
16+ begin
17+ Fiddle ::Function . new (
18+ Fiddle ::Handle ::DEFAULT [ "rb_iseq_load" ] ,
19+ [ Fiddle ::TYPE_VOIDP ] * 3 ,
20+ Fiddle ::TYPE_VOIDP
21+ )
22+ rescue NameError
23+ end
2124
2225 # This object is used to track the size of the stack at any given time. It
2326 # is effectively a mini symbolic interpreter. It's necessary because when
@@ -141,6 +144,7 @@ def length
141144 end
142145
143146 def eval
147+ raise "Unsupported platform" if ISEQ_LOAD . nil?
144148 compiled = to_a
145149
146150 # Temporary hack until we get these working.
You can’t perform that action at this time.
0 commit comments