Closed CharlesTaylor7 closed 2 months ago
Another great PR. Specification test is great and diagnostic great 👍. Up to 202!
Just added two quick commits on top
diagnostics.rs
from the first PR. ASTNode::get_position
call for A::expression_position
for getting the position of where to emit the type checking error. This is because the type checking API is meant to be agnostic from a parser implementation (so in the future any other project can reuse the checking APIs without them to being specific to the ezno-parser
parser I built). A::expression_position
comes from ASTImplementation
which works in under any AST definitions that implement it. For the ezno-parser
AST definition it does use ASTNode::get_position
. That fixes why the CI error on the extras tests as the only place you can refer to ezno-parser
in the checker is under the synthesis directory (which mostly connects APIs to the AST definitions). Little bit complex, need to document the ASTImplementation
trait and that whole system better!
Part 2 of #112 Default parameter type checking.