Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Handle non-indexed generics >= py3.9 (#94)
Closes #93 This prevents `get_parameters` throwing an exception on python >= 3.9. This does lead to a difference in behaviour between different python versions, but the new class based alias introduced in 3.9 doesn't store the required info. So to maintaining the same behaviour would require a dictionary of the generic types to the correct output. Example of change in behaviour: **python <=3.8** ``` >>> from typing import List >>> from typing_inspect import get_parameters >>> get_parameters(List) (~T,) ``` **python >=3.9** ``` >>> from typing import List >>> from typing_inspect import get_parameters >>> get_parameters(List) () ```
- Loading branch information