|
The following list summarizes differences between Liberty BASIC and MS-DOS BASICs that would normally not cause a syntax error, but nonetheless have significant differences.
Jump to A B C D E F G I L M
A- ASC
- (PB) Is a function only.
- ASC("") returns zero rather than generating an error.
B- BEEP does not make any sound.
- BYREF - cannot pass arrays to SUBs and FUNCTIONs.
C- CALL
- Requires that parentheses be omitted.
E.g. Call MySub "Testing", 1, 2, 3
- Is a required keyword to call any SUB.
- Cannot be used to call a FUNCTION.
- CHR$ (PB) cannot accept more than one parameter.
- CLOSE
- Requires a #handle or #handle$ variable.
- Cannot accept more than one handle.
- COMMAND$ becomes CommandLine$
D- DATA
- (QB) Can appear in the root code or in SUBs/FUNCTIONs. READs apply only to the DATA in the same scope.
- Cannot embed quoted text within unquoted text.
- Spaces are not allowed unless text is enclosed in quotes.
- DATE$
- Becomes a function.
- Cannot set the PC's clock
- DIM
- Limited to two dimensions.
- Arrays are always zero-based.
E- EOF requires a #handle or #handle$ variable.
- ERL is not implemented.
- ERR
- Is named Err (case sensitive).
- Many error codes are different or unassigned (0).
- EXIT cannot exit nested loops,
E.g. FOR ... : WHILE ... : EXIT FOR : WEND : NEXT F- FIELD ?
- FREEFILE is not implemented.
G- GET
- Is not a graphics command.
- Is not used with BINARY files.
- GOTO (before LB 5) must not be used to exit a structured (DO, FOR, WHILE) loop.
I- IF...THEN IF ... THEN ... ELSE ... (single line) evaluates differently
- INKEY$
- Is named Inkey$ (case sensitive).
- Is filled only for WHEN characterInput events.
- INPUT
- Never generates "Redo from start" quasi-error. Fills variable(s) with zeros.
- A comma (,) before the first variable is not allowed.
- When reading comma-delimited data, quotes are ignored.
- INPUT$(num, #file) becomes INPUT$(#file, num).
- INSTR(A, B$, C$) becomes INSTR(B$, C$, A).
- INT in LB acts exactly like FIX.
L- LOCATE
- Only positioning is supported, not cursor changes.
- LOCATE row, column becomes LOCATE column, row.
- LOF requires a #handle or #handle$ variable.
- LPRINT requires DUMP to start printing.
- LPRINT USING - See LPRINT and PRINT USING.
M- MAX (PB)
- Accepts only two numeric parameters.
- MAX%, MAX&, and MAX$ are not implemented
- MID$ is a function only.
- MIN (PB)
- Accepts only two numeric parameters.
- MIN%, MIN&, and MIN$ are not implemented.
- MKDIR becomes a function.
- MKx$ functions are not implemented.
Have questions or comments about this article? Discuss it. |
|
|