Apparently not. You can write:
Code:
let x;
x = 1;
print!("{}", x);
the compiler knows that it wasn't used before it was initialized and it will compile and print 1
if you write
Code:
let x;
print!("{}", x);
x = 1;
the compiler will barf at you
Code:
const.rs:3:18: 3:19 error: use of possibly uninitialized variable: `x`
const.rs:3 print!("{}", x);
^
note: in expansion of format_args!
<std macros>:2:23: 2:75 note: expansion site
<std macros>:1:1: 3:2 note: in expansion of print!
const.rs:3:5: 3:21 note: expansion site
error: aborting due to previous error