Skip to content
Snippets Groups Projects
Commit dff3aa9a authored by benjamin.franksen's avatar benjamin.franksen
Browse files

snc: re-factored and polished function definitions

This came out of the desire to allow function definitions intermixed
with c code and other definitions, and not only at the end of the
program but also in the initial definition section. Some amount of
re-factoring was necessary in the analysis part to make this possible,
since previously we had only one definition list per scope and now the
program has two. More changes were needed in the code generation, mostly
to pick apart the stuff that the parser now mixes together, and also to
beautify the generated code. The separate declarations for function
definitions are no longer in the header file; they are static anyway.

One difference in behaviour is that now the extra escaped C code
sections at the end of a program are paced *before* the state set code.
The advantage is that extra prototypes are no longer needed (except if
the functions call each other resursively). This change should not break
existing programs, since C functions cannot call state set functions. 
parent b84116ab
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment