We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent efccbf6 commit 2a03740Copy full SHA for 2a03740
1 file changed
tests/basics/globals-del.py
@@ -0,0 +1,27 @@
1
+"""
2
+1
3
4
+
5
+def _f(): pass
6
+FunctionType = type(_f)
7
+LambdaType = type(lambda: None)
8
+CodeType = None
9
+MappingProxyType = None
10
+SimpleNamespace = None
11
12
+def _g():
13
+ yield 1
14
+GeneratorType = type(_g())
15
16
+class _C:
17
+ def _m(self): pass
18
+MethodType = type(_C()._m)
19
20
+BuiltinFunctionType = type(len)
21
+BuiltinMethodType = type([].append)
22
23
+del _f
24
25
+# print only the first 8 chars, since we have different str rep to CPython
26
+print(str(FunctionType)[:8])
27
+print(str(BuiltinFunctionType)[:8])
0 commit comments