From a8e635d77ac18ed5cb399df97c9c8f003fe39255 Mon Sep 17 00:00:00 2001 From: Markus Schirp Date: Fri, 27 Jul 2012 13:32:57 +0200 Subject: [PATCH] Simplify code loading steps and set default file --- lib/mutant/loader.rb | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/lib/mutant/loader.rb b/lib/mutant/loader.rb index e64fda4d..d22324cd 100644 --- a/lib/mutant/loader.rb +++ b/lib/mutant/loader.rb @@ -40,18 +40,8 @@ module Mutant # def initialize(root) @root = root - root.file = "foo" - Rubinius.run_script(script.compiled_method) - end - - # Return compiled method script for node - # - # @return [Rubinius::CompiledMethod::Script] - # - # @api private - # - def script - compiled_code.create_script + root.file ||= '(mutant)' + Rubinius.run_script(compiled_code) end # Return compiled code for node