typecheck: diagnose missing return types

This commit is contained in:
Hermes Agent
2026-09-18 09:12:58 +00:00
parent da2bd5c2e8
commit 131211adef
6 changed files with 15 additions and 1 deletions
+3
View File
@@ -311,6 +311,9 @@ EXPECTED = {
"tests/typecheck_extra_teach_tokens_bad.claro": [
"tests/typecheck_extra_teach_tokens_bad.claro:1: Function greet has extra text after return type NUMBER. Keep only the function name, parameters, and one return type.",
],
"tests/typecheck_missing_return_type_bad.claro": [
"tests/typecheck_missing_return_type_bad.claro:1: Function greet needs a return type after RETURNS. Add a type such as NUMBER.",
],
"tests/typecheck_extra_check_type_tokens_bad.claro": [
"tests/typecheck_extra_check_type_tokens_bad.claro:2: CHECK TYPE score has extra text after type NUMBER. Keep only the expression, IS, and one type.",
],