still finding index errors

This commit is contained in:
Torsten Ruger
2015-10-27 18:45:56 +02:00
parent 444ad75e1e
commit 79cf59c4e2
3 changed files with 7 additions and 2 deletions

View File

@ -23,6 +23,7 @@ module Register
@array = array
@index = index
@register = register
raise "index 0 " if index == 0
raise "not integer #{index}" unless index.is_a? Numeric
raise "Not register #{register}" unless RegisterValue.look_like_reg(register)
raise "Not register #{array}" unless RegisterValue.look_like_reg(array)