We finally finished the first assignment of the compiler construction project, which was to make the reference compiler recognize records. We were able to compile the test file, record.ast, and it generated the right c-code. Today, we simply ported the code from the old compiler to the new one. The new one had some new assert statements, to check if the right subtype was being used, and all, but it didn't take so long.
We now began the testing phase. We have this Java applet called diagnostix which is able to evaluate the quality of our test suite, and it showed us that our test cases detected 3/5 bugs the compiler should guard against...not bad for our first day of testing, and we are way ahead of schedule.
An interesting case we had was checking that a record name could not be used as a variable name, and also checking that it is illegal in our compiler to check for equality of two records.
Later, thats all for today.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment