Stefan Richthofer
Stefan Richthofer
Maybe ``pytypes.get_Generic_parameters(tp, generic_supertype=tp)`` would do the trick, i.e. checking that it returns empty list or none or errors (don't remember exact behavior right now).
Luckily, this is much the same as Python 3.7 support #40 . It looks like once 3.7 is achieved, 3.8 works as well. It would be so great if the...
I think the rationale is that ``list`` behaves like ``List[Any]`` and ``List`` is invariant (because it's writable), see https://www.python.org/dev/peps/pep-0484/#covariance-and-contravariance. Also ``Dict`` is invariant in the key type, so that is...
> having ``list`` and ``dict`` not be supported I claim they *are* supported, and what you observe is correct behavior. ``List[int]`` is *not* a subtype of ``List[Any]`` because it does...
In case you don't already know this trick: You can install current master via pip like explained [here](https://coderwall.com/p/-wbo5q/pip-install-a-specific-github-repo-tag-or-branch). It should also be possible to specify it as a dependency this...
It occurred to me that this is much the same issue as described in #76. The actual issue is that `[1, 2, 3]` is considered `List[int]` although it might rather...
Yes that is [numeric tower according to PEP484](https://www.python.org/dev/peps/pep-0484/#the-numeric-tower). Same with ``float`` and ``complex``. You can turn it off via [``pytypes.apply_numeric_tower = False``](https://github.com/Stewori/pytypes/blob/master/pytypes/__init__.py#L163).
`OrderedDict` is currently not supported. I don't really want to add new features before Python 3.7 compatibility is achieved. I can see if adding this support is somewhat trivial. Otherwise...
I will check if using ``@decorator`` does not break anything... If all goes well we can apply that to the decorators in pytypes.
Looks like `deep_type` doesn't support type. This might be reasonably easy to add...