Skip to content

Commit

Permalink
JS: Fixing wrong primitive slice constructor (#646)
Browse files Browse the repository at this point in the history
  • Loading branch information
ambiguousname authored Aug 19, 2024
1 parent 3eaf5a4 commit 645c187
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions feature_tests/js/api/Float64Vec.mjs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion tool/src/js/type_generation/converter.rs
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ impl<'jsctx, 'tcx> TyGenContext<'jsctx, 'tcx> {
// Slices are always returned to us by way of pointers, so we assume that we can just access DiplomatReceiveBuf's helper functions:
match slice {
hir::Slice::Primitive(_, primitive_type) => format!(
r#"new diplomatRuntime.DiplomatPrimitiveSlice.getSlice(wasm, {variable_name}, "{}", {edges})"#,
r#"new diplomatRuntime.DiplomatSlicePrimitive.getSlice(wasm, {variable_name}, "{}", {edges})"#,
self.formatter.fmt_primitive_list_view(primitive_type)
)
.into(),
Expand Down

0 comments on commit 645c187

Please sign in to comment.