stdlib/opal-parser.rb in opal-1.3.2 vs stdlib/opal-parser.rb in opal-1.4.0.alpha1

- old
+ new

@@ -5,11 +5,11 @@ require 'opal/erb' require 'opal/version' module Kernel def eval(str, binding = nil, file = nil, line = nil) - str = Opal.coerce_to!(str, String, :to_str) + str = ::Opal.coerce_to!(str, String, :to_str) default_eval_options = { file: file || '(eval)', eval: true } compiling_options = __OPAL_COMPILER_CONFIG__.merge(default_eval_options) code = `Opal.compile(str, compiling_options)` if binding binding.js_eval(code) @@ -33,10 +33,10 @@ end %x{ Opal.compile = function(str, options) { try { - str = #{Opal.coerce_to!(`str`, String, :to_str)} + str = #{::Opal.coerce_to!(`str`, String, :to_str)} if (options) options = Opal.hash(options); return Opal.Opal.$compile(str, options); } catch (e) { if (e.$$class === Opal.Opal.SyntaxError) {