[Issue 23722] Lambdas are mangled incorrectly when using multiple compilation units, resulting in incorrect code
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Wed Nov 20 15:20:30 UTC 2024
https://issues.dlang.org/show_bug.cgi?id=23722
--- Comment #7 from ilya.yanok at gmail.com ---
(In reply to kinke from comment #6)
> Yes, I fixed the first issue (different lambdas getting the same mangle and
> incorrectly being folded at link-time) in LDC v1.33:
> https://github.com/ldc-developers/ldc/pull/4415
Cool! But that won't help with lambda names leaking into template
instantiations' symbol via arguments unfortunately. So I think we really need
lambda names to be stable (which the PR does).
I was actually curious about the second issue: LDC seems to generate the code
for
alias f = () { ... }
for all modules that use `f`, while dmd only generates it if a module that uses
`f` is compiled together with the module that defines it (or if that's the same
module). Do you happen to know where does this difference come from?
--
More information about the Digitalmars-d-bugs
mailing list