Well,
one upon a long ago... there was a tool named "Basic Masher" it was written to make Basic programs shorter in one way or another, alas, I have not really found out how it works. At first the program asks for the number of variables in your program (and since I am no programmer and much too lazy to count variables in other peoples programs, this is where I always stopped) and I have no clue what happens then. I found three different versions of the program, two versions written in Atari Basic and one version compiled with ABC or MMG compiler. I used the longer/newer? Basic version to create version number four in compiled Turbo Basic and the CTB-linker to make it a standalone *.COM/*.XEX file... you can find these four versions on the attached disk image BASMASH.ATR, maybe you can find out how this program works and if its really usefull or not...
Second, you can use an easy trick by using programs that add a ML-header to your Basic File (but which do not compile the program). At the moment I have four programs in my collection which do this:
1) a PC program from Fandal, named BAS2XEX.EXE which I will not upload here (since it creates files that do not run on the real A8, it creates pseudo-ML files that use memory $0700-xxxx, RUN $0700)...
2) an A8 program named BAS2BIN that was once published in Antic or Analog magazine, it creates ML-files which I never got to work on my A8... (maybe I was too stupid to use it correctly)...
3) another A8 program named BAS2COM by Raster, it can convert tokenized *.BAS or listed *.LST Atari Basic files into pseudo-ML (the Basic file must not be longer than 28kbytes); however not all created ML files will run, so always keep a backup of your Basic file somewhere; if the created ML file works fine, you can load it with "binary load" from DOS or simply from a gamedos, then hit Break, Reset or Control-3 to get the file listed again...
4) another A8 program named Automatic Basic program Loader by Juergen Meyer, which will convert any *.BAS file into *.COM (length up to 32kbytes, always add a CLR and Gr.0 at the start of the Basic program); alas Break or Reset or Control-3 will not always list the program (sometimes it happens that the A8 crashes then), so again keep a backup of your Basic file...
Now, with these programs you can convert a Basic file into a pseudo-ML file, usually these ML files are some bytes/sectors longer then - how do you get them shorter ?!? Easy, since the Basic files now have an ML header you can use any kind of COM/XEX packer program on the A8 (e.g. Superpacker by Bewesoft, Fastpacker, Flash Packer, Code 3 Cruncher, Magnus Cruncher, etc.) or on the PC (Superpacker by TeBe) to pack this pseudo-ML file. I already did this with some programs, I can load them from DOS or Gamedos, see the program unpack and run and then one press of Reset or Break and they can be listed and edited again... see attached disk BAS2COM.ATR here...
Of course there is also option three, compile the Basic program with ABC or MMG or some other Basic compiler, then pack the *.COM/*.XEX file...
Greetings, Andreas Koch.