diff options
| author | Ginger Bill <bill@gingerbill.org> | 2017-04-02 18:16:45 +0100 |
|---|---|---|
| committer | Ginger Bill <bill@gingerbill.org> | 2017-04-02 18:16:45 +0100 |
| commit | 8ce58573dfa2c140dcafd633e51c56d555f7ebc1 (patch) | |
| tree | 0bbcfca14f77f8cbcbb6385e72148d3fbb1caedb /src/checker.c | |
| parent | 2c8b99337bb33d0f713026c5c38e05428cc52143 (diff) | |
len, cap, make; remove .count, .capacity, new_slice
Diffstat (limited to 'src/checker.c')
| -rw-r--r-- | src/checker.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/checker.c b/src/checker.c index c594bbe8a..30b1857b5 100644 --- a/src/checker.c +++ b/src/checker.c @@ -23,9 +23,13 @@ typedef struct BuiltinProc { typedef enum BuiltinProcId { BuiltinProc_Invalid, + BuiltinProc_len, + BuiltinProc_cap, + BuiltinProc_new, - BuiltinProc_new_slice, BuiltinProc_free, + // BuiltinProc_new_slice, + BuiltinProc_make, BuiltinProc_reserve, BuiltinProc_clear, @@ -75,9 +79,13 @@ typedef enum BuiltinProcId { gb_global BuiltinProc builtin_procs[BuiltinProc_Count] = { {STR_LIT(""), 0, false, Expr_Stmt}, + {STR_LIT("len"), 1, false, Expr_Expr}, + {STR_LIT("cap"), 1, false, Expr_Expr}, + {STR_LIT("new"), 1, false, Expr_Expr}, - {STR_LIT("new_slice"), 2, true, Expr_Expr}, {STR_LIT("free"), 1, false, Expr_Stmt}, + // {STR_LIT("new_slice"), 2, true, Expr_Expr}, + {STR_LIT("make"), 1, true, Expr_Expr}, {STR_LIT("reserve"), 2, false, Expr_Stmt}, {STR_LIT("clear"), 1, false, Expr_Stmt}, |