Commit Graph

3127 Commits

Author SHA1 Message Date
Jonathan Wakely 744e26e71e re PR libstdc++/65630 (operator+ for new std::string not exported)
PR libstdc++/65630
	* config/abi/pre/gnu.ver: Export operator+ for new strings.
	* testsuite/21_strings/basic_string/operators/char/65630.cc: New.
	* testsuite/21_strings/basic_string/operators/wchar_t/65630.cc: New.

From-SVN: r221775
2015-03-30 18:52:37 +01:00
Tim Shen 2894311302 re PR libstdc++/65420 (Enumerators in std::regex_constants should be constexpr variables instead)
PR libstdc++/65420
	* include/bits/regex_constants.h: Use constexpr variables for flags.
	* testsuite/28_regex/constants/constexpr.cc: New testcase.

From-SVN: r221750
2015-03-28 04:17:12 +00:00
Jonathan Wakely 04f69fda7a re PR libstdc++/65499 (Missing "using namespace literals::chrono_literals" in std::chrono)
PR libstdc++/65499
	* include/std/chrono: Add using-directive for literals to std::chrono.
	* testsuite/20_util/duration/literals/65499.cc: New.

From-SVN: r221730
2015-03-27 12:45:10 +00:00
Jonathan Wakely d1a74a287e re PR libstdc++/58038 (std::this_thread::sleep_until can cause inifinite sleep)
PR libstdc++/58038
	PR libstdc++/60421
	* include/std/thread (this_thread::sleep_for): Check for negative
	durations.
	(this_thread::sleep_until): Check for times in the past.
	* testsuite/30_threads/this_thread/58038.cc: New.
	* testsuite/30_threads/this_thread/60421.cc: New.

From-SVN: r221708
2015-03-26 19:59:08 +00:00
Jonathan Wakely 4280698d09 re PR libstdc++/62259 (atomic class doesn't enforce required alignment on powerpc64)
PR libstdc++/62259
	PR libstdc++/65147
	* include/std/atomic (atomic<T>): Increase alignment for types with
	the same size as one of the integral types.
	* testsuite/29_atomics/atomic/60695.cc: Adjust dg-error line number.
	* testsuite/29_atomics/atomic/62259.cc: New.

From-SVN: r221703
2015-03-26 19:27:02 +00:00
Alan Lawrence 28fda0c459 re PR libstdc++/33394 (Add test case for Thread race segfault in std::string::append with -O and -s)
PR libstdc++/33394
	* testsuite/21_strings/basic_string/pthread33394.cc: Use
	dg-additional-options.

From-SVN: r221666
2015-03-25 15:46:58 +00:00
Paolo Carlini ea348bbe59 re PR libstdc++/65543 (rvalue stream insertion and extraction operators incorrectly implemented)
2015-03-25  Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/65543
	* include/std/istream (operator>>(basic_istream<>&&, _Tp&): Revert
	thinko in r150387.
	* include/std/ostream (operator<<(basic_ostream<>&&, const _Tp&):
	Likewise.
	* testsuite/27_io/rvalue_streams-2.cc: New.

From-SVN: r221655
2015-03-25 09:57:06 +00:00
Jonathan Wakely 9ccd0dba21 re PR libstdc++/33394 (Add test case for Thread race segfault in std::string::append with -O and -s)
PR libstdc++/33394
	* testsuite/21_strings/basic_string/pthread33394.cc: Add test.

# Auto-generated commit message above this line, original below.
	PR libstdc++/33394
	* testsuite/21_strings/basic_string/pthread33394.cc: Add test.

From-SVN: r221635
2015-03-24 14:47:32 +00:00
James Greenhalgh c00acee464 [Patch Testsuite] Make all_attributes.cc in to (almost_)all_attributes.cc for ARM.
* testsuite/17_intro/headers/c++1998/all_attributes.cc: Disable
	test for unused for ARM.
	* testsuite/17_intro/headers/c++200x/all_attributes.cc: Likewise.
	* testsuite/17_intro/headers/c++2014/all_attributes.cc: Likewise.

From-SVN: r221538
2015-03-20 17:20:12 +00:00
Jonathan Wakely df6d9c7f6a c++config (__gnu_cxx::__cxx11): Define new namespace.
* include/bits/c++config (__gnu_cxx::__cxx11): Define new namespace.
	* include/ext/codecvt_specializations.h (encoding_state,
	encoding_char_traits): Remove abi-tag and use inline namespace.
	* testsuite/ext/profile/mutex_extensions_neg.cc: Adjust dg-error line.

From-SVN: r221533
2015-03-20 13:26:55 +00:00
Jonathan Wakely 1c6f4a147d 1.cc: Remove name of unused exception variable.
* testsuite/30_threads/shared_lock/modifiers/1.cc: Remove name of
	unused exception variable.
	* testsuite/30_threads/unique_lock/modifiers/1.cc: Likewise.
	* testsuite/30_threads/shared_lock/modifiers/2.cc: Remove duplicate
	test.
	* testsuite/30_threads/unique_lock/modifiers/2.cc: Likewise.

From-SVN: r221477
2015-03-17 16:36:32 +00:00
Jonathan Wakely 95f2fd9c5d nested_exception.h: Do not try to derive from final classes.
* libsupc++/nested_exception.h: Do not try to derive from final
	classes.
	* testsuite/18_support/nested_exception/throw_with_nested.cc: Test
	final class.

From-SVN: r221476
2015-03-17 14:24:55 +00:00
Renlin Li 04a1709359 [PATCH]Remove xfail for wrapped target
libstdc++-v3/

2015-03-12  Renlin Li  <renlin.li@arm.com>

	* testsuite/27_io/ios_base/sync_with_stdio/1.cc: Remove xfail for
	wrapped target.

From-SVN: r221393
2015-03-12 15:00:28 +00:00
Tim Shen 84839a5140 re PR libstdc++/64441 (A match_results returns an incorrect sub_match if the sub_match::matched is false)
PR libstdc++/64441
	* include/bits/regex.h (match_results<>::size,
	match_results<>::position, match_results<>::str,
	match_results<>::operator[], match_results<>::prefix,
	match_results<>::suffix, match_results<>::end,
	match_results<>::_M_resize, match_results<>::_M_unmatched_sub,
	match_results<>::_M_prefix, match_results<>::_M_suffix): Remove
	global __unmatched_sub. Add unmatched submatch as part of
	match_results.
	* include/bits/regex.tcc (__regex_algo_impl<>, regex_replace<>,
	regex_iterator<>::operator++): Adjust to use match_results::_M_prefix.
	* testsuite/28_regex/match_results/out_of_range_submatches.cc:
	New testcases.

From-SVN: r221330
2015-03-10 18:41:46 +00:00
Jonathan Wakely d2e0c00b8c re PR libstdc++/64467 (28_regex/traits/char/isctype.cc and wchar_t/isctype.cc)
PR libstdc++/64467
	* testsuite/28_regex/traits/char/isctype.cc: Don't test newline
	for newlib targets. Really fix mixed line-endings this time.

From-SVN: r221279
2015-03-09 12:47:51 +00:00
Jonathan Wakely 9933260f2f locale_conv.h (wstring_convert::_M_conv): Handle noconv result.
* include/bits/locale_conv.h (wstring_convert::_M_conv): Handle
	noconv result.
	* testsuite/22_locale/conversions/string/2.cc: Also test UTF-8.
	* testsuite/22_locale/conversions/string/3.cc: Likewise, and UTF-16.

From-SVN: r221212
2015-03-05 13:36:21 +00:00
Jonathan Wakely b6584a72ac re PR libstdc++/64797 (22_locale/conversions/string/2.cc FAILs)
PR libstdc++/64797
	* include/bits/locale_conv.h (wstring_convert::_M_conv): Handle
	incomplete multibyte sequences correctly.
	* include/std/codecvt (codecvt_utf8, codecvt_utf16,
	codecvt_utf8_utf16): Limit _Maxcode to maximum Unicode code point.
	* src/c++11/codecvt.cc (invalid_mb_sequence, incomplete_mb_character):
	Define constants.
	(is_high_surrogate, is_low_surrogate, surrogate_pair_to_code_point):
	Define convenience functions.
	(read_utf8_code_point): Return relevant constant to distinguish
	incomplete characters from invalid sequences.
	(read_utf16_code_point): Likewise. Check for invalid sequences.
	(ucs4_in, utf16_in): Use incomplete_mb_character constant.
	(utf16_out): Check for invalid sequences.
	(utf16_span): Fix condition.
	(ucs2_out): Use is_high_surrogate.
	(ucs2_in): Use incomplete_mb_character constant and fix condition.
	* testsuite/22_locale/codecvt/char16_t.cc: Fix whitespace.
	* testsuite/22_locale/conversions/buffer/1.cc: New.
	* testsuite/22_locale/conversions/string/2.cc: Use char16_t and
	char32_t instead of wchar_t.
	* testsuite/22_locale/conversions/string/3.cc: New.

From-SVN: r221189
2015-03-04 17:19:55 +00:00
Iain Sandoe 71ca36ba7b re PR libstdc++/64883 (FAIL: 17_intro/headers/c++*/all_attributes.cc (test for excess errors) on x86_64-apple-darwin10)
2015-03-03  Iain Sandoe  <iain@codesourcery.com>

	PR libstdc++/64883
	* testsuite/17_intro/headers/c++1998/all_attributes.cc: Don't check
	visibility for Darwin.
	* testsuite/17_intro/headers/c++200x/all_attributes.cc: Likewise, and
	also deprecated.
	* testsuite/17_intro/headers/c++2014/all_attributes.cc: Likewise.

From-SVN: r221160
2015-03-03 18:14:20 +00:00
Jonathan Wakely 9d8dbe732a re PR libstdc++/65279 (std::scoped_allocator_adaptor is not assignable)
PR libstdc++/65279
	* include/std/scoped_allocator (__inner_type_impl,
	scoped_allocator_adaptor): Add defaulted copy assignment and move
	assignment operators.
	* testsuite/20_util/scoped_allocator/65279.cc: New.

From-SVN: r221119
2015-03-02 17:50:55 +00:00
Hans-Peter Nilsson 53b2288f93 re PR testsuite/65093 (26_numerics/random/binomial_distribution/operators/values.cc times out on slow targets)
PR testsuite/65093
	* testsuite/26_numerics/random/binomial_distribution/operators/values.cc
	(test01): Add explanatory comment.  Keep only the bd1 sub-test and
	split out bd2, bd3, bd4, and bd5 sub-tests into...
	* testsuite/26_numerics/random/binomial_distribution/operators/values2.cc,
	testsuite/26_numerics/random/binomial_distribution/operators/values3.cc,
	testsuite/26_numerics/random/binomial_distribution/operators/values4.cc,
	testsuite/26_numerics/random/binomial_distribution/operators/values5.cc:
	New separate files with the old parts.

From-SVN: r220821
2015-02-19 19:30:03 +00:00
Jonathan Wakely 01bf6bdb10 char16_t.cc: Add dg-require-cstdint.
* testsuite/22_locale/codecvt/char16_t.cc: Add dg-require-cstdint.
	* testsuite/22_locale/codecvt/char32_t.cc: Likewise.

From-SVN: r220795
2015-02-18 20:21:04 +00:00
Jonathan Wakely 7f971f18e4 codecvt.cc (write_utf16_code_point): Fix code to output surrogate pairs.
* src/c++11/codecvt.cc (write_utf16_code_point): Fix code to output
	surrogate pairs.
	(utf16_in): Pass mode argument to write_utf16_code_point.
	(codecvt<char16_t, char, mbstate_t>::do_in): Set mode according to
	native byte order.
	* testsuite/22_locale/codecvt/char16_t.cc: New.
	* testsuite/22_locale/codecvt/in/wchar_t/1.cc: Fix typo.

From-SVN: r220793
2015-02-18 19:39:03 +00:00
Rüdiger Sonderfeld fb96818737 char32_t.cc: New.
2015-02-17  Rüdiger Sonderfeld  <ruediger@c-plusplus.de>
	    Jonathan Wakely  <jwakely@redhat.com>

	* testsuite/22_locale/codecvt/char32_t.cc: New.

Co-Authored-By: Jonathan Wakely <jwakely@redhat.com>

From-SVN: r220760
2015-02-17 14:25:48 +00:00
Jonathan Wakely faa7d78e41 re PR libstdc++/65085 (Move-assigned empty string corrupt with -D_GLIBCXX_USE_CXX11_ABI=1)
PR libstdc++/65085
	* include/bits/basic_string.h (basic_string(basic_string&&)): Ensure
	empty string gets null-terminated.
	* testsuite/21_strings/basic_string/cons/char/65085.cc: New.

From-SVN: r220758
2015-02-17 12:44:26 +00:00
Matthew Wahab 1e0c223f94 isctype.cc (test01): Fix mixed line-endings introduced in last change.
* testsuite/28_regex/traits/char/isctype.cc (test01): Fix
	mixed line-endings introduced in last change.

From-SVN: r220682
2015-02-13 13:42:06 +00:00
Jason Merrill 864f0146f0 * testsuite/28_regex/traits/wchar_t/isctype.cc: Fix whitespace.
From-SVN: r220655
2015-02-12 15:20:30 -05:00
Matthew Wahab 72900b8306 isctype.cc (test01): Replace test for __NEWLIB__ macro with a dejagnu set macro.
* testsuite/28_regex/traits/char/isctype.cc (test01): Replace test
	for __NEWLIB__ macro with a dejagnu set macro.
	* testsuite/28_regex/traits/wchar_t/isctype.cc (test01): Likewise.

From-SVN: r220648
2015-02-12 14:55:23 +00:00
Matthew Wahab ff9eac2965 [PATCH][libstdc++][Testsuite] isctype test fails for newlib.
libstdc++-v3/
2015-02-02  Matthew Wahab  <matthew.wahab@arm.com>

	PR libstdc++/64467
	* testsuite/28_regex/testsuiteraits/char/isctype.cc (test01): Add newlib
	special case for '\n'.
	* test01estsuite/28_regex/traits/wchar_t/isctype.cc (test01): Likewise.

From-SVN: r220392
2015-02-04 09:24:56 +00:00
Jonathan Wakely 13fc08e44e re PR libstdc++/64883 (FAIL: 17_intro/headers/c++*/all_attributes.cc (test for excess errors) on x86_64-apple-darwin10)
PR libstdc++/64883
	* include/c_global/cstdio (gets): Use __deprecated__ attribute instead
	of deprecated.
	* include/c_std/cstdio (gets): Likewise.
	* testsuite/17_intro/headers/c++1998/all_attributes.cc: Avoid clashing
	with attributes used in darwin headers.

From-SVN: r220318
2015-02-01 15:11:08 +00:00
Jonathan Wakely 85d44192f6 atomic_base.h: Use __always_inline__ instead of always_inline.
* include/bits/atomic_base.h: Use __always_inline__ instead of
	always_inline.
	* include/bits/atomic_futex.h: Likewise.
	* include/bits/c++config: Use __abi_tag__ instead of abi_tag.
	* include/ext/pb_ds/detail/gp_hash_table_map_/gp_ht_map_.hpp: Use
	__packed__ instead of packed.
	* include/std/shared_mutex: Use __unused__ instead of unused.
	* testsuite/17_intro/headers/c++1998/all_attributes.cc: New.
	* testsuite/17_intro/headers/c++200x/all_attributes.cc: New.
	* testsuite/17_intro/headers/c++2014/all_attributes.cc: New.

From-SVN: r220243
2015-01-29 12:47:20 +00:00
Kyrylo Tkachov f6d04238e0 [libstdc++][testsuite][reverted] Remove check for truncation overflow
* testsuite/lib/libstdc++.exp (v3_target_compile): Remove
    check for unsupported.
    (v3_target_compile_as_c): Likewise.

From-SVN: r220206
2015-01-28 13:53:45 +00:00
Jonathan Wakely c7ac7ddaa9 2.cc: Add test for non-transparent comparison function.
* testsuite/23_containers/set/operations/2.cc: Add test for
	non-transparent comparison function.

From-SVN: r220107
2015-01-26 11:18:14 +00:00
Tim Shen 770acfc9e3 re PR libstdc++/64680 (basic_regex::operator= does not reset flags)
PR libstdc++/64680
	* include/bits/regex.h (basic_regex<>::basic_regex,
	basic_regex<>::operator=, basic_regex<>::imbue): Conform to the
	standard interface.
	* testsuite/28_regex/basic_regex/assign/char/cstring.cc: New testcase.

From-SVN: r219987
2015-01-22 05:07:03 +00:00
Tim Shen 77033d2668 re PR libstdc++/64649 (regex_traits::lookup_classname() only works with random access iterators)
PR libstdc++/64649
	* include/bits/regex.tcc (regex_traits<>::lookup_collatename,
	regex_traits<>::lookup_classname): Correctly narrow input chars.
	* testsuite/28_regex/traits/wchar_t/user_defined.cc: New testcase.

From-SVN: r219986
2015-01-22 05:02:38 +00:00
Jonathan Wakely deff1f4105 * testsuite/29_atomics/atomic/64658.cc: Test stored value.
From-SVN: r219952
2015-01-21 16:17:17 +00:00
Jonathan Wakely 4159cf0d22 re PR libstdc++/64650 (std::experimental::bad_optional_access is not default constructible)
PR libstdc++/64650
	* include/experimental/optional (bad_optional_access): Add default
	constructor.
	* testsuite/experimental/optional/requirements.cc: Test for default
	constructor.

From-SVN: r219889
2015-01-20 11:51:03 +00:00
Jonathan Wakely 91c78ea5b6 Implement N3657: heterogeneous lookup in associative containers.
* include/bits/stl_map.h (map::find<>, map::count<>,
	map::lower_bound<>, map::upper_bound<>, map::equal_range<>): New
	member function templates to perform heterogeneous lookup.
	* include/bits/stl_multimap.h (multimap::find<>, multimap::count<>,
	multimap::lower_bound<>, multimap::upper_bound<>,
	multimap::equal_range<>): Likewise.
	* include/bits/stl_multiset.h (multiset::find<>, multiset::count<>,
	multiset::lower_bound<>, multiset::upper_bound<>,
	multiset::equal_range<>): Likewise.
	* include/bits/stl_set.h (set::find<>, set::count<>,
	set::lower_bound<>, set::upper_bound<>, set::equal_range<>): Likewise.
	* include/bits/stl_tree.h (_Rb_tree::_S_lower_bound_tr,
	_Rb_tree::_S_upper_bound_tr, _Rb_tree::_M_find_tr,
	_Rb_tree::_M_count_tr, _Rb_tree::_M_lower_bound_tr,
	_Rb_tree::_M_upper_bound_tr, _Rb_tree::_M_equal_range_tr): Likewise.
	* testsuite/23_containers/map/operations/2.cc: New.
	* testsuite/23_containers/multimap/operations/2.cc: New.
	* testsuite/23_containers/multiset/operations/2.cc: New.
	* testsuite/23_containers/set/operations/2.cc: New.

From-SVN: r219888
2015-01-20 11:50:58 +00:00
Jonathan Wakely 71a16cd8bc Add C++11 std::string constructors for locales and facets.
* config/abi/pre/gnu.ver: Export new constructors.
	* include/bits/codecvt.h (codecvt_byname): Add string constructor.
	(codecvt_byname<char16_t>, codecvt_byname<char32_t>): Define explicit
	specializations and declare explicit instantiations.
	* include/bits/locale_classes.h (locale, collate_byname): Add string
	constructors.
	* include/bits/locale_facets.h (ctype_byname, numpunct_byname):
	Likewise.
	* include/bits/locale_facets_nonio.h (time_get_byname,
	time_put_byname, moneypunct_byname, messages_byname): Likewise.
	* src/c++11/codecvt.cc (codecvt_byname<char16_t>,
	codecvt_byname<char32_t>): Define explicit instantiations.
	* src/c++11/locale-inst.cc (time_put_byname, codecvt_byname):
	Instantiate string constructors.
	(ctype_byname): Define string constructor.
	* testsuite/22_locale/codecvt_byname/1.cc: New.
	* testsuite/22_locale/collate_byname/1.cc: New.
	* testsuite/22_locale/ctype_byname/2.cc: New.
	* testsuite/22_locale/messages_byname/1.cc: New.
	* testsuite/22_locale/moneypunct_byname/1.cc: New.
	* testsuite/22_locale/numpunct_byname/1.cc: New.

From-SVN: r219887
2015-01-20 11:50:51 +00:00
Jonathan Wakely 0e4974d62e re PR libstdc++/64658 (std::atomic_init() undefined)
PR libstdc++/64658
	* include/std/atomic (atomic_init): Define.
	* testsuite/29_atomics/atomic/64658.cc: New.

From-SVN: r219886
2015-01-20 11:50:43 +00:00
Tim Shen e5f3553320 re PR libstdc++/64649 (regex_traits::lookup_classname() only works with random access iterators)
PR libstdc++/64649
	* include/bits/regex.tcc (regex_traits<>::lookup_collatename,
	regex_traits<>::lookup_classname): Support forward iterators.
	* testsuite/28_regex/traits/char/lookup_classname.cc: New testcases.
	* testsuite/28_regex/traits/char/lookup_collatename.cc: New testcase.

From-SVN: r219866
2015-01-19 23:00:13 +00:00
Tim Shen 60c176fb45 re PR libstdc++/64584 (basic_regex::assign breaks *this if it throws regex_error)
PR libstdc++/64584
	PR libstdc++/64585
	* include/bits/regex.h (basic_regex<>::basic_regex,
	basic_regex<>::assign, basic_regex<>::imbue,
	basic_regex<>::swap, basic_regex<>::mark_count): Drop NFA after
	imbuing basic_regex; Make assign() transactional against exception.
	* include/bits/regex_compiler.h (__compile_nfa<>): Add back
	__compile_nfa SFINAE.
	* include/std/regex: Adjust include order to avoid __compile_nfa
	forward declaration.
	* testsuite/28_regex/basic_regex/assign/char/string.cc: New testcase.
	* testsuite/28_regex/basic_regex/imbue/string.cc: New testcase.

From-SVN: r219865
2015-01-19 22:56:04 +00:00
Ville Voutilainen 8bae22b708 range_access.h (begin, end): Use _GLIBCXX14_CONSTEXPR on overloads for arrays.
2015-01-19  Ville Voutilainen  <ville.voutilainen@gmail.com>
	    Jonathan Wakely  <jwakely@redhat.com>

	* include/bits/range_access.h (begin, end): Use _GLIBCXX14_CONSTEXPR
	on overloads for arrays.
	(cbegin, cend, rbegin, rend, crbegin, crend): New.
	* testsuite/24_iterators/range_access_cpp14.cc: New.

Co-Authored-By: Jonathan Wakely <jwakely@redhat.com>

From-SVN: r219846
2015-01-19 14:37:03 +00:00
Jonathan Wakely 257024e31e re PR libstdc++/64646 (New overloads of std::is_permutation dereference past-the-end iterator)
PR libstdc++/64646
	* include/bits/stl_algo.h (__is_permutation): Also test for reaching
	end of the second range.
	* testsuite/25_algorithms/is_permutation/64646.cc: New.

From-SVN: r219821
2015-01-18 16:31:06 +00:00
Jonathan Wakely 1d0a12dc55 DR 488 PR libstdc++/58357
DR 488
	PR libstdc++/58357
	* include/bits/algorithmfwd.h (rotate): Return an iterator.
	* include/bits/stl_algo.h (rotate, __rotate): Likewise.
	* testsuite/25_algorithms/rotate/dr488.cc: New.
	* testsuite/25_algorithms/rotate/check_type.cc: Adjust function type.
	* testsuite/25_algorithms/rotate/requirements/explicit_instantiation/
	2.cc: Likewise.
	* testsuite/25_algorithms/rotate/requirements/explicit_instantiation/
	pod.cc: Likewise.

From-SVN: r219793
2015-01-17 03:15:52 +00:00
Jonathan Wakely d31b87976f re PR libstdc++/60940 (general operations on atomic types do not work with atomic integral typedefs)
PR libstdc++/60940
	* include/bits/atomic_base.h: Remove atomic integral typedefs as
	synonyms for __atomic_base<int> etc.
	* include/std/atomic: Make atomic_int a synonym for atomic<int> and
	likewise for all atomic integral types.
	* testsuite/29_atomics/atomic_integral/cons/copy_list.cc: New.
	* testsuite/29_atomics/atomic/60695.cc: Adjust dg-error line number.

From-SVN: r219790
2015-01-17 01:23:28 +00:00
Jonathan Wakely 3ecec1eff7 re PR libstdc++/56785 (std::tuple of two elements does not apply empty base class optimization when one of its elements is a std::tuple with two elements)
PR libstdc++/56785
	* include/std/tuple (_Tuple_impl): Remove zero-element specialization
	and define one-element specialization.
	* testsuite/20_util/tuple/56785.cc: New.

From-SVN: r219785
2015-01-17 00:21:41 +00:00
Jonathan Wakely c23ccace5c 1.cc: Remove unused header.
* testsuite/22_locale/codecvt/codecvt_utf8/requirements/1.cc:
	Remove unused header.
	* testsuite/22_locale/codecvt/codecvt_utf16/requirements/1.cc:
	Likewise.
	* testsuite/22_locale/codecvt/codecvt_utf8_utf16/requirements/1.cc:
	Likewise.

From-SVN: r219781
2015-01-17 00:12:50 +00:00
Jonathan Wakely 96d8c147aa locale_conv.h (wstring_convert, [...]): New.
* include/bits/locale_conv.h (wstring_convert, wbuffer_convert): New.
	* include/std/locale: Include new header.
	* include/Makefile.am: Add it.
	* include/Makefile.in: Regenerate.
	* testsuite/22_locale/conversions/buffer/requirements/typedefs.cc: New.
	* testsuite/22_locale/conversions/string/1.cc: New.
	* testsuite/22_locale/conversions/string/2.cc: New.
	* testsuite/22_locale/conversions/string/requirements/typedefs.cc: New.
	* testsuite/22_locale/conversions/string/requirements/typedefs-2.cc:
	New.

From-SVN: r219780
2015-01-16 23:38:48 +00:00
Jonathan Wakely 28af1fb39d Implement C++11 <codecvt> header.
* config/abi/pre/gnu.ver: Export new symbols.
	* include/Makefile.am: Add codecvt.
	* include/Makefile.in: Regenerate.
	* include/std/codecvt: New header.
	* src/c++11/codecvt.cc (__codecvt_utf8_base, __codecvt_utf16_base,
	__codecvt_utf8_utf16_base): Define specializations.
	* testsuite/22_locale/codecvt/codecvt_utf8/requirements/1.cc: New.
	* testsuite/22_locale/codecvt/codecvt_utf16/requirements/1.cc: New.
	* testsuite/22_locale/codecvt/codecvt_utf8_utf16/requirements/1.cc:
	New.

From-SVN: r219779
2015-01-16 23:38:35 +00:00
Jonathan Wakely bb93f35da1 acinclude.m4: Fix typo in comment.
* acinclude.m4: Fix typo in comment.
	* configure: Regenerate.
	* include/bits/codecvt.h (codecvt<char16_t, char, mbstate_t>,
	codecvt<char16_t, char, mbstate_t>): Declare specializations.
	* include/bits/locale_facets.h: Reserve space for new specializations.
	* src/c++11/Makefile.am: Add codecvt.cc.
	* src/c++11/Makefile.in: Regenerate.
	* src/c++11/codecvt.cc: New.
	* src/c++98/Makefile.am: Compile locale_init.cc and localename.cc
	with -std=gnu++11.
	* src/c++98/Makefile.in: Regenerate.
	* src/c++98/locale_init.cc: Initialize new codecvt specializations.
	* src/c++98/localename.cc: Likewise.
	* config/abi/pre/gnu.ver: Exports for new codecvt specializations.
	* testsuite/22_locale/codecvt/utf8.cc: New.
	* testsuite/22_locale/locale/cons/unicode.cc: Check that new
	specializations are installed in locale objects.

From-SVN: r219747
2015-01-16 15:02:35 +00:00