]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Protect optional's deduction guide with the feature macro
authorVille Voutilainen <ville.voutilainen@gmail.com>
Wed, 3 Jan 2018 20:33:10 +0000 (22:33 +0200)
committerVille Voutilainen <ville@gcc.gnu.org>
Wed, 3 Jan 2018 20:33:10 +0000 (22:33 +0200)
* include/std/optional: Use the feature macro.

From-SVN: r256185

libstdc++-v3/ChangeLog
libstdc++-v3/include/std/optional

index f603e316f109a576abc4b88a5cf1e27f5a69f137..64fa7204d84e147c187f9723e6c10d2ddd1170e1 100644 (file)
@@ -1,3 +1,8 @@
+2018-01-03  Ville Voutilainen  <ville.voutilainen@gmail.com>
+
+       Protect optional's deduction guide with the feature macro
+       * include/std/optional: Use the feature macro.
+
 2018-01-03  Jakub Jelinek  <jakub@redhat.com>
 
        Update copyright years.
index 76b2b0e498d47683d82e9c6782d7ac5096cad93c..466a11c1e5f2d8f096b66532a1c4cddfdc02889e 100644 (file)
@@ -1038,7 +1038,9 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
 
   /// @}
 
+#if __cpp_deduction_guides >= 201606
   template <typename _Tp> optional(_Tp) -> optional<_Tp>;
+#endif
 
 _GLIBCXX_END_NAMESPACE_VERSION
 } // namespace std