[LLVMbugs] [Bug 8048] New: clang++ incorrectly deduces template argument to local type

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Tue Aug 31 23:58:55 PDT 2010


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

           Summary: clang++ incorrectly deduces template argument to local
                    type
           Product: clang
           Version: unspecified
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: sharparrow1 at yahoo.com
                CC: llvmbugs at cs.uiuc.edu, dgregor at apple.com


Testcase:
template<class T> void f(T t);
void g() { enum { E }; f(E); }

clang incorrectly accepts this.  Comeau rejects with "error: a template
argument may not reference a local type".  Invalid per [temp.arg.type]p2.

-- 
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