gcc/libstdc++-v3/testsuite/28_regex
Jonathan Wakely 1b09eea33f libstdc++: Check for overflow in regex back-reference [PR106607]
Currently we fail to notice integer overflow when parsing a
back-reference expression, or when converting the parsed result from
long to int. This changes the result to be int, so no conversion is
needed, and uses the overflow-checking built-ins to detect an
out-of-range back-reference.

libstdc++-v3/ChangeLog:

	PR libstdc++/106607
	* include/bits/regex_compiler.tcc (_Compiler::_M_cur_int_value):
	Use built-ins to check for integer overflow in back-reference
	number.
	* testsuite/28_regex/basic_regex/106607.cc: New test.
2022-08-22 22:52:24 +01:00
..
algorithms libstdc++: Add dg-timeout-factor to some more regex tests 2022-01-10 12:18:14 +00:00
basic_regex libstdc++: Check for overflow in regex back-reference [PR106607] 2022-08-22 22:52:24 +01:00
constants Update copyright years. 2022-01-03 10:42:10 +01:00
headers/regex Update copyright years. 2022-01-03 10:42:10 +01:00
iterators libstdc++: Add comparisons to std::default_sentinel_t (LWG 3719) 2022-08-04 19:37:56 +01:00
match_results libstdc++: Ensure pmr aliases work without <memory_resource> 2022-05-19 23:38:23 +01:00
regex_error Update copyright years. 2022-01-03 10:42:10 +01:00
requirements Update copyright years. 2022-01-03 10:42:10 +01:00
sub_match Update copyright years. 2022-01-03 10:42:10 +01:00
traits Update copyright years. 2022-01-03 10:42:10 +01:00
init-list.cc Update copyright years. 2022-01-03 10:42:10 +01:00
range_access.cc Update copyright years. 2022-01-03 10:42:10 +01:00
regression.cc Update copyright years. 2022-01-03 10:42:10 +01:00
simple_c++11.cc Update copyright years. 2022-01-03 10:42:10 +01:00