]> git.ipfire.org Git - thirdparty/gcc.git/blobdiff - libstdc++-v3/testsuite/21_strings/basic_string/requirements/exception/basic.cc
Update copyright years.
[thirdparty/gcc.git] / libstdc++-v3 / testsuite / 21_strings / basic_string / requirements / exception / basic.cc
index 1f6b970d2bfcc44beec5a85a493bb3d1fecd72e2..9edd5f85eb3d8681d2f7478cb67ceb8205ea178b 100644 (file)
@@ -1,9 +1,9 @@
-// { dg-options "-std=gnu++0x" }
+// { dg-do run { target c++11 } }
 // { dg-require-cstdint "" }
 
 // 2009-11-10  Benjamin Kosnik  <benjamin@redhat.com>
 
-// Copyright (C) 2009 Free Software Foundation, Inc.
+// Copyright (C) 2009-2020 Free Software Foundation, Inc.
 //
 // This file is part of the GNU ISO C++ Library.  This library is free
 // software; you can redistribute it and/or modify it under the
@@ -26,7 +26,9 @@
 void
 value()
 {
-  typedef __gnu_cxx::throw_value_limit value_type;
+  // NB: Instantiating with __gnu_cxx::throw_value_limit would be illegal,
+  // isn't a POD type.
+  typedef char value_type;
   typedef __gnu_cxx::throw_allocator_limit<value_type> allocator_type;
   typedef std::char_traits<value_type> traits_type;
   typedef std::basic_string<value_type, traits_type, allocator_type> test_type;