Bug 24680 – [dip1000] final auto class method infers scope but no return

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P1
Component
dlang.org
Product
D
Version
D2
Platform
All
OS
All
Creation time
2024-07-24T19:05:44Z
Last change time
2024-07-29T15:22:24Z
Keywords
pull
Assigned to
No Owner
Creator
Dennis

Comments

Comment #0 by dkorpel — 2024-07-24T19:05:44Z
```D class C { final auto peek(ubyte[] buf) { return buf; } } @safe escape(C c) { ubyte[5] buf; return c.peek(buf[]); } ``` This should error, but it only does when you remove `final`
Comment #1 by dlang-bot — 2024-07-24T19:15:01Z
@dkorpel created dlang/dmd pull request #16751 "Fix bugzilla 24680 - [dip1000] final auto class method infers scope b…" fixing this issue: - Fix bugzilla 24680 - [dip1000] final auto class method infers scope but no return https://github.com/dlang/dmd/pull/16751
Comment #2 by dlang-bot — 2024-07-29T15:22:24Z
dlang/dmd pull request #16751 "Fix bugzilla 24680 - [dip1000] final auto class method infers scope b…" was merged into master: - 01ebf8dbba04faad8b6f0fac7d521c847f4a77d6 by Dennis Korpel: Fix bugzilla 24680 - [dip1000] final auto class method infers scope but no return https://github.com/dlang/dmd/pull/16751