Skip to content

Commit

Permalink
Synchronize reference qualification of operator= to docs
Browse files Browse the repository at this point in the history
  • Loading branch information
dtolnay committed Feb 8, 2025
1 parent 7599a50 commit f8f351e
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion book/src/binding/box.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public:
explicit Box(const T &);
explicit Box(T &&);
Box &operator=(Box &&) noexcept;
Box &operator=(Box &&) & noexcept;
const T *operator->() const noexcept;
const T &operator*() const noexcept;
Expand Down
4 changes: 2 additions & 2 deletions book/src/binding/result.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,8 @@ public:
Error(Error &&) noexcept;
~Error() noexcept;
Error &operator=(const Error &);
Error &operator=(Error &&) noexcept;
Error &operator=(const Error &) &;
Error &operator=(Error &&) & noexcept;
const char *what() const noexcept override;
};
Expand Down
4 changes: 2 additions & 2 deletions book/src/binding/slice.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ public:
template <typename C>
explicit Slice(C &c) : Slice(c.data(), c.size());
Slice &operator=(Slice<T> &&) noexcept;
Slice &operator=(const Slice<T> &) noexcept
Slice &operator=(Slice<T> &&) & noexcept;
Slice &operator=(const Slice<T> &) & noexcept
requires std::is_const_v<T>;
T *data() const noexcept;
Expand Down
2 changes: 1 addition & 1 deletion book/src/binding/str.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public:
Str(const char *);
Str(const char *, size_t);
Str &operator=(const Str &) noexcept;
Str &operator=(const Str &) & noexcept;
explicit operator std::string() const;
Expand Down
4 changes: 2 additions & 2 deletions book/src/binding/string.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ public:
static String lossy(const char16_t *) noexcept;
static String lossy(const char16_t *, size_t) noexcept;
String &operator=(const String &) noexcept;
String &operator=(String &&) noexcept;
String &operator=(const String &) & noexcept;
String &operator=(String &&) & noexcept;
explicit operator std::string() const;
Expand Down
4 changes: 2 additions & 2 deletions book/src/binding/vec.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ public:
Vec(Vec &&) noexcept;
~Vec() noexcept;
Vec &operator=(Vec &&) noexcept;
Vec &operator=(const Vec &);
Vec &operator=(Vec &&) & noexcept;
Vec &operator=(const Vec &) &;
size_t size() const noexcept;
bool empty() const noexcept;
Expand Down

0 comments on commit f8f351e

Please sign in to comment.