July 20, 2022 [Issue 23260] New: If constructors have a function body, they should infer attributes | ||||
|---|---|---|---|---|
| ||||
https://issues.dlang.org/show_bug.cgi?id=23260 Issue ID: 23260 Summary: If constructors have a function body, they should infer attributes Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: enhancement Priority: P1 Component: dmd Assignee: nobody@puremagic.com Reporter: bugzilla@digitalmars.com struct S { int a; this(int a) { } } @safe test() { S s = S(1); // ctor attribute inference will let this compile } -- | ||||
Copyright © 1999-2021 by the D Language Foundation
Permalink
Reply