From 7d29a851872fb9e37592cd9f3870494d3b2f7088 Mon Sep 17 00:00:00 2001 From: Torsten Ruger Date: Wed, 28 Dec 2016 18:25:14 +0200 Subject: [PATCH] remove legacy :int type --- lib/register/register_value.rb | 2 -- test/typed/expressions/test_ops.rb | 4 ++-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/lib/register/register_value.rb b/lib/register/register_value.rb index 983460c5..f37359b1 100644 --- a/lib/register/register_value.rb +++ b/lib/register/register_value.rb @@ -10,8 +10,6 @@ module Register raise "wrong type for register init #{r}" unless r.is_a? Symbol raise "double r #{r}" if r.to_s[0,1] == "rr" raise "not reg #{r}" unless self.class.look_like_reg r - type = :Integer if type == :int - raise "Legacy type error, should be class name not ref" if (type == :ref) @type = type @symbol = r @value = value diff --git a/test/typed/expressions/test_ops.rb b/test/typed/expressions/test_ops.rb index 1492aaa7..3a462c9d 100644 --- a/test/typed/expressions/test_ops.rb +++ b/test/typed/expressions/test_ops.rb @@ -32,13 +32,13 @@ module Register end def test_field_int - add_space_field(:bro,:int) + add_space_field(:bro,:Integer) @input = s(:operator_value, :+, s(:field_access,s(:receiver, s(:name, :self)), s(:field, s(:name, :bro))), s(:int, 3)) check end def test_int_field - add_space_field(:bro,:int) + add_space_field(:bro,:Integer) @input = s(:operator_value, :+, s(:int, 3), s(:field_access, s(:receiver, s(:name, :self)), s(:field,s(:name, :bro)))) check end