mirror of
https://github.com/micropython/micropython.git
synced 2026-01-07 04:30:24 +01:00
py: Add built-in super.
This commit is contained in:
7
tests/bytecode/mp-tests/class6.py
Normal file
7
tests/bytecode/mp-tests/class6.py
Normal file
@@ -0,0 +1,7 @@
|
||||
class A:
|
||||
def f(self):
|
||||
pass
|
||||
|
||||
class B(A):
|
||||
def f(self):
|
||||
super().f()
|
||||
6
tests/bytecode/mp-tests/class7.py
Normal file
6
tests/bytecode/mp-tests/class7.py
Normal file
@@ -0,0 +1,6 @@
|
||||
# accessing super, but not as a function call
|
||||
|
||||
class A:
|
||||
def f():
|
||||
#x = super
|
||||
print(super)
|
||||
Reference in New Issue
Block a user