[LLVMbugs] [Bug 9115] New: confusing diagnostic for extra qualification on member

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Tue Feb 1 04:10:18 PST 2011


http://llvm.org/bugs/show_bug.cgi?id=9115

           Summary: confusing diagnostic for extra qualification on member
           Product: clang
           Version: trunk
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: reif at earthlink.net
                CC: llvmbugs at cs.uiuc.edu, dgregor at apple.com


For this code:

class MyClass {
public:
MyClass::MyClass();
};

g++ gives:

test.cpp:3: error: extra qualification ‘MyClass::’ on member ‘MyClass’

and comeau gives:

"ComeauTest.c", line 3: error: qualified name is not allowed in member
declaration
      MyClass::MyClass();

but clang++ gives:

test.cpp:3:22: error: expected member name or ';' after declaration specifiers
MyClass::MyClass();
~~~~~~~~~~~~~~~~ ^
1 error generated.

which is confusing.

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list