using Foo :: enum {A, B, C}; len(Foo)

This commit is contained in:
gingerBill
2018-07-29 10:50:15 +01:00
parent 49f2124df0
commit 6512a3e5f2
11 changed files with 60 additions and 73 deletions
-1
View File
@@ -290,7 +290,6 @@ write_type :: proc(buf: ^String_Buffer, ti: ^runtime.Type_Info) {
case runtime.Type_Info_Enum:
write_string(buf, "enum ");
write_type(buf, info.base);
if info.is_export do write_string(buf, " #export");
write_string(buf, " {");
for name, i in info.names {
if i > 0 do write_string(buf, ", ");
+1 -1
View File
@@ -88,7 +88,7 @@ Type_Info_Enum :: struct {
base: ^Type_Info,
names: []string,
values: []Type_Info_Enum_Value,
is_export: bool,
is_using: bool, // TODO(bill): Should this be in the `Type_Info`?
};
Type_Info_Map :: struct {
key: ^Type_Info,