build: prefer nodiscard over warn_unused_result
This commit is contained in:
parent
fd03c344b2
commit
8c8a252d9f
@ -63,8 +63,8 @@ namespace util::posix {
|
|||||||
int release (void);
|
int release (void);
|
||||||
|
|
||||||
//---------------------------------------------------------------------
|
//---------------------------------------------------------------------
|
||||||
[[gnu::warn_unused_result]] ssize_t read (void *buf, size_t count);
|
[[nodiscard]] ssize_t read (void *buf, size_t count);
|
||||||
[[gnu::warn_unused_result]] ssize_t write (const void *buf, size_t count);
|
[[nodiscard]] ssize_t write (const void *buf, size_t count);
|
||||||
|
|
||||||
|
|
||||||
//---------------------------------------------------------------------
|
//---------------------------------------------------------------------
|
||||||
|
@ -81,8 +81,8 @@ namespace util {
|
|||||||
~signal ();
|
~signal ();
|
||||||
|
|
||||||
/// Add a callback to list.
|
/// Add a callback to list.
|
||||||
cookie connect [[gnu::warn_unused_result]] (callback&&);
|
cookie connect [[nodiscard]] (callback&&);
|
||||||
cookie connect [[gnu::warn_unused_result]] (const callback&);
|
cookie connect [[nodiscard]] (const callback&);
|
||||||
|
|
||||||
void disconnect (cookie&);
|
void disconnect (cookie&);
|
||||||
|
|
||||||
|
2
view.hpp
2
view.hpp
@ -288,7 +288,7 @@ namespace util {
|
|||||||
}
|
}
|
||||||
|
|
||||||
//---------------------------------------------------------------------
|
//---------------------------------------------------------------------
|
||||||
[[gnu::warn_unused_result]] constexpr auto
|
[[nodiscard]] constexpr auto
|
||||||
redim (size_type count) const
|
redim (size_type count) const
|
||||||
{
|
{
|
||||||
assert (count > 0);
|
assert (count > 0);
|
||||||
|
Loading…
Reference in New Issue
Block a user