remove unused remnanant of abandoned WIP.
short-circuit casting if input is valid