let val: Int = 5;
let val2: @(Int | Float) = val;

val2 := 10;

if val != 10 {
    panic("Invalid value");
}

let val3 = 2.5;
val2 = val3;
val2 := 10.5;

if val != 10 {
    panic("Invalid value");
}

if val2.as<@Float>() != 10.5 {
    panic("Invalid value");
}