fix build with gcc

closes #66
This commit is contained in:
Andrew Kelley
2016-01-12 21:07:45 -07:00
parent cb46d0b5b0
commit 76dc44d2a6
2 changed files with 7 additions and 4 deletions

View File

@@ -2402,7 +2402,7 @@ static void define_builtin_fns_int(CodeGen *g, TypeTableEntry *type_entry) {
{"sub", "ssub", "usub"},
{"mul", "smul", "umul"},
};
for (int i = 0; i < sizeof(overflow_fns)/sizeof(overflow_fns[0]); i += 1) {
for (size_t i = 0; i < sizeof(overflow_fns)/sizeof(overflow_fns[0]); i += 1) {
OverflowFn *overflow_fn = &overflow_fns[i];
BuiltinFnEntry *builtin_fn = allocate<BuiltinFnEntry>(1);
buf_resize(&builtin_fn->name, 0);