We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Original bug ID: 7278 Reporter: @chambart Assigned to: @alainfrisch Status: closed (set by @xavierleroy on 2017-09-24T15:33:01Z) Resolution: fixed Priority: normal Severity: major Version: 4.03.0 Fixed in version: 4.04.0 +dev / +beta1 / +beta2 Category: typing Monitored by: @gasche @hcarty
Private records shouldn't be mutable, but the check is not applied for inline records.
For instance this shouldn't be accepted:
type a = private A of { mutable i : int } let f (A r) = r.i <- 3
The text was updated successfully, but these errors were encountered:
Comment author: @gasche
I didn't actually know that privacy prevented field mutations (I would have used this in my Xml-light patch otherwise)! Thanks.
Sorry, something went wrong.
Comment author: @alainfrisch
Fixed by commit 030f6d6. Thanks for the report!
alainfrisch
No branches or pull requests
Original bug ID: 7278
Reporter: @chambart
Assigned to: @alainfrisch
Status: closed (set by @xavierleroy on 2017-09-24T15:33:01Z)
Resolution: fixed
Priority: normal
Severity: major
Version: 4.03.0
Fixed in version: 4.04.0 +dev / +beta1 / +beta2
Category: typing
Monitored by: @gasche @hcarty
Bug description
Private records shouldn't be mutable, but the check is not applied for inline records.
For instance this shouldn't be accepted:
type a = private A of { mutable i : int }
let f (A r) = r.i <- 3
The text was updated successfully, but these errors were encountered: