Method: ExecJS::RubyRacerRuntime::Context#call
- Defined in:
- lib/execjs/ruby_racer_runtime.rb
#call(properties, *args) ⇒ Object
41 42 43 44 45 46 47 48 49 50 51 52 53 |
# File 'lib/execjs/ruby_racer_runtime.rb', line 41 def call(properties, *args) lock do begin unbox @v8_context.eval(properties).call(*args) rescue ::V8::JSError => e if e.value["name"] == "SyntaxError" raise RuntimeError, e.value.to_s else raise ProgramError, e.value.to_s end end end end |