Fix generic alias checks (#172)

This commit is contained in:
Nikhil Rao 2022-12-22 16:06:11 -08:00 committed by GitHub
parent 0bc09dc961
commit 63ec55bdde
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -619,7 +619,7 @@ class BaseVar(Var, Base):
Returns:
The default value of the var.
"""
if isinstance(self.type_, _GenericAlias):
if utils.is_generic_alias(self.type_):
type_ = self.type_.__origin__
else:
type_ = self.type_