2014-05-02 08:02:25 +03:00
|
|
|
module Vm
|
|
|
|
module Kernel
|
2014-05-03 15:13:44 +03:00
|
|
|
def self.start
|
|
|
|
#TODO extract args into array of strings
|
2014-05-03 18:51:47 +03:00
|
|
|
Machine.instance.main_entry
|
2014-05-03 15:13:44 +03:00
|
|
|
end
|
|
|
|
def self.exit
|
|
|
|
# Machine.exit swi 0
|
2014-05-03 18:51:47 +03:00
|
|
|
Machine.instance.main_exit
|
2014-05-03 15:13:44 +03:00
|
|
|
end
|
2014-05-03 18:51:47 +03:00
|
|
|
def self.puts string
|
|
|
|
# should unwrap from string to char*
|
2014-05-05 09:35:40 +03:00
|
|
|
Machine.instance.puts string
|
2014-05-02 08:02:25 +03:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|