[PATCH 15/15] librados/librados.cc: fix implicitly-defined namespace 'std'

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Fix warning from clang(++):

librados/librados.cc:15:17: warning: using directive refers to
 implicitly-defined namespace 'std'
using namespace std;
                ^
Include what we need and use the related classes.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@xxxxxxxxx>
---
 src/librados/librados.cc | 16 ++++++++++++++--
 1 file changed, 14 insertions(+), 2 deletions(-)

diff --git a/src/librados/librados.cc b/src/librados/librados.cc
index 0ac6eb4..5a81a26 100644
--- a/src/librados/librados.cc
+++ b/src/librados/librados.cc
@@ -12,8 +12,6 @@
  *
  */
 
-using namespace std;
-
 #include "common/config.h"
 #include "common/errno.h"
 #include "common/ceph_argparse.h"
@@ -27,6 +25,20 @@ using namespace std;
 #include "librados/PoolAsyncCompletionImpl.h"
 #include "librados/RadosClient.h"
 
+#include <string>
+#include <map>
+#include <set>
+#include <vector>
+#include <list>
+#include <stdexcept>
+
+using std::string;
+using std::map;
+using std::set;
+using std::vector;
+using std::list;
+using std::runtime_error;
+
 #define dout_subsys ceph_subsys_rados
 #undef dout_prefix
 #define dout_prefix *_dout << "librados: "
-- 
1.8.1.2

--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [CEPH Users]     [Ceph Large]     [Information on CEPH]     [Linux BTRFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux