Perhaps it would be more general to simple make `basetype` have a default value of `(basestring,)` and allow callers to pass in an iterable of base types. I believe `isinstance` supports such iterables directly. That way, the caller could control whether to descend into strings, but it wouldn't make the (fairly uncommon, I would imagine) case of specifying one or more additional base types much more verbose.