remove dead code
This commit is contained in:
parent
c5ec532616
commit
be79388cc5
@ -7,10 +7,6 @@ module Mom
|
||||
def to_risc(m)
|
||||
Risc::Label.new(self.class.name, self.class.name + "_todo")
|
||||
end
|
||||
# implement flatten as noop to avoid condition
|
||||
def flatten( options = {} )
|
||||
return self
|
||||
end
|
||||
end
|
||||
|
||||
# A label with a name
|
||||
|
@ -21,8 +21,9 @@ end
|
||||
module MomCompile
|
||||
include CompilerHelper
|
||||
|
||||
def compile_first_method input
|
||||
def compile_first_method( input )
|
||||
# works a lot like Vool.ruby_to_vool
|
||||
# but here we return the intermediate mom instructions that are otherwise not available
|
||||
statements = Vool::RubyCompiler.compile as_test_main( input )
|
||||
statements = statements.normalize
|
||||
res = statements.create_objects
|
||||
@ -33,10 +34,6 @@ module MomCompile
|
||||
res
|
||||
end
|
||||
|
||||
def compile_first_method_flat(input)
|
||||
compile_first_method(input).flatten
|
||||
end
|
||||
|
||||
def check_array( should , is )
|
||||
index = 0
|
||||
test = is
|
||||
|
@ -7,7 +7,7 @@ module Vool
|
||||
|
||||
def setup
|
||||
Risc.machine.boot
|
||||
@ins = compile_first_method_flat( "a = 5; a.mod4")
|
||||
@ins = compile_first_method( "a = 5; a.mod4")
|
||||
end
|
||||
def test_check_type
|
||||
assert_equal NotSameCheck , @ins.next.class , @ins
|
||||
|
Loading…
Reference in New Issue
Block a user