From 6c2ce66bfcce96ab3b2a5227e2f904598aa2de41 Mon Sep 17 00:00:00 2001 From: Torsten Ruger Date: Tue, 10 Nov 2015 11:48:53 +0200 Subject: [PATCH] fix old warning --- lib/register/register_value.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/register/register_value.rb b/lib/register/register_value.rb index a09a0932..b41c6dec 100644 --- a/lib/register/register_value.rb +++ b/lib/register/register_value.rb @@ -10,7 +10,8 @@ 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 - raise "Legacy type error, should be class" if (type == :int) or (type == :ref) + type = :Integer if type == :int + raise "Legacy type error, should be class name not ref" if (type == :ref) @type = type @symbol = r @value = value