Compile 0.45 - Casts implemented

Needs fixing and more testing