Joined: 16/09/2019 Location: United KingdomPosts: 4050
Posted: 12:58pm 03 Mar 2022
If the manual is correct then they aren't relative:
RESTORE [line] Resets the line and position counters for the READ statement. If 'line' is specified the counters will be reset to the beginning of the specified line. 'line' can be a line number or label or a variable with these values. If 'line' is not specified the counters will be reset to the start of the program.
Relative would look like:
RESTORE [line_num|label], line_offset
or possibly:
RESTORE RELATIVE line_offset
where any of 'line_num', 'label' and 'line_offset' could be literals or variables.
Which I think would also provide a way to deal with the issue, provided you were careful in the arrangement of your DATA statements and were prepared to live with it all going haywire if you decided to add some comments or additional lines within the DATA statements.
I really was quite happy with CSUB and PEEK(CFUNADDR cfun).