Mutability for Immutable Composite Types #6368
Labels
audit-report
Related to the audit report
bug
Something isn't working
P: high
Should be looked at if there are no critical issues left
CS-FSSA-002
In Sway, mutability is specified upon declaration. In case a variable is defined as immutable, its content
cannot be changed. However, the mutability check is not recursive on composite types. This means we
can create a mutable reference to a field of an immutable variable like the following example:
The text was updated successfully, but these errors were encountered: