Skip to content

Commit d1d8df3

Browse files
authored
Merge pull request odin-lang#5793 from Kelimion/checker-bugs
Checker bugs
2 parents 7670982 + e675454 commit d1d8df3

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/exact_value.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -908,8 +908,8 @@ gb_internal ExactValue exact_binary_operator_value(TokenKind op, ExactValue x, E
908908
if (op != Token_Add) goto error;
909909

910910
// NOTE(bill): How do you minimize this over allocation?
911-
String sx = x.value_string;
912-
String sy = y.value_string;
911+
String16 sx = x.value_string16;
912+
String16 sy = y.value_string16;
913913
isize len = sx.len+sy.len;
914914
u16 *data = gb_alloc_array(permanent_allocator(), u16, len);
915915
gb_memmove(data, sx.text, sx.len*gb_size_of(u16));

src/types.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -410,7 +410,7 @@ gb_internal u32 type_info_flags_of_type(Type *type) {
410410
flags |= TypeInfoFlag_Comparable;
411411
}
412412
if (is_type_simple_compare(type)) {
413-
flags |= TypeInfoFlag_Comparable;
413+
flags |= TypeInfoFlag_Simple_Compare;
414414
}
415415
return flags;
416416
}
@@ -1725,7 +1725,7 @@ gb_internal bool is_type_u8_ptr(Type *t) {
17251725
t = base_type(t);
17261726
if (t == nullptr) { return false; }
17271727
if (t->kind == Type_Pointer) {
1728-
return is_type_u8(t->Slice.elem);
1728+
return is_type_u8(t->Pointer.elem);
17291729
}
17301730
return false;
17311731
}
@@ -1766,7 +1766,7 @@ gb_internal bool is_type_u16_ptr(Type *t) {
17661766
t = base_type(t);
17671767
if (t == nullptr) { return false; }
17681768
if (t->kind == Type_Pointer) {
1769-
return is_type_u16(t->Slice.elem);
1769+
return is_type_u16(t->Pointer.elem);
17701770
}
17711771
return false;
17721772
}

0 commit comments

Comments
 (0)