[Issue 19606] New: Bad error message when two identical overloads exist as `@disable` and not

d-bugmail at puremagic.com d-bugmail at puremagic.com
Wed Jan 23 10:03:00 UTC 2019


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

          Issue ID: 19606
           Summary: Bad error message when two identical overloads exist
                    as `@disable` and not
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Keywords: diagnostic
          Severity: minor
          Priority: P1
         Component: dmd
          Assignee: nobody at puremagic.com
          Reporter: b2.temp at gmx.com

code:

    class Foo
    {
        @disable this();
        this(){}
    }

    void main()
    {
        Foo foo = new Foo;
    } 

> Error: `runnable.Foo.__ctor` called with argument types `()` matches both:

I think that the compiler should detect an error before this one and rather
complain that the same function exists as `@disable` and not.

--


More information about the Digitalmars-d-bugs mailing list