feat: improve unknown object field expression diagnostic

This commit is contained in:
Hermes Agent
2026-08-09 03:03:23 +00:00
parent c41d2555c9
commit a3c084ba70
8 changed files with 33 additions and 5 deletions
+3
View File
@@ -44,6 +44,9 @@ EXPECTED = {
"tests/typecheck_object_field_unknown_yesno_bad.claro": [
"tests/typecheck_object_field_unknown_yesno_bad.claro:6: Object Player has no field ready. Check the field name or add HAS ready YESNO to the class.",
],
"tests/typecheck_object_field_unknown_expression_bad.claro": [
"tests/typecheck_object_field_unknown_expression_bad.claro:7: Object Player has no field level. Check the field name or add the field to the class with the right type.",
],
"tests/typecheck_object_field_check_type_text_bad.claro": [
"tests/typecheck_object_field_check_type_text_bad.claro:7: Type check failed: expected NUMBER, but player.name looks like TEXT.",
],