FAQ
FAQ
This page will be updated throughout the project period when relevant.
Note that questions related to the exam can be found on a separate
page via the exam page, or via
this direct link.
- Can we have the LaTeX source for the official front page
so we can insert the group information electronically?
-
Sure!
- I use the flag "-lfl", so why won't my Flex program compile?
-
It says in the Flex documentation that you should link
to Flex when compiling the C-program it has created,
i.e., give
gcc
the flag -lfl
.
However, this does not seem to be necessary and may give
more problems than it solves.
Among other things, libfl.a
defines a main function.
So if you have defined a main function yourself, it won't compile.
Consider not using that flag.
- Why does Flex keep complaining about "yywrap"?
-
Flex wants you to define a yywrap function to tell Flex
what to do when it has read through the (first) input file.
This function is often not needed; partly because there's
often just one input file. One way to stop the complaining
is to write
%option noyywrap
in the top of your
lex file. In fact, to stop further warnings, you can write
%option noyywrap nounput noinput
and declare
a function as external: extern int fileno();
.
- Can we have the LaTeX source code for the Hungry grammar?
-
Sure!
- Bison indicates a default case, but it is not using it!
-
When considering the .output file, which Bison can generate for
debugging purposes, some states end with a default statement.
However, this should be read as an "otherwise" in a case
statement, where the other cases consist of the listed
next symbols on input. For a concrete next symbol on input,
the action which is taken is the one not enclosed
in square brackets.
Last modified: Tue Feb 28 08:08:56 CET 2012
Kim Skak Larsen
(kslarsen@imada.sdu.dk)