You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It would be great if MyPy types would be allowed in data blocks.
If I understand the way that the immutability of the data block is achieved, by using a _coconut.collections.namedtuple, this could be easily implemented by using MyPys own NamedTuple.
@jonathanplatzer That's a great idea! There is the issue that typing doesn't exist on old Python versions, but I think I can get around that via stub file magic (real _coconut.NamedTuple uses collections.namedtuple, but stub file _coconut.NamedTuple uses typing.NamedTuple).
It would be great if MyPy types would be allowed in
data
blocks.If I understand the way that the immutability of the
data
block is achieved, by using a_coconut.collections.namedtuple
, this could be easily implemented by using MyPys ownNamedTuple
.So this
could be compiled to this:
The text was updated successfully, but these errors were encountered: