[Issue 13084] ModuleInfo.opApply delegate expects immutable parameter

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Fri Jul 11 05:50:03 PDT 2014


https://issues.dlang.org/show_bug.cgi?id=13084

--- Comment #3 from Kenji Hara <k.hara.pg at gmail.com> ---
(In reply to Jacob Carlborg from comment #2)
> I assumed that, but i still breaks code. What about the standard deprecation
> cycle?

Unfortunately, it's impossible. We cannot allow iterating both mutable and
immutable objects by ModuleInfo.opApply, because it will cause type system 
violation. We should change the opApply signature all at once.

And compiler already place all ModuleInfo in read-only section. So modifying
ModuleInfo will cause segfault in some platforms. It's more worse.

--


More information about the Digitalmars-d-bugs mailing list