diff options
author | Patrick Palka <ppalka@redhat.com> | 2022-10-20 10:30:31 -0400 |
---|---|---|
committer | Patrick Palka <ppalka@redhat.com> | 2022-10-20 10:30:31 -0400 |
commit | 7bf3a4d36a8e59297ea65dd479ffe696f0974303 (patch) | |
tree | a56d379e4b7cd8a4cde3a28807e3ce3e751c18cd /gcc | |
parent | f4fda3eec408e1eb12cc966f55f0de396be71597 (diff) | |
download | gcc-7bf3a4d36a8e59297ea65dd479ffe696f0974303.zip gcc-7bf3a4d36a8e59297ea65dd479ffe696f0974303.tar.gz gcc-7bf3a4d36a8e59297ea65dd479ffe696f0974303.tar.bz2 |
libstdc++: Redefine __from_chars_alnum_to_val's table
After the C++23 constexpr <charconv> patch r13-3313-g378a0f1840e694 we
have some modules testsuite regressions:
FAIL: g++.dg/modules/xtreme-header-4_b.C -std=c++2b (test for excess errors)
FAIL: g++.dg/modules/xtreme-header_b.C -std=c++2b (test for excess errors)
Like with PR105297, the cause seems to be the deduced type of __table
resolving ahead of time to a local class type, which trips up modules.
And unfortunately that PR's minimal workaround of making __tables's
initializer value dependent doesn't help in this case.
So this patch works around this by avoiding using a local class for the
table type. And I suppose we should use a static data member to define
the table once for all dialects (including C++14) instead of having to
define it twice in C++23 mode (once as a static local variable and again
as a variable template for sake of constexpr evaluation).
libstdc++-v3/ChangeLog:
* include/std/charconv (__detail::__from_chars_alnum_to_val_table):
Redefine as a class template containing the members type, value and
_S_make_table. Don't use a local class as the table type.
(__detail::__table): Remove.
(__detail::__from_chars_alnum_to_val): Adjust after the above.
Diffstat (limited to 'gcc')
0 files changed, 0 insertions, 0 deletions