argv --> stdin IN LEX

David Chase rbbb at rice.EDU
Tue Dec 9 12:26:46 AEST 1986


RTFM! RTFM! RTFM!  I QUOTE:

	In addition to these routines, Lex also permits access to the
    I/O routines that it uses.  They are:

    1)	input() which returns the next input character;

    2)	output(c) which writes the character c on the
	output; and

    3)	unput(c) pushes the character c back onto the
	input stream to be read later by input().

    By default these routines are provided as macros definitions,
    but the user can override them and supply private versions.
    ....

Read the rest of "Lex- A Lexical Analyzer Generator" by M. E. Lesk and E.
Schmidt for other details, including the lookahead issues, use of yywrap,
etc.

>>"Look at the code generated by these tools!  It's easy to change it!"

David



More information about the Comp.unix.wizards mailing list