Bug 20691 – Converting scope static array to scope dynamic array should be error
Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2020-03-21T08:08:49Z
Last change time
2021-08-27T14:02:50Z
Keywords
pull, safe
Assigned to
No Owner
Creator
Walter Bright
Comments
Comment #0 by bugzilla — 2020-03-21T08:08:49Z
void bar() @safe
{
scope char[][2] sa;
scope char[][] da = sa; // should give error
}
Comment #1 by bugzilla — 2020-03-21T08:15:48Z
-preview=dip1000 too
Comment #2 by dlang-bot — 2020-03-21T08:16:28Z
@WalterBright created dlang/dmd pull request #10951 "fix Issue 20691 - Converting scope static array to scope dynamic arra…" fixing this issue:
- fix Issue 20691 - Converting scope static array to scope dynamic array should be error
https://github.com/dlang/dmd/pull/10951
Comment #3 by pro.mathias.lang — 2020-03-21T08:55:10Z
Why ?
Comment #4 by pro.mathias.lang — 2020-03-21T08:57:57Z
I see you commented on 20505. Why open a new issue then ? Let's keep the discussion in one place.
*** This issue has been marked as a duplicate of issue 20505 ***
Comment #5 by dlang-bot — 2021-08-27T14:02:50Z
dlang/dmd pull request #10951 "fix Issue 20691 - Converting scope static array to scope dynamic arra…" was merged into master:
- 4da2034d14e9a9aa19260fde343b5fc6b613201f by Walter Bright:
fix Issue 20691 - Converting scope static array to scope dynamic array should be error
https://github.com/dlang/dmd/pull/10951