minor send fixes
This commit is contained in:
parent
3e46dcda4e
commit
eb57eb4d41
@ -36,7 +36,7 @@ module Virtual
|
|||||||
|
|
||||||
class Machine
|
class Machine
|
||||||
|
|
||||||
FIRST_PASS = "Virtual::SendImplementation"
|
FIRST_PASS = "Virtual::GetImplementation"
|
||||||
LAST_PASS = "Virtual::SetOptimisation"
|
LAST_PASS = "Virtual::SetOptimisation"
|
||||||
|
|
||||||
def initialize
|
def initialize
|
||||||
|
@ -13,5 +13,4 @@ module Virtual
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
Virtual.machine.add_pass "Virtual::GetImplementation"
|
|
||||||
end
|
end
|
||||||
|
@ -44,7 +44,7 @@ int foo()
|
|||||||
end
|
end
|
||||||
foo()
|
foo()
|
||||||
HERE
|
HERE
|
||||||
@output = [[Virtual::MethodEnter , Virtual::NewMessage, Virtual::Set, Virtual::Set, Virtual::MessageSend],
|
@output = [[Virtual::MethodEnter , Virtual::NewMessage, Virtual::Set, Virtual::Set, Virtual::MethodCall],
|
||||||
[Virtual::MethodReturn]]
|
[Virtual::MethodReturn]]
|
||||||
check
|
check
|
||||||
end
|
end
|
||||||
|
@ -9,7 +9,7 @@ int foo(int x)
|
|||||||
int a = 5
|
int a = 5
|
||||||
return a
|
return a
|
||||||
end
|
end
|
||||||
3.foo( 4 )
|
foo( 4 )
|
||||||
HERE
|
HERE
|
||||||
@expect = [ Virtual::Return ]
|
@expect = [ Virtual::Return ]
|
||||||
check
|
check
|
||||||
|
@ -64,6 +64,7 @@ class TestPuts < MiniTest::Test
|
|||||||
"GetSlot" , "RegisterTransfer" ,"GetSlot" , "GetSlot","GetSlot",
|
"GetSlot" , "RegisterTransfer" ,"GetSlot" , "GetSlot","GetSlot",
|
||||||
"FunctionReturn" , "RegisterTransfer" , "Syscall" , "NilClass"].each_with_index do |name , index|
|
"FunctionReturn" , "RegisterTransfer" , "Syscall" , "NilClass"].each_with_index do |name , index|
|
||||||
got = ticks(1)
|
got = ticks(1)
|
||||||
|
#puts "TICK #{index}"
|
||||||
assert got.class.name.index(name) , "Wrong class for #{index+1}, expect #{name} , got #{got}"
|
assert got.class.name.index(name) , "Wrong class for #{index+1}, expect #{name} , got #{got}"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user