Post Reply 
HP-42S / Free42 Extension for Visual Studio Code
11-07-2018, 04:41 PM
Post: #13
RE: HP-42S / Free42 Extension for Visual Studio Code
(11-07-2018 09:23 AM)Heilingbrunner Wrote:  Why do we need line numbers in the code ?

While editing a file in vscode I don't care about line numbers.
The same holds if I load a .raw file into an emulator.
However when I enter a program manually into a real calculator it helps to have line numbers.
If I miss a command it helps to find the error.

Quote:The VSC editor already shows line numbers.

True. But when the x-Byte Prgm line is generated it is off by one.

HP-42S
Code:
00 { 20-Byte Prgm }
01▸LBL "TREE"
02 X<>Y
03 -
04 LASTX
05 X↑2
06 1ᴇ4
07 +
08 SQRT
09 ÷
10 ×
11 END

Visual Studio Code
Code:
 1    { 23-Byte Prgm }
 2    LBL "TREE"
 3    X<>Y
 4    -
 5    LASTX
 6    X↑2
 7    1ᴇ4
 8    +
 9    SQRT
10    ÷
11    ×
12    END

Cheers
Thomas
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: HP-42S / Free42 Extension for Visual Studio Code - Thomas Klemm - 11-07-2018 04:41 PM



User(s) browsing this thread: 1 Guest(s)