Issue 170825
Summary [clang-tidy] cppcoreguidelines-rvalue-reference-param-not-moved complains about move ctor parameter
Labels clang-tidy
Assignees
Reporter Febbe
    llvm v.: 20

The cppcoreguidelines-rvalue-reference-param-not-moved complains about the following move ctor.
The nl_socket has only trivial fields.

```
auto
nl_socket::operator==(nl_socket && other) noexcept -> nl_socket &
{
    nl_socket_close(this);
    this->fd    = std::exchange(other.fd, -1);
    this->local = other.local;
    return *this;
}
```

_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to