Index: src/wasm/wasm-objects.cc |
diff --git a/src/wasm/wasm-objects.cc b/src/wasm/wasm-objects.cc |
index 0b8c8e970b4311fea5a546622fe51ecdd25c6d6b..e33e99b5774b2a3f3a7894bcf6205be4c5a28f63 100644 |
--- a/src/wasm/wasm-objects.cc |
+++ b/src/wasm/wasm-objects.cc |
@@ -492,8 +492,8 @@ Handle<WasmExportedFunction> WasmExportedFunction::New( |
EmbeddedVector<char, 16> buffer; |
int length = SNPrintF(buffer, "%d", func_index); |
name = isolate->factory() |
- ->NewStringFromAscii( |
- Vector<const char>::cast(buffer.SubVector(0, length))) |
+ ->NewStringFromOneByte( |
+ Vector<uint8_t>::cast(buffer.SubVector(0, length))) |
.ToHandleChecked(); |
} else { |
name = maybe_name.ToHandleChecked(); |