FMaterialCompiler::ValidCast

Casts the passed in code to DestType, or generates a compile error if the cast is not valid.