3 ms·
Is TFA (or anyone else for that matter) actually concerned with "immutable variables"? e.g., `let i = 0; i++;` They seem to be only worried about modifying ob
by tantalor 11mo ago
Is TFA (or anyone else for that matter) actually concerned with "immutable variables"?
e.g., `let i = 0; i++;`
They seem to be only worried about modifying objects, not reassignment of variables.
- voidUpdate 11mo agoLooks like Rust is https://doc.rust-lang.org/stable/std/keyword.let.html https://doc.rust-lang.org/stable/std/keyword.let.html
- macintux 11mo agoErlang doesn't allow variable reassignment. Elixir apparently does, but I've never played with it.
- ruined 11mo agotypescript handles that well already
- Cthulhu_ 11mo agoThat's probably because reassignment is already covered by using `const`. Of course, it doesn't help that the immutable modifier for Swift is `let`. But also, in Swift, if you assign a list via `let`, the list is also immutable.