Bug 24891 – Two scope attributes emitted as part of .di generation

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2024-12-05T11:21:59Z
Last change time
2024-12-05T18:44:47Z
Keywords
pull
Assigned to
No Owner
Creator
Richard (Rikki) Andrew Cattermole

Comments

Comment #0 by alphaglosined — 2024-12-05T11:21:59Z
dmd -o- -Hd=imports str.d ```d module str; struct String { export: nothrow @nogc: @safe: this(return scope ref typeof(this) other) @trusted scope { } } ``` Results in: ```d // D import file generated from 'str.d' module str; struct String { export nothrow @nogc @safe scope scope @trusted this(ref return scope typeof(this) other); } ``` As of dmd 2.109.1
Comment #1 by alphaglosined — 2024-12-05T11:28:15Z
Another example: ```d @disable this(ref return scope const typeof(this) other) scope const; ``` Into: ```d scope @disable const scope this(ref return scope const typeof(this) other); ``` And: ```d export: nothrow @safe: @disable this(ref return scope typeof(this) other) @safe scope const; ``` Into: ```d export { nothrow @safe { scope @nogc scope @trusted this(ref return scope typeof(this) other); } } ```
Comment #2 by dlang-bot — 2024-12-05T13:35:25Z
@dkorpel created dlang/dmd pull request #17105 "Fix bugzilla 24891 - Two scope attributes emitted as part of .di gene…" fixing this issue: - Fix bugzilla 24891 - Two scope attributes emitted as part of .di generation https://github.com/dlang/dmd/pull/17105
Comment #3 by dominikus — 2024-12-05T15:50:00Z
Why are still issues created on bugzilla? I thought everything should now use the git repository. Or what else was the plan with the migration?
Comment #4 by dlang-bot — 2024-12-05T17:18:02Z
dlang/dmd pull request #17105 "Fix bugzilla 24891 - Two scope attributes emitted as part of .di gene…" was merged into master: - 869ed9c6b9e4622e3cce1906264b13ee15b4b004 by Dennis Korpel: Fix bugzilla 24891 - Two scope attributes emitted as part of .di generation https://github.com/dlang/dmd/pull/17105
Comment #5 by nick — 2024-12-05T18:44:47Z
@Dominikus Dittes Scherkl - only Phobos issues have moved to GH.