summaryrefslogtreecommitdiff
path: root/src/shared/cplusplus/Array.h
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@nokia.com>2009-07-27 21:47:03 +0200
committerThiago Macieira <thiago.macieira@nokia.com>2009-08-03 14:59:42 +0200
commitd0457b70e33f1a090a91b0037e9254a0e14b8427 (patch)
tree2984b2db2129ba8cfefeac46d246a4a335b92150 /src/shared/cplusplus/Array.h
parent88549a4b1dbbb16c7d63f176fd870ec8bdb61477 (diff)
downloadqt-creator-d0457b70e33f1a090a91b0037e9254a0e14b8427.tar.gz
Compile the C++ parser library with Sun CC 5.9.
Things you mustn't do: 1) end an enum with a comma 2) #include <cxxxx> and not use std:: 3) use anonymous structures All three things are invalid C++. Anonymous structures inside anonymous unions are allowed by GCC, but that doesn't mean it's valid.
Diffstat (limited to 'src/shared/cplusplus/Array.h')
-rw-r--r--src/shared/cplusplus/Array.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/shared/cplusplus/Array.h b/src/shared/cplusplus/Array.h
index a3c66bd5ce..9fa7a657e9 100644
--- a/src/shared/cplusplus/Array.h
+++ b/src/shared/cplusplus/Array.h
@@ -77,7 +77,7 @@ public:
for (int index = 0; index <= _segmentCount; ++index) {
delete[] (_segments[index] + (index << SEGMENT_SHIFT));
}
- free(_segments);
+ std::free(_segments);
}
}
@@ -101,7 +101,7 @@ public:
if (++_count == _allocatedElements) {
if (++_segmentCount == _allocatedSegments) {
_allocatedSegments += 4;
- _segments = (_Tp **) realloc(_segments, _allocatedSegments * sizeof(_Tp *));
+ _segments = (_Tp **) std::realloc(_segments, _allocatedSegments * sizeof(_Tp *));
}
_Tp *segment = new _Tp[SEGMENT_SIZE];