July 30, 2018 [Issue 19129] New: std.typecons.scoped crashes when used on classes that have context | ||||
---|---|---|---|---|
| ||||
https://issues.dlang.org/show_bug.cgi?id=19129 Issue ID: 19129 Summary: std.typecons.scoped crashes when used on classes that have context Product: D Version: D2 Hardware: All URL: http://dlang.org/ OS: All Status: NEW Severity: major Priority: P3 Component: phobos Assignee: nobody@puremagic.com Reporter: eyal@weka.io Example: int y; class C { this(int x) { y = x; } } import std.typecons: scoped; scoped!C(1); // crashes, as ctx.y segfaults when ctx remains null scoped should probably reject classes that have a "this" member (that aren't `static class`). -- |
Copyright © 1999-2021 by the D Language Foundation