diff options
author | Brad King <brad.king@kitware.com> | 2021-01-26 14:08:34 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2021-01-26 14:08:39 (GMT) |
commit | bd29de1a9147a575454a73f673bc1a90d842d725 (patch) | |
tree | 043c28f7b660591e005da98c301239f3a119584f | |
parent | 9792c7df4ef361388ab1f47ba50674245aa8e95a (diff) | |
parent | b7d4ee23d859c8734ef8d625466739808093bc57 (diff) | |
download | CMake-bd29de1a9147a575454a73f673bc1a90d842d725.zip CMake-bd29de1a9147a575454a73f673bc1a90d842d725.tar.gz CMake-bd29de1a9147a575454a73f673bc1a90d842d725.tar.bz2 |
Merge topic 'cm-optional-warning'
b7d4ee23d8 cm::optional: Fix `-Wunused-parameter` warnings in comparison operators
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: Kyle Edwards <kyle.edwards@kitware.com>
Merge-request: !5739
-rw-r--r-- | Utilities/std/cm/optional | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Utilities/std/cm/optional b/Utilities/std/cm/optional index 0defae1..2ebc78c 100644 --- a/Utilities/std/cm/optional +++ b/Utilities/std/cm/optional @@ -313,7 +313,7 @@ bool operator!=(const optional<T>& opt, nullopt_t) noexcept } template <typename T> -bool operator<(const optional<T>& opt, nullopt_t) noexcept +bool operator<(const optional<T>& /*opt*/, nullopt_t) noexcept { return false; } @@ -331,7 +331,7 @@ bool operator>(const optional<T>& opt, nullopt_t) noexcept } template <typename T> -bool operator>=(const optional<T>& opt, nullopt_t) noexcept +bool operator>=(const optional<T>& /*opt*/, nullopt_t) noexcept { return true; } @@ -355,13 +355,13 @@ bool operator<(nullopt_t, const optional<T>& opt) noexcept } template <typename T> -bool operator<=(nullopt_t, const optional<T>& opt) noexcept +bool operator<=(nullopt_t, const optional<T>& /*opt*/) noexcept { return true; } template <typename T> -bool operator>(nullopt_t, const optional<T>& opt) noexcept +bool operator>(nullopt_t, const optional<T>& /*opt*/) noexcept { return false; } |