Convert checks for isNumericType and isSequenceType into something
Python3-friendly.