The Concept:
Take a variable x mark it as castable to Y to the AST.
The AST shall then be able via a graph of castable types be able to cast x to Y.
Example in C++:
auto x = __castable<Y> X();
auto ref_xy = x->as<Y>();
Probable Applications
It may be quite vague for some, but bear with me:
Could be useful in use cases where x matters in how is treated.