Skip to content

Commit

Permalink
Better fix for optimized specialization for Struct.
Browse files Browse the repository at this point in the history
Resolves #3388 (in a better way)
  • Loading branch information
jemc committed May 3, 2015
1 parent 20d0317 commit 8c898e7
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion kernel/delta/struct.rb
Expand Up @@ -92,7 +92,10 @@ def length
CODE

begin
module_eval code
mod = Module.new do
module_eval code
end
include mod
rescue SyntaxError
# SyntaxError means that something is wrong with the
# specialization code. Just eat the error and don't specialize.
Expand Down

0 comments on commit 8c898e7

Please sign in to comment.