mirror of
https://github.com/HDFGroup/hdf5.git
synced 2025-04-18 17:40:55 +08:00
[svn-r11264] Purpose: Additional code improvement
Description: Used "using" declaration and directive better to reduce namespace pollution. Platforms tested: Linux 2.4 (heping) SunOS 5.8 64-bit (sol)
This commit is contained in:
parent
f27f7c7821
commit
6496413284
@ -33,6 +33,9 @@
|
||||
|
||||
#ifndef H5_NO_NAMESPACE
|
||||
namespace H5 {
|
||||
#ifndef H5_NO_STD
|
||||
using namespace std;
|
||||
#endif // H5_NO_STD
|
||||
#endif
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
|
@ -35,6 +35,9 @@
|
||||
|
||||
#ifndef H5_NO_NAMESPACE
|
||||
namespace H5 {
|
||||
#ifndef H5_NO_STD
|
||||
using namespace std;
|
||||
#endif // H5_NO_STD
|
||||
#endif
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
|
@ -26,6 +26,9 @@
|
||||
|
||||
#ifndef H5_NO_NAMESPACE
|
||||
namespace H5 {
|
||||
#ifndef H5_NO_STD
|
||||
using namespace std;
|
||||
#endif // H5_NO_STD
|
||||
#endif
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
|
@ -34,6 +34,9 @@
|
||||
|
||||
#ifndef H5_NO_NAMESPACE
|
||||
namespace H5 {
|
||||
#ifndef H5_NO_STD
|
||||
using namespace std;
|
||||
#endif // H5_NO_STD
|
||||
#endif
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
|
@ -21,7 +21,7 @@
|
||||
#ifndef H5_NO_NAMESPACE
|
||||
namespace H5 {
|
||||
#ifndef H5_NO_STD
|
||||
using namespace std;
|
||||
using std::string;
|
||||
#endif // H5_NO_STD
|
||||
#endif
|
||||
|
||||
|
@ -38,6 +38,9 @@
|
||||
|
||||
#ifndef H5_NO_NAMESPACE
|
||||
namespace H5 {
|
||||
#ifndef H5_NO_STD
|
||||
using namespace std;
|
||||
#endif // H5_NO_STD
|
||||
#endif
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
|
@ -38,6 +38,9 @@
|
||||
|
||||
#ifndef H5_NO_NAMESPACE
|
||||
namespace H5 {
|
||||
#ifndef H5_NO_STD
|
||||
using namespace std;
|
||||
#endif // H5_NO_STD
|
||||
#endif
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
|
@ -61,10 +61,18 @@ class H5_DLLCPP IdComponent {
|
||||
|
||||
// Makes and returns the string "<class-name>::<func_name>";
|
||||
// <class-name> is returned by fromClass().
|
||||
#ifdef H5_NO_STD
|
||||
string inMemFunc(const char* func_name) const;
|
||||
#else
|
||||
std::string inMemFunc(const char* func_name) const;
|
||||
#endif // H5_NO_STD
|
||||
|
||||
// Returns this class name.
|
||||
#ifdef H5_NO_STD
|
||||
virtual string fromClass() const {return ("IdComponent");}
|
||||
#else
|
||||
virtual std::string fromClass() const {return ("IdComponent");}
|
||||
#endif // H5_NO_STD
|
||||
|
||||
#endif // DOXYGEN_SHOULD_SKIP_THIS
|
||||
|
||||
|
@ -26,6 +26,9 @@
|
||||
|
||||
#ifndef H5_NO_NAMESPACE
|
||||
namespace H5 {
|
||||
#ifndef H5_NO_STD
|
||||
using namespace std;
|
||||
#endif // H5_NO_STD
|
||||
#endif
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
|
Loading…
x
Reference in New Issue
Block a user