I think it's better to avoid that. When casting some wrong argument like an object or array to int might result in 0 or 1 and leading to misleading behaviour. Therefore I'd prefer an exception here. What do you think? I think the other platforms implement it like that also.