mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-05 15:18:49 +00:00
[REFLECTION BREAKING] Modify the internals of the map type to increase performance
This commit is contained in:
+2
-2
@@ -1501,10 +1501,10 @@ fmt_value :: proc(fi: ^Info, v: any, verb: rune) {
|
||||
header := cast(^runtime.Map_Entry_Header)data;
|
||||
|
||||
if reflect.is_string(info.key) {
|
||||
strings.write_string(fi.buf, header.key.str);
|
||||
strings.write_string(fi.buf, header.key.key.str);
|
||||
} else {
|
||||
fi := Info{buf = fi.buf};
|
||||
fmt_arg(&fi, any{rawptr(&header.key.hash), info.key.id}, 'v');
|
||||
fmt_arg(&fi, any{rawptr(&header.key.key.val), info.key.id}, 'v');
|
||||
}
|
||||
|
||||
strings.write_string(fi.buf, "=");
|
||||
|
||||
Reference in New Issue
Block a user