remy / vscode-nextbasic

VS Code tools for NextBASIC
https://marketplace.visualstudio.com/items?itemName=remysharp.nextbasic
8 stars 2 forks source link

Should .....; pause error? as it needs :? #28

Closed Tailzer closed 3 years ago

Tailzer commented 3 years ago

Not sure if this is a bug or feature request? or out of scope?

I made a typo and the extension didn't pick it up?

code example: 330 PRINT INK 2; AT 19,12; CHR$ 147; CHR$ 145; CHR$ 147; PAUSE 6

returns a C Nonsense in Basic error due to the ';' preceding the PAUSE as it is expecting a ':'

remy commented 3 years ago

The syntax validation isn't 100% complete implementation of NextBASIC's parser (mostly because the parser - as far as I know - is closed source), so it's mostly used as a helper.

Where I find there should be an error and my validation didn't pick it up, I'll normally try to adjust my logic for that use case - so your example code is perfect and can help me improve the tool for others too.

I've found most of the recent validation bugs have been around print statements and what's allowed with semi-colon separation and what's not.

I'll file as a bug and get a fix in.

Tailzer commented 3 years ago

ok cool, that makes sense. If i spot anything else ill shout. Thanks

remy commented 3 years ago

Fixed in the latest release: 1.5.4 - thanks again.