Improve && and || operation.
Add $foreach.index and $foreach.hasNext for #foreach.
Add status UNDEFINED.
Remove stats UNDEFINED.
Fix unpaired braces.
Only when Reference be part of Statements, will convert non-silent and undefined reference to literal, in other conditions, will pass the real value of Reference.