[llvm-bugs] [Bug 27027] New: Block scope operator function ignored by lookup for infix notation

via llvm-bugs llvm-bugs at lists.llvm.org
Tue Mar 22 04:03:21 PDT 2016


https://llvm.org/bugs/show_bug.cgi?id=27027

            Bug ID: 27027
           Summary: Block scope operator function ignored by lookup for
                    infix notation
           Product: clang
           Version: trunk
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
          Assignee: unassignedclangbugs at nondot.org
          Reporter: r.hl at gmx.net
                CC: dgregor at apple.com, llvm-bugs at lists.llvm.org
    Classification: Unclassified

struct bar {};

void wot(bar x, bar y)
{
  bool operator+(bar, bar);
  x + y; // <<-- invalid operands to binary expression
}

---------------------------------------------------

This is spuriously rejected, although the local operator+ is a candidate as per
[over.match.oper]/(3.2). Fails for all binary operators.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20160322/eed5ee17/attachment.html>


More information about the llvm-bugs mailing list