Jump to content
IGNORED

FastBasic 4.4 BETA


Recommended Posts

 Hi!

On 7/20/2020 at 4:20 PM, vitoco said:

Please, let me know if you allow the abbreviatons in the syntax, in order to try them in my new tenliners and to check if something goes wrong and then to include them in manual.md.

 

Added the function abbreviations and the optional parentheses.

 

New in this beta release:

 

- Adds CONTROL-G to the IDE go to a specific line in the file.

- Recognize Shift-F1 and Shift-F2 (1200XL keys) as page-up and page-down. This also works on most emulators.

- Adds a "NEXT" word to the DLI to write to WSYNC, advancing to the next screen line before writing the registers. (use like " DLI tst = $80 INTO $D01A, $86 NEXT INTO $D01A, $8A NEXT INTO $D01A, $8E NEXT INTO $D01A"

- Allows to skip parentheses in functions accepting one value, like "A = PEEK 123" or "? CHR$ 65"

- Allows function abbreviations, using the table provided by @vitoco.

 

Please, test this beta version - specially the abbreviations, as I would like to release version 4.4 next weekend. The integer IDE is exactly 8192 bytes, after a lot of optimizations I could make it fit in 8kB again :)

 

Have Fun!

 

fastbasic-manual-4.4-beta.pdf fastbasic-v4.4-beta-18-g7c637a4.atr fastbasic-v4.4-beta-18-g7c637a4-win32.zip fastbasic-v4.4-beta-18-g7c637a4-linux64.zip

  • Like 5
  • Thanks 1
Link to comment
Share on other sites

18 hours ago, dmsc said:

- Allows to skip parentheses in functions accepting one value, like "A = PEEK 123" or "? CHR$ 65"

- Allows function abbreviations, using the table provided by @vitoco.

These are great for tenliners!!! Thanks...

 

As I assigned "A." for "ADR()" function, but this function can't be abbreviated, how about assigning it to "ABS()" function instead of "AB."?

 

Link to comment
Share on other sites

Hi!

2 hours ago, vitoco said:

These are great for tenliners!!! Thanks...

 

As I assigned "A." for "ADR()" function, but this function can't be abbreviated, how about assigning it to "ABS()" function instead of "AB."?

There is an option: I can implement abbreviation of "ADR", by changing the parser to only skips letters or numbers after a dot. But this will mean that you would need to abbreviate "ERR()" as "E.()" and "KEY()" as "K.()". That would also mean that I could abbreviate string functions conserving the $ at the end, for example, "CHR$" to "C.$"

 

Would that be a better solution?

 

Have Fun!

Link to comment
Share on other sites

3 hours ago, dmsc said:

There is an option: I can implement abbreviation of "ADR", by changing the parser to only skips letters or numbers after a dot. But this will mean that you would need to abbreviate "ERR()" as "E.()" and "KEY()" as "K.()". That would also mean that I could abbreviate string functions conserving the $ at the end, for example, "CHR$" to "C.$"

 

Would that be a better solution?

I think it would not... Just keep "ADR()" and "USR()" without abbreviations and requiring parentheses.

 

BTW, "STR$()" cannot be abbreviated because it would be a conflict with "STRIG()", but I think that "CHR$()" could be abbreviated as "C.()" as its rule is also a valid T_EXPR, even when it looks strange without a dollar sign.

 

On 8/2/2020 at 11:29 PM, dmsc said:

- Adds a "NEXT" word to the DLI to write to WSYNC, advancing to the next screen line before writing the registers. (use like " DLI tst = $80 INTO $D01A, $86 NEXT INTO $D01A, $8A NEXT INTO $D01A, $8E NEXT INTO $D01A"

This feature is nice, but I wouldn't use "NEXT" as the WSYNC option, because it is already used in FOR-NEXT loops and it could cause confusion. Instead, I'd prefer "SYNC", "WSYNC" or "WAIT" as they are related to the DLI slang. What do you think?

 

++V

Link to comment
Share on other sites

Hi!

8 hours ago, vitoco said:

This feature is nice, but I wouldn't use "NEXT" as the WSYNC option, because it is already used in FOR-NEXT loops and it could cause confusion. Instead, I'd prefer "SYNC", "WSYNC" or "WAIT" as they are related to the DLI slang. What do you think?

 

Privately I also proposed to change it to "DOWN" or "ROW", so it reads better, the options could be:

 

  "DLI x = $10 INTO $D01A, $14 NEXT INTO $D01A, $18 NEXT INTO $D01A"

 

  "DLI x = $10 INTO $D01A, $14 DOWN INTO $D01A, $18 DOWN INTO $D01A"

 

  "DLI x = $10 INTO $D01A, $14 ROW INTO $D01A, $18 ROW INTO $D01A"

 

  "DLI x = $10 INTO $D01A, $14 SYNC INTO $D01A, $18 SYNC INTO $D01A"

 

  "DLI x = $10 INTO $D01A, $14 WAIT INTO $D01A, $18 WAIT INTO $D01A"

 

What do you prefer?

 

Have Fun!

 

Link to comment
Share on other sites

1 hour ago, Philsan said:

FastBasic with abbreviations, in the hands of Victor, is a lethal weapon! ?

Ha, ha, ha.... My only already finished project for NOMAM 2021 returned to WIP state today. It's length was 2551 bytes of a maximum of 2560 (including newlines) for the EXTREM-256 category, but after I abbreviated the function names and removed the unnecesary parentheses, it's new length went down to just 2502 bytes, that is 49 bytes saved (about 2%), giving me 58 bytes to add more features!!!

 

24 minutes ago, Wrathchild said:

WSYNC - if you are working on DLIs then you will know what that is

I agree, but there is a constraint: 8K limit for integer version of FB. There is room for a name up to 4 bytes long, so I vote for "SYNC" instead of an acronym with less letters or a single symbol.

 

  • Like 1
Link to comment
Share on other sites

Hi!

23 hours ago, Preppie said:

Fully abbreviated FastBasic is now harder to read than a hex dump ?

 

Yes, now you can write code like this:

P.D.88,P.D.88+1

Or this full program:

DO:F.X=D.88TOD.88+39:P.X,P.X+1:N.:L.

Good luck deciphering the meanings :P 

 

  • Haha 1
Link to comment
Share on other sites

1 hour ago, dmsc said:

DO:F.X=D.88TOD.88+39:P.X,P.X+1:N.:L.

Good luck deciphering the meanings :P 

It is faster and shorter this one:

DO:MS.D.88,40,P.D.88+1:L.

BTW, I allways forget that N. does not require the variable name in FB. That saves me at least an extra byte.

 

Edited by vitoco
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...