We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The implementation of deep_clone in fixedarray.mbt is not really a deep clone because it won't clone elements.
deep_clone
fixedarray.mbt
core/array/fixedarray.mbt
Line 958 in e687864
test { let arr : FixedArray[_] = [@ref.new(1), @ref.new(2), @ref.new(3)] let cloned = deep_clone(arr) arr[0].val = 0 inspect!(cloned, content="[{val: 0}, {val: 2}, {val: 3}]") }
The text was updated successfully, but these errors were encountered:
Clone
@CAIMEOX
Sorry, something went wrong.
No branches or pull requests
The implementation of
deep_clone
infixedarray.mbt
is not really a deep clone because it won't clone elements.core/array/fixedarray.mbt
Line 958 in e687864
Unexpected behavior happens when there is internal mutability:
The text was updated successfully, but these errors were encountered: