_______________________________________________Hi. I have a homework-assignment where one of the tasks is to make a static Analyzer for BIPL-E, BIPL-E being the BIPL Language with input- and output-parameters.
The Analyzer is supposed to
- check that all variables has been defined before use. If not, give an error message.
You can do this by traversing each statement in the program to check if it uses values that
haven’t been defined before. You can keep track of which variables that has been defined so far in a list, and put new ones to the list when you encounter Assign-statements
- check that all output parameters have been given a value when the program has ended
- You don’t care about what the different statements really evaluates to .
As a start:
static_analyzer :: BIPLE -> ..
..
Best regards,
Eirik
Sendt fra E-post for Windows 10
Haskell-Cafe mailing list
To (un)subscribe, modify options or view archives go to:
http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe
Only members subscribed via the mailman list are allowed to post.