mirror of https://github.com/tLDP/LDP
Merge pull request #100 from cwfoo/lex-yacc-typos
Fix typos in Lex-YACC-HOWTO
This commit is contained in:
commit
4037f9e524
|
@ -422,7 +422,7 @@ output the message passed, but there are smarter things to do. See
|
||||||
the 'Further reading' section at the end.
|
the 'Further reading' section at the end.
|
||||||
|
|
||||||
The function yywrap() can be used to continue reading from another file. It
|
The function yywrap() can be used to continue reading from another file. It
|
||||||
is called at EOF and you can than open another file, and return 0. Or you
|
is called at EOF and you can then open another file, and return 0. Or you
|
||||||
can return 1, indicating that this is truly the end. For more about this,
|
can return 1, indicating that this is truly the end. For more about this,
|
||||||
see the 'How do Lex and YACC work internally' chapter.
|
see the 'How do Lex and YACC work internally' chapter.
|
||||||
|
|
||||||
|
@ -934,7 +934,7 @@ and integers - but not simultaneously.
|
||||||
|
|
||||||
Remember that we told YACC previously what type yylval was supposed to be by
|
Remember that we told YACC previously what type yylval was supposed to be by
|
||||||
defining YYSTYPE. We could conceivably define YYSTYPE to be a union this
|
defining YYSTYPE. We could conceivably define YYSTYPE to be a union this
|
||||||
way, by YACC has an easier method for doing this: the %union statement.
|
way, but YACC has an easier method for doing this: the %union statement.
|
||||||
|
|
||||||
Based on Example 4, we now write the Example 7 YACC grammar. First the
|
Based on Example 4, we now write the Example 7 YACC grammar. First the
|
||||||
intro:
|
intro:
|
||||||
|
|
Loading…
Reference in New Issue