Merge remote-tracking branch 'upstream/master' into prototype-fmt

This commit is contained in:
Daniel Gavin
2021-04-23 10:24:05 +02:00
44 changed files with 1568 additions and 717 deletions
+1
View File
@@ -6,6 +6,7 @@ Proc_Tag :: enum {
Bounds_Check,
No_Bounds_Check,
Optional_Ok,
Optional_Second,
}
Proc_Tags :: distinct bit_set[Proc_Tag; u32];
-5
View File
@@ -212,11 +212,6 @@ Type_Flag_Bit_Set :: enum u32le {
Underlying_Type = 4,
}
Type_Flags_SimdVector :: distinct bit_set[Type_Flag_SimdVector; u32le];
Type_Flag_SimdVector :: enum u32le {
x86_mmx = 1,
}
from_array :: proc(base: ^Header_Base, a: $A/Array($T)) -> []T {
s: mem.Raw_Slice;
s.data = rawptr(uintptr(base) + uintptr(a.offset));
+4 -6
View File
@@ -1910,12 +1910,10 @@ parse_proc_tags :: proc(p: ^Parser) -> (tags: ast.Proc_Tags) {
ident := expect_token(p, .Ident);
switch ident.text {
case "bounds_check":
tags |= {.Bounds_Check};
case "no_bounds_check":
tags |= {.No_Bounds_Check};
case "optional_ok":
tags |= {.Optional_Ok};
case "bounds_check": tags |= {.Bounds_Check};
case "no_bounds_check": tags |= {.No_Bounds_Check};
case "optional_ok": tags |= {.Optional_Ok};
case "optional_second": tags |= {.Optional_Second};
case:
}
}