Bug 23036 – Rvalue constructor with default parameter crashes compiler in the presence of a copy constructor

Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2022-04-19T05:21:08Z
Last change time
2024-11-28T08:03:37Z
Keywords
pull
Assigned to
No Owner
Creator
RazvanN
See also
https://issues.dlang.org/show_bug.cgi?id=19931, https://issues.dlang.org/show_bug.cgi?id=19871

Comments

Comment #0 by razvan.nitu1305 — 2022-04-19T05:21:08Z
Comment #1 by razvan.nitu1305 — 2022-04-19T05:21:26Z
struct S { this(ref S) {} this(S, int a = 2) {} } void main() { S a; S b = a; }
Comment #2 by razvan.nitu1305 — 2022-04-19T05:25:51Z
Regression since 2.086.1
Comment #3 by dlang-bot — 2022-04-19T05:40:49Z
@RazvanN7 created dlang/dmd pull request #14011 "Fix Issue 23036 - [REG2.086]Rvalue constructor with default parameter…" fixing this issue: - Fix Issue 23036 - [REG2.086]Rvalue constructor with default parameter crashes compiler in the presence of a copy constructor https://github.com/dlang/dmd/pull/14011
Comment #4 by dlang-bot — 2022-04-19T09:27:26Z
dlang/dmd pull request #14011 "Fix Issue 23036 - [REG2.086]Rvalue constructor with default parameter…" was merged into master: - 2d9bb00a46284e27042fa30b1e0a82ce16a20fd0 by RazvanN7: Fix Issue 23036 - [REG2.086]Rvalue constructor with default parameter crashes compiler in the presence of a copy constructor https://github.com/dlang/dmd/pull/14011