Accept a class object where a symbol addressing a class is accepted.

Convert IndexError to ArgumentError, and ArgumentError to TypeError as
appropriate.