fold last of the virtual into register

This commit is contained in:
Torsten Ruger
2015-10-22 18:16:29 +03:00
parent f658ecf425
commit dcbd3c7091
67 changed files with 161 additions and 227 deletions

View File

@ -24,7 +24,7 @@ module Parfait
# in a non-booting version this should map to _add_singleton_method
# def add_function function
# raise "not a function #{function}" unless function.is_a? Virtual::Function
# raise "not a function #{function}" unless function.is_a? Register::Function
# raise "syserr " unless function.name.is_a? Symbol
# self.functions << function
# end

View File

@ -13,7 +13,7 @@ module Parfait
# known local variable names
# executable code
# ps, the compiler injects its own info, see Virtual::MethodSource
# ps, the compiler injects its own info, see Register::MethodSource
class Method < Object

View File

@ -2,7 +2,7 @@ module Parfait
class Variable < Object
def initialize type , name , value = nil
raise "not type #{type}" unless Virtual.machine.space.get_class_by_name(type)
raise "not type #{type}" unless Register.machine.space.get_class_by_name(type)
self.type , self.name , self.value = type , name , value
self.value = 0 if self.type == :Integer and value == nil
raise "must give name for variable" unless name

View File

@ -16,7 +16,7 @@ module Parfait
class Word < Object
# initialize with length. For now we try to keep all non-parfait (including String) out
# String will contain spaces for non-zero length
# Virtual provides methods to create Parfait objects from ruby
# Register provides methods to create Parfait objects from ruby
def initialize len
super()
raise "Must init with int, not #{len.class}" unless len.kind_of? Fixnum