Skip to content

Commit ccfd01e

Browse files
authored
[Strings] Implement TODOs in the fuzzer (#6416)
1 parent 84aed03 commit ccfd01e

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/tools/fuzzing/fuzzing.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2468,9 +2468,14 @@ Expression* TranslateToFuzzReader::makeBasicRef(Type type) {
24682468
case HeapType::string:
24692469
return builder.makeStringConst(std::to_string(upTo(1024)));
24702470
case HeapType::stringview_wtf8:
2471+
return builder.makeStringAs(
2472+
StringAsWTF8, makeBasicRef(Type(HeapType::string, NonNullable)));
24712473
case HeapType::stringview_wtf16:
2474+
return builder.makeStringAs(
2475+
StringAsWTF16, makeBasicRef(Type(HeapType::string, NonNullable)));
24722476
case HeapType::stringview_iter:
2473-
WASM_UNREACHABLE("TODO: strings");
2477+
return builder.makeStringAs(
2478+
StringAsIter, makeBasicRef(Type(HeapType::string, NonNullable)));
24742479
case HeapType::none:
24752480
case HeapType::noext:
24762481
case HeapType::nofunc:

0 commit comments

Comments
 (0)