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

             Bug #: 12539
           Summary: Literal operator templates are never searched
           Product: clang
           Version: trunk
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++11
        AssignedTo: [email protected]
        ReportedBy: [email protected]
                CC: [email protected], [email protected]
    Classification: Unclassified


The following code should compile and run by the standard (13.5.8p5), but clang
rejects it with "error: no matching literal operator for call to 'operator ""
_x' with arguments of types 'const char *' and 'unsigned long'". Adding those
parameters, in violation of the standard, causes clang to reject it because of
that same violation.


template<char... Args>
int operator"" _x()
{
  return 1;
}

int main()
{
  return "asdf"_x;
}

-- 
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.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs

Reply via email to