pchapin / scala

Scalaness: A stagged programming system for embedded systems based on Scala.
0 stars 0 forks source link

NesT argument type mismatch errors are incorrectly indicated #3

Open pchapin opened 11 years ago

pchapin commented 11 years ago

If there is a mismatch between an argument type and a parameter type when a nesT function/command is called, the error report points at the first argument in the argument list regardless of which argument is in error. This is misleading.

This arises because the TypeException thrown to indicate the error is using the position of the current node in the AST as the location of the error. However, the current node in this case is the ARGUMENT_LIST node and so the error is reported for the list as a single unit (pointing at the first argument in the list).