remove unused variable class

This commit is contained in:
Torsten Ruger 2016-12-15 19:43:53 +02:00
parent dc56274940
commit 886220d388
3 changed files with 0 additions and 21 deletions

View File

@ -132,7 +132,6 @@ module Register
:TypedMethod => {:name => :Word, :source => :Object, :instructions => :Object, :binary => :Object,
:arguments => :Type , :for_type => :Type, :locals => :Type } ,
:Value => {},
:Variable => {:value_type => :Class, :name => :Word , :value => :Object}
}
end

View File

@ -12,7 +12,6 @@ require_relative "parfait/word"
require_relative "parfait/binary_code"
require_relative "parfait/typed_method"
require_relative "parfait/meta_class"
require_relative "parfait/variable"
require_relative "parfait/dictionary"
require_relative "parfait/type"
require_relative "parfait/message"

View File

@ -1,19 +0,0 @@
module Parfait
class Variable < Object
def initialize type , name , value = nil
raise "not type #{type}(#{type.class})" unless Register.machine.space.get_class_by_name(type)
self.value_type , self.name , self.value = type , name , value
self.value = 0 if self.value_type == :Integer and value == nil
raise "must give name for variable" unless name
end
attributes [:value_type , :name, :value]
def to_s
"Variable(#{self.value_type} ,#{self.name})"
end
def inspect
to_s
end
end
end