summaryrefslogtreecommitdiff
path: root/libstdc++-v3/include/ext
diff options
context:
space:
mode:
Diffstat (limited to 'libstdc++-v3/include/ext')
-rw-r--r--libstdc++-v3/include/ext/atomicity.h2
-rw-r--r--libstdc++-v3/include/ext/random2
-rw-r--r--libstdc++-v3/include/ext/vstring.h8
3 files changed, 8 insertions, 4 deletions
diff --git a/libstdc++-v3/include/ext/atomicity.h b/libstdc++-v3/include/ext/atomicity.h
index 6367026c0ed..a43962724a6 100644
--- a/libstdc++-v3/include/ext/atomicity.h
+++ b/libstdc++-v3/include/ext/atomicity.h
@@ -29,6 +29,8 @@
#ifndef _GLIBCXX_ATOMICITY_H
#define _GLIBCXX_ATOMICITY_H 1
+#pragma GCC system_header
+
#include <bits/c++config.h>
#include <bits/gthr.h>
#include <bits/atomic_word.h>
diff --git a/libstdc++-v3/include/ext/random b/libstdc++-v3/include/ext/random
index 5f365e65a33..347ebed449c 100644
--- a/libstdc++-v3/include/ext/random
+++ b/libstdc++-v3/include/ext/random
@@ -791,7 +791,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
result_type
min() const
{ result_type __res;
- __res.fill(std::numeric_limits<_RealType>::min());
+ __res.fill(std::numeric_limits<_RealType>::lowest());
return __res; }
/**
diff --git a/libstdc++-v3/include/ext/vstring.h b/libstdc++-v3/include/ext/vstring.h
index 43edb53b41c..85322130cf9 100644
--- a/libstdc++-v3/include/ext/vstring.h
+++ b/libstdc++-v3/include/ext/vstring.h
@@ -557,10 +557,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
reference
operator[](size_type __pos)
{
- // allow pos == size() as v3 extension:
+ // Allow pos == size() both in C++98 mode, as v3 extension,
+ // and in C++11 mode.
_GLIBCXX_DEBUG_ASSERT(__pos <= this->size());
- // but be strict in pedantic mode:
- _GLIBCXX_DEBUG_PEDASSERT(__pos < this->size());
+ // In pedantic mode be strict in C++98 mode.
+ _GLIBCXX_DEBUG_PEDASSERT(__cplusplus >= 201103L
+ || __pos < this->size());
this->_M_leak();
return this->_M_data()[__pos];
}