瀏覽代碼

Fix missing allocator

gingerBill 5 年之前
父節點
當前提交
7a4ec48389
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      core/unicode/utf8/utf8.odin

+ 1 - 1
core/unicode/utf8/utf8.odin

@@ -147,7 +147,7 @@ runes_to_string :: proc(runes: []rune, allocator := context.allocator) -> string
 		byte_count += w;
 	}
 
-	bytes := make([]byte, byte_count);
+	bytes := make([]byte, byte_count, allocator);
 	offset := 0;
 	for r in runes {
 		b, w := encode_rune(r);