2015-11-30 15:09:12 +01:00
|
|
|
require "ast/sexp"
|
|
|
|
|
2017-01-19 08:02:29 +01:00
|
|
|
module Risc
|
2015-11-30 15:09:12 +01:00
|
|
|
module Builtin
|
|
|
|
class Space
|
|
|
|
module ClassMethods
|
|
|
|
include AST::Sexp
|
|
|
|
|
|
|
|
# main entry point, ie __init__ calls this
|
|
|
|
# defined here as empty, to be redefined
|
|
|
|
def main context
|
2017-01-17 20:23:58 +01:00
|
|
|
compiler = Vm::MethodCompiler.create_method(:Space , :main ).init_method
|
2015-11-30 15:09:12 +01:00
|
|
|
return compiler.method
|
|
|
|
end
|
|
|
|
|
|
|
|
end
|
|
|
|
extend ClassMethods
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
require_relative "integer"
|
|
|
|
require_relative "object"
|
|
|
|
require_relative "kernel"
|
|
|
|
require_relative "word"
|