Jakt currently does not track mutability of types. Instead, it awkwardly conflates mutability of bindings with mutability of types.
We should split a type T
into T
and mut T
. This would map to T const
and T
in the generated C++.
let x = get_some<mut T>()
should create an immutable binding to a mut T
mut x = get_some<T>()
should create a mutable binding to a T
Mutation method calls should only be allowed on mut T
values, not T
.
Passing a mut T
to a function parameter of type T
should be allowed.
There are probably other details that need figuring out.
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too