ChildsplayOSU / bogl

Haskell implementation of the BoGL language
https://bogl.engr.oregonstate.edu
BSD 3-Clause "New" or "Revised" License
7 stars 1 forks source link

Add Expr for Board Equation into State before TC #139

Closed montymxb closed 4 years ago

montymxb commented 4 years ago

Closes #90, where the type error for an expression that does not match with the type of a board failed with an odd error of !.

This makes a small adjustment by first adding the expression into the state monad, before type checking the expression with the type of the board. By doing so, the previous expression is able to be extracted correctly (whereas before it was missing), and the expected mismatch type error is reported normally.

Additionally, changes the error message for a missing source expression to something a bit more verbose besides !. Removes the associated TODO marks, as they were related to this issue before.