In this code:-
if (myTest)
{
var myVar:Int = 1;
}
else
{
myVar = 2;
}
the second reference to myVar
is undefined.
This is due to myVar
being only defined in the scope of the first block.
But where is this documented and what is it known as?