mirror of
https://github.com/odin-lang/Odin.git
synced 2026-09-18 18:35:16 -04:00
fix: no more deferred_return in generic parapoly type name
fix: segfault on accessing empty tags array in docs writer
This commit is contained in:
1 parent
d21fea404b
commit
ebd50de56c
2 files changed
+7
-3
No files matched your search
+4
-2
@@ -670,8 +670,10 @@ gb_internal OdinDocTypeIndex odin_doc_type(OdinDocWriter *w, Type *type, bool ca
|
||||
auto tags = array_make<OdinDocString>(heap_allocator(), type->Struct.fields.count);
|
||||
defer (array_free(&tags));
|
||||
|
||||
for_array(i, type->Struct.fields) {
|
||||
tags[i] = odin_doc_write_string(w, type->Struct.tags[i]);
|
||||
if (type->Struct.tags != nullptr) {
|
||||
for_array(i, type->Struct.fields) {
|
||||
tags[i] = odin_doc_write_string(w, type->Struct.tags[i]);
|
||||
}
|
||||
}
|
||||
|
||||
doc_type.tags = odin_write_slice(w, tags.data, tags.count);
|
||||
|
||||
Reference in new issue
Block a user