Skip to content

Commit 8bcdd2f

Browse files
committed
Fix incorrect error message when merging world imports
The error context said "mismatched type for export" when the mismatch was actually in the imports section of a world merge. Changed to "mismatched type for import" to correctly describe the error.
1 parent e1e684a commit 8bcdd2f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

crates/wac-types/src/aggregator.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ impl TypeAggregator {
227227
// We'll remap the source below and replace
228228
checker
229229
.is_subtype(*source_kind, types, target_kind, &self.types)
230-
.with_context(|| format!("mismatched type for export `{name}`"))?;
230+
.with_context(|| format!("mismatched type for import `{name}`"))?;
231231
}
232232

233233
let remapped = self.remap_item_kind(types, *source_kind, checker)?;

0 commit comments

Comments
 (0)