May 12 [Issue 24548] New: [spec] Boolean condition conversion is not documented | ||||
---|---|---|---|---|
| ||||
https://issues.dlang.org/show_bug.cgi?id=24548 Issue ID: 24548 Summary: [spec] Boolean condition conversion is not documented Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW Severity: minor Priority: P1 Component: dlang.org Assignee: nobody@puremagic.com Reporter: nick@geany.org E.g. for IfStatement, the spec just says: > Expression is evaluated. The result is converted to a boolean, using opCast!bool() if the method is defined. That is insufficient information. It should specify which types can be converted to bool, and how. PR incoming. -- |
Copyright © 1999-2021 by the D Language Foundation