www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 18665] New: Deprecate the undocumented opCom to specify

https://issues.dlang.org/show_bug.cgi?id=18665

          Issue ID: 18665
           Summary: Deprecate the undocumented opCom to specify
                    user-defined negation in favor of opUnary
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: dmd
          Assignee: nobody puremagic.com
          Reporter: greensunny12 gmail.com

Looks like DMD supports explicitly overloading ~ with opCom:

https://github.com/dlang/dmd/blob/25bc0213a7455b8ccbb9a4cc869c86ecc24c6777/src/dmd/expression.d#L5756

- It's only used on std.bitmanip
- It's not mentioned in the spec
- It doesn't appear on Google

This should be deprecated in favor of opUnary

--
Mar 26 2018