Posted: Fri May 07, 2010 4:24 am
Good work, I find it useful for debug btw Syntax check doesn't work yet, right ?
May I suggest a proofreader function ?
May I suggest a proofreader function ?
The Commodore Vic 20 Forum
https://www.sleepingelephant.com/~sleeping/ipw-web/bulletin/bb/
https://www.sleepingelephant.com/~sleeping/ipw-web/bulletin/bb/viewtopic.php?t=4390
Code: Select all
' Emulator settings
' standard emulator, path/exe and commandline (%F=full path to prg file)
Emu=c:\vice\xvic.exe
EmuParams=%F
' special emulator for load address -1 = 1025 --> VIC +3K, PET/CBM series
Emu-1=c:\vice\xvic.exe
EmuParams-1=-config c:\vice\vice_vic3k.ini %F
' special emulator for load address -2 = 2049 --> C64
Emu-2=c:\vice\x64.exe
EmuParams-2=%F
' special emulator for load address -3 = 4097 --> VIC unexp, VIC +SuperExpander, Plus/4, C16
Emu-3=c:\vice\xvic.exe
EmuParams-3=-config c:\vice\vice_vicunexp.ini %F
' special emulator for load address -4 = 4609 --> VIC +8K and more
Emu-4=c:\vice\xvic.exe
EmuParams-4=-config c:\vice\vice_vicfull.ini %F
' special emulator for load address -5 = 7169 --> C128
Emu-5=c:\vice\x128.exe
EmuParams-5=%F
' special emulator for load address -6 = 3 --> CBM II series
Emu-6=c:\vice\xcbm2.exe
EmuParams-6=%F
I think that a Basic Syntax Check is a real killer application tool...Schlowski wrote:Syntax check will be removed, I think.
... Doing a real syntax check would require much more than simply converting PETSCII to tokens...
The most common was the first 1983 COMPUTE's version for Vic-20 and C64.Proofreader could be done, but is there really any demand. And if so, which proofreader(s) should be implemented?
I really don't know for sure, that's what you get if you save with xcbm2So the cmb2 has the load address of 3?
Problem is this would require a real parser and, to make it worse, this parser must be able to react like different Basic extensions. For example Exbasic/Wimbasic allows to omit THEN in most cases, making 10 IFA=1B=2 a valid command whereas this would cause an error in Basic V2. And I do not have the slightest idea what specialities Waterloo Structured Basic or Simons Basic or other Basic dialects have.I think that a Basic Syntax Check is a real killer application tool...
I will take a look at it, thanks for the info.The most common was the first 1983 COMPUTE's version for Vic-20 and C64.
Thanks for the info Schlowski, I'll blog about it soon. Too good not to share.Schlowski wrote: @robinsonmason: I started BasEdit as a simple to use Basic Editor for the PC as I always find it a little bit uncomfortable to edit bigger Basic programs on the VIC. Even if this means I loose some nostalgic feeling during coding. But the better overview over the source due to the bigger editing area and the ease of running through the source up and down makes up for that loss. At least for me.
I'll blog about it soon
I think that a Syntax check for the standard C64/Vic20 Basic V2 version is enoughSchlowski wrote:Problem is this would require a real parser and, to make it worse, this parser must be able to react like different Basic extensions.
Ok, I took your word and sacrificed my precious sleeping time for a syntax check.nbla000 wrote:I think that a Basic Syntax Check is a real killer application tool...
I think that a Syntax check for the standard C64/Vic20 Basic V2 version is enough
Code: Select all
; syntax = "..." description for syntax-check
; t$xx = token with value $xx
; c = command
; f = function - numeric
; f$ = function - string
; <var_any> = any numeric or string variable incl. arrays
; <var_num> = any numeric variable (int/float) incl. arrays
; <var_str> = any string variable incl. arrays
; <var> = any real variable incl. arrays
; <var_any_simple> = any numeric or string variable NO arrays
; <var_simple> = any float variable NO arrays
; <num> = any numeric expression (examples: 1, 2+3, 1+b+c(5), LEN(a$))
; <num_lit> = numeric literal / constant value (examples: 1, 10)
; <str> = any string expression (examples "A", LEFT$(A$,1), MID$(A$,LEN(B$)))
; <str_lit> = string literal / constant (example: "HELLO")
; <log> = logical expression (examples: I=10, X$<>"")
; <skip> = anything until : or line end
; <cmd> = any command (examples: END, A=5)
; <print> = commandlist for print
;
; sample for if-token
if, $8B, syntax="c<log>{t$A7<num_lit>|<cmd>}|{t$89<num_lit>}"
Code: Select all
; incomplete commands
; print : everything until : or end of line is valid, no check!
; print# : everything until : or end of line is valid, no check!
; cmd : everything until : or end of line is valid, no check!
; tab( : missing check for usage only with print!
; spc( : missing check for usage only with print!
Code: Select all
; special:
; sys : ignore everything until : or end of line
Code: Select all
7.204 lines total including
310 comment lines
560 empty lines
-----------------------------
6.334 lines of code
Code: Select all
3.774 lines total including
210 comment lines
520 empty lines
-----------------------------
3.044 lines of code
Cool! Does it work for any VB.NET project? Can I download it somewhere?Schlowski wrote: Btw, just made a little tool which scans my *.vb files and counts lines, comments and empty lines resulting in the following values for BasEdit.NET