From ae93ec5bb0cfb6b70098a125b188995d441bb43e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B0=8F=E7=99=BD=E4=BA=91?= <71159641+littlewhitecloud@users.noreply.github.com> Date: Sun, 17 Dec 2023 21:03:04 +0800 Subject: [PATCH] Update typecheck.c --- src/typecheck.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/typecheck.c b/src/typecheck.c index d924b0aa..a4941721 100644 --- a/src/typecheck.c +++ b/src/typecheck.c @@ -245,6 +245,8 @@ static Signature handle_signature(FileTypes *ft, const AstSignature *astsig, con else sig.returntype = type_from_ast(ft, &astsig->returntype); + // TODO: validate main() parameters + // TODO: test main() taking parameters if (!self_type && !strcmp(sig.name, "main") && sig.returntype != intType) { fail_with_error(astsig->returntype.location, "the main() function must return int"); }