Closed
Description
Affected rules
- A13-2-2
Description
A false positive alert is reported for the following code example which is not trying to implement a bitwise or arithmetic operator:
User-defined bitwise or arithmetic operator test::operator<<(ostream &, const Test &) -> ostream & does not return a prvalue.
Example
#include <ostream>
namespace test {
struct Test {};
std::ostream& operator<<(std::ostream& os, const Test&) { // A13-2-2 reported here
os << "test";
return os;
}
} // namespace test