Separate isAssignableFrom() and isAssignableTo() logic