hkust-taco / mlscript

The MLscript programming language. Functional and object-oriented; structurally typed and sound; with powerful type inference. Soon to have full interop with TypeScript!
https://hkust-taco.github.io/mlscript
MIT License
175 stars 27 forks source link

Override Fields Created in Ctor #160

Closed NeilKleistGao closed 1 year ago

NeilKleistGao commented 1 year ago
class C(a: int) { let a = 1 }

If there is a field a created in ctor, do not create #a and get a twice. let a = 1 will override the value from the ctor.