Message404078
--- a/Lib/typing.py
+++ b/Lib/typing.py
@@ -719,6 +719,12 @@ def __eq__(self, other):
def __hash__(self):
return hash(self.__forward_arg__)
+ def __or__(self, other):
+ return Union[self, other]
+
+ def __ror__(self, other):
+ return Union[other, self]
+
def __repr__(self):
return f'ForwardRef({self.__forward_arg__!r})'
This can be easily fixed, but I am waiting for guido and ken to check whether this is an intentioned operation. |
|
Date |
User |
Action |
Args |
2021-10-16 13:43:34 | corona10 | set | recipients:
+ corona10, gvanrossum, kj, bobbeyreese |
2021-10-16 13:43:34 | corona10 | set | messageid: <1634391814.27.0.892958821982.issue45489@roundup.psfhosted.org> |
2021-10-16 13:43:34 | corona10 | link | issue45489 messages |
2021-10-16 13:43:34 | corona10 | create | |
|