Thread overview | |||||
---|---|---|---|---|---|
|
February 15, 2024 [Issue 24393] Going into ROM operator overload | ||||
---|---|---|---|---|
| ||||
https://issues.dlang.org/show_bug.cgi?id=24393 RazvanN <razvan.nitu1305@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |razvan.nitu1305@gmail.com --- Comment #1 from RazvanN <razvan.nitu1305@gmail.com> --- I fail to see how implementing opGoingIntoROM is gonna help either of the 2 mentioned cases. What can user code do to instruct LDC to put the data in ROM? -- |
February 15, 2024 [Issue 24393] Going into ROM operator overload | ||||
---|---|---|---|---|
| ||||
https://issues.dlang.org/show_bug.cgi?id=24393 --- Comment #2 from Richard Cattermole <alphaglosined@gmail.com> --- You have that backward. When you are going to mark memory as immutable (and with that potentially flagged as read only at CPU level), an object needs to be able to alter its behavior with respect to this. That is what this method does, it allows it to turn off the mutex so that it always locks/unlocks without mutation, and to turn off the reference count. It also means if disabled or missing that the type does not support being in ROM and hence cannot be immutable. So we kinda have three options as I see it: 1. Add some way for the object to adjust itself, so that immutable actually does mean process-wide immutability for a given object. 2. Disallow reference counting and Object to ever be immutable. We would of course need some way of detecting reference counting and that means we need it in the language. 3. Remove immutable as it doesn't offer the guarantees that the spec says it does (and cannot). This ticket focusses on the first one, as it doesn't break code and strengthens what guarantees the language "offers". -- |
December 13 [Issue 24393] Going into ROM operator overload | ||||
---|---|---|---|---|
| ||||
https://issues.dlang.org/show_bug.cgi?id=24393 --- Comment #3 from dlangBugzillaToGithub <robert.schadek@posteo.de> --- THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/18214 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB -- |
Copyright © 1999-2021 by the D Language Foundation