Re: [cc65] re: command line args

From: Greg King <gngking1erols.com>
Date: 2004-04-19 08:27:24
From: Ullrich von Bassewitz; on Date: Thursday, April 15, 2004, at 05:20 AM
>
> On Wed, Apr 14, 2004 at 12:01:57PM +0200, carlos wrote:
> > the problem, that the BASIC is turned off, could be solved if it is
> > turned off after getting the command-line args.
>
> And, what about the code under the ROM?
>
> > There must be a possibility to recover the last cursor position and the
> > position the run was entered. Then, 3 chars. (or four chars. with a
> > colon) to the right, you will find the params.
> > You could use stdio functions with screen input to get the params.
>
> Reading from the screen may solve some problems, but it introduces
> others. A leading space before the RUN command, for example, will break
> your sample programs. Or, in case you are going to skip whitespace:
> There may be another command before the RUN.

A more basic (pun intended) reason not to do it that way is that it
"re-invents the wheel!"  The BASIC and Kernal ROMs do exactly what is
described above, before they run the C program.  There is no good reason to
do it twice ("rem," is not _that_ ugly :-).  It would be a waste of time
and file-/memory-space.

----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Mon Apr 19 08:28:45 2004

This archive was generated by hypermail 2.1.8 : 2004-04-19 08:28:52 CEST