53
53
#include < cstring>
54
54
#include < cctype>
55
55
56
- #ifndef OPENCV_NOSTL
57
- # include < string>
58
- #endif
56
+ #include < string>
59
57
60
58
// import useful primitives from stl
61
- #ifndef OPENCV_NOSTL_TRANSITIONAL
62
59
# include < algorithm>
63
60
# include < utility>
64
61
# include < cstdlib> // for abs(int)
@@ -81,21 +78,6 @@ namespace cv
81
78
using std::log;
82
79
}
83
80
84
- #else
85
- namespace cv
86
- {
87
- template <typename T> static inline T min (T a, T b) { return a < b ? a : b; }
88
- template <typename T> static inline T max (T a, T b) { return a > b ? a : b; }
89
- template <typename T> static inline T abs (T a) { return a < 0 ? -a : a; }
90
- template <typename T> static inline void swap (T& a, T& b) { T tmp = a; a = b; b = tmp; }
91
-
92
- template <> inline uchar abs (uchar a) { return a; }
93
- template <> inline ushort abs (ushort a) { return a; }
94
- template <> inline unsigned abs (unsigned a) { return a; }
95
- template <> inline uint64 abs (uint64 a) { return a; }
96
- }
97
- #endif
98
-
99
81
namespace cv {
100
82
101
83
// ! @addtogroup core_utils
@@ -555,7 +537,6 @@ class CV_EXPORTS String
555
537
556
538
String toLowerCase () const ;
557
539
558
- #ifndef OPENCV_NOSTL
559
540
String (const std::string& str);
560
541
String (const std::string& str, size_t pos, size_t len = npos);
561
542
String& operator =(const std::string& str);
@@ -564,7 +545,6 @@ class CV_EXPORTS String
564
545
565
546
friend String operator + (const String& lhs, const std::string& rhs);
566
547
friend String operator + (const std::string& lhs, const String& rhs);
567
- #endif
568
548
569
549
private:
570
550
char * cstr_;
@@ -1049,21 +1029,10 @@ static inline bool operator>= (const String& lhs, const char* rhs) { return lh
1049
1029
1050
1030
} // cv
1051
1031
1052
- #ifndef OPENCV_NOSTL_TRANSITIONAL
1053
1032
namespace std
1054
1033
{
1055
1034
static inline void swap (cv::String& a, cv::String& b) { a.swap (b); }
1056
1035
}
1057
- #else
1058
- namespace cv
1059
- {
1060
- template <> inline
1061
- void swap<cv::String>(cv::String& a, cv::String& b)
1062
- {
1063
- a.swap (b);
1064
- }
1065
- }
1066
- #endif
1067
1036
1068
1037
#include " opencv2/core/ptr.inl.hpp"
1069
1038
0 commit comments