Top "Mutable" questions

A mutable can be modified after it is created.

Using volatile keyword with mutable object

In Java, I understand that volatile keyword provides visibility to variables. The question is, if a variable is a reference …

java concurrency volatile mutable
Good uses for mutable function argument default values?

It is a common mistake in Python to set a mutable object as the default value of an argument in …

python arguments default-value mutable
Converting immutable to mutable collections

What is the best way to convert collection.immutable.Set to collection.mutable.Set?

scala collections immutability mutable
How do I pass a reference to mutable data in Rust?

I want to create a mutable struct on the stack and mutate it from helper functions. #[derive(Debug)] struct Game { …

pointers mutable rust
What's the difference between placing "mut" before a variable name and after the ":"?

Here are two function signatures I saw in the Rust documentation: fn modify_foo(mut foo: Box<i32>) { *…

variables syntax reference rust mutable
Why is there no mutable TreeMap in Scala?

Is it lack of time, some technical problem or is there a reason why it should not exist?

scala collections map tree mutable
How do I pass a mutable vector as a function parameter in Rust?

I am implementing a small program that evaluates the Collatz conjecture. As part of this, I have a function that …

rust mutable