I have finished the lexer and thanks to you I have added new ideas to my program...

claudio daffra Answered 1 answer
Question by claudio daffra 2 years ago

Question

I have finished the lexer and thanks to you I have added new ideas to my programming.
i need to understand "Creating Tokens Outside Of The Input File"
Why is there a need to use a second string-based lexer where additional instructions can be provided?
It is probably used in advanced modules of the program but I need to understand now, can you give me some concrete examples? Thanks in advance.

Answers

Answered by Daniel McCarthy

Instructor

Hello, really glad I have helped you with my content. Regarding the string parser this is used later in the course when you build the preprocessor, rather than rewrite all the lexer code which would be a waste of time we simply made an abstraction that we can use later when building our preprocessor
Thanks
Dan