handle range starting at 0 (fixes #30)
This commit is contained in:
parent
e97964dd5c
commit
657a92e84e
1 changed files with 2 additions and 0 deletions
|
|
@ -102,6 +102,8 @@ class Command
|
|||
if off1?
|
||||
address1 += @parseOffset(off1)
|
||||
|
||||
address1 = 0 if address1 is -1
|
||||
|
||||
if address1 < 0 or address1 > lastLine
|
||||
throw new CommandError('Invalid range')
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue