Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
StunxFS committed Dec 25, 2023
1 parent b37ba53 commit dc5740b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions rivetc/src/sym.py
Original file line number Diff line number Diff line change
Expand Up @@ -250,8 +250,8 @@ def add_or_get_slice(self, elem_typ, is_mut = False):
slice_sym.add(
Func(
ABI.Rivet, True, False, False, True, False, "to_dynamic_array", [],
type_Type(slice_sym), False, True, NO_POS, False, False,
type_Type(slice_sym)
type_Type(self.add_or_get_dyn_array(elem_typ, is_mut)), False, True,
NO_POS, False, True, type_Type(slice_sym)
)
)
if core_slice_sym := self.find("core").find("Slice"):
Expand Down
2 changes: 1 addition & 1 deletion tests/valid/src/dynamic_array.ri
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
test "dynamic array from fixed array" {
arr := [1, 2, 3];
mut dyn_array := arr[:];
mut dyn_array := arr[:].to_dynamic_array();
dyn_array.push(2);
@assert(dyn_array.len == 4);

Expand Down

0 comments on commit dc5740b

Please sign in to comment.