shadow
Declaring the same variable again using the variable.
This is different from declaring it as mutable.
You are able to change the type of the value with shadowing.
Example
fn main() {
let x = 5;
let x = x + 1;
{
let x = x * 2;
println!("The value of x in the inner scope is: {x}");
}
println!("The value of x in the main function is: {x}");
}
/*
Compiles to:
The value of x in the inner scope is: 12
The value of x in the main function is: 6
*/