1
0
mirror of https://github.com/janet-lang/janet synced 2025-11-18 00:05:13 +00:00

Add compile time arity checking.

This should help catch a number of errors, but it
is a very shallow implementation of type checking. It will
catch some common misuses of functions at compile time
rather than runtime.
This commit is contained in:
Calvin Rose
2019-09-30 19:50:42 -05:00
parent 2becd196dd
commit 7910a5feef
4 changed files with 90 additions and 11 deletions

View File

@@ -214,7 +214,7 @@ JanetSlot *janetc_toslots(JanetCompiler *c, const Janet *vals, int32_t len);
JanetSlot *janetc_toslotskv(JanetCompiler *c, Janet ds);
/* Push slots load via janetc_toslots. */
void janetc_pushslots(JanetCompiler *c, JanetSlot *slots);
int32_t janetc_pushslots(JanetCompiler *c, JanetSlot *slots);
/* Free slots loaded via janetc_toslots */
void janetc_freeslots(JanetCompiler *c, JanetSlot *slots);