]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
c++11: fixes for std::pair type conversions
authorCasey Bodley <cbodley@redhat.com>
Thu, 30 Jul 2015 20:29:55 +0000 (16:29 -0400)
committerCasey Bodley <cbodley@redhat.com>
Mon, 3 Aug 2015 15:16:13 +0000 (11:16 -0400)
mds_rank_t is no longer a BOOST_STRONG_TYPEDEF, because that was
preventing the conversion between pairs of int and pairs of mds_rank_t

Signed-off-by: Casey Bodley <cbodley@redhat.com>
src/common/ceph_json.h
src/mds/mdstypes.h
src/rgw/rgw_cache.cc

index 4bc0b9a863a7cdf3dc93dc99dcfe62b95973b7a8..e69055b1611ba59c99ac37ac3b93e0d3a51b5edc 100644 (file)
@@ -198,7 +198,7 @@ void decode_json_obj(multimap<K, V>& m, JSONObj *obj)
     JSONObj *o = *iter;
     JSONDecoder::decode_json("key", key, o);
     JSONDecoder::decode_json("val", val, o);
-    m.insert(make_pair<K, V>(key, val));
+    m.insert(make_pair(key, val));
   }
 }
 
index fbba7887d73deb4b39ffc8b1d26c65fbc10dcd81..e0a421fdd85fe2a69afca342669a65982963aabd 100644 (file)
@@ -74,7 +74,7 @@
 #define MDS_TRAVERSE_DISCOVERXLOCK 3    // succeeds on (foreign?) null, xlocked dentries.
 
 
-BOOST_STRONG_TYPEDEF(int32_t, mds_rank_t)
+typedef int32_t mds_rank_t;
 BOOST_STRONG_TYPEDEF(uint64_t, mds_gid_t)
 extern const mds_gid_t MDS_GID_NONE;
 extern const mds_rank_t MDS_RANK_NONE;
index c3f3b06ffc88bb654d9320999e3768911bf12331..03c3b050e3fd65b6d9bc3af4a14ffe7879592272 100644 (file)
@@ -105,7 +105,7 @@ bool ObjectCache::chain_cache_entry(list<rgw_cache_entry_info *>& cache_info_ent
   for (liter = cache_entry_list.begin(); liter != cache_entry_list.end(); ++liter) {
     ObjectCacheEntry *entry = *liter;
 
-    entry->chained_entries.push_back(make_pair<RGWChainedCache *, string>(chained_entry->cache, chained_entry->key));
+    entry->chained_entries.push_back(make_pair(chained_entry->cache, chained_entry->key));
   }
 
   return true;