Adding dynamic typecasting to the Mercury language.