]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
osd/HitSet: mark copy ctor of HitSet::Params noexcept
authorKefu Chai <kchai@redhat.com>
Tue, 29 Jan 2019 09:18:21 +0000 (17:18 +0800)
committerKefu Chai <kchai@redhat.com>
Tue, 29 Jan 2019 12:04:53 +0000 (20:04 +0800)
to be returned using seastar::future<...> the value type should satisfy
std::is_nothrow_constructible<T>.

with this change, pg_pool_t will be nothrow_constructible. and hence
can be returned using seastar::future<pg_pool_t>. otherwise
std::is_nothrow_constructible<pg_pool_t>::value would be false.

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/osd/HitSet.cc
src/osd/HitSet.h

index 227a738769b6ceb489a0f08f1db02b6caa1e4e1b..653c4448d38a36a901159e414c824889e995422a 100644 (file)
@@ -107,7 +107,7 @@ void HitSet::generate_test_instances(list<HitSet*>& o)
   o.back()->insert(hobject_t("qwer", "", CEPH_NOSNAP, 456, 1, ""));
 }
 
-HitSet::Params::Params(const Params& o)
+HitSet::Params::Params(const Params& o) noexcept
 {
   if (o.get_type() != TYPE_NONE) {
     create_impl(o.get_type());
index 943f40647141f8c2b5f3cac9012c77b0090ccb81..7e50fd930adfa3286231a0e206f8245f787a3cfe 100644 (file)
@@ -104,7 +104,7 @@ public:
       return TYPE_NONE;
     }
 
-    Params(const Params& o);
+    Params(const Params& o) noexcept;
     const Params& operator=(const Params& o);
 
     void encode(bufferlist &bl) const;