mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-20 03:20:56 +07:00
16 lines
274 B
Python
16 lines
274 B
Python
import typing
|
|
|
|
|
|
MyTup1 = typing.NamedTuple("MyTup1", bar=int, baz=str)
|
|
|
|
|
|
class MyTup2(typing.NamedTuple):
|
|
bar: int
|
|
baz: str
|
|
|
|
|
|
MyTup1(1, "")._replace(<arg1>)
|
|
MyTup2(1, "")._replace(<arg2>)
|
|
|
|
MyTup1._replace(MyTup1(1, ""), <arg3>)
|
|
MyTup2._replace(MyTup2(1, ""), <arg4>) |