This type checking is redundant, as `const_get` throws its own exceptions.