Skip to content

Commit a4b7041

Browse files
authored
Fix misc. things for globals (#2119)
1 parent 1a312a8 commit a4b7041

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

src/tools/wasm-metadce.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -353,7 +353,7 @@ struct MetaDCEGraph {
353353
std::cout << " is function " << DCENodeToFunction[name] << '\n';
354354
}
355355
if (DCENodeToGlobal.find(name) != DCENodeToGlobal.end()) {
356-
std::cout << " is function " << DCENodeToGlobal[name] << '\n';
356+
std::cout << " is global " << DCENodeToGlobal[name] << '\n';
357357
}
358358
for (auto target : node.reaches) {
359359
std::cout << " reaches: " << target.str << '\n';

src/wasm/wasm-binary.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -816,10 +816,9 @@ void WasmBinaryBuilder::read() {
816816
case BinaryConsts::Section::Element:
817817
readTableElements();
818818
break;
819-
case BinaryConsts::Section::Global: {
819+
case BinaryConsts::Section::Global:
820820
readGlobals();
821821
break;
822-
}
823822
case BinaryConsts::Section::Data:
824823
readDataSegments();
825824
break;

0 commit comments

Comments
 (0)