diff options
author | Joseph Myers <joseph@codesourcery.com> | 2019-10-04 22:56:14 +0100 |
---|---|---|
committer | Joseph Myers <jsm28@gcc.gnu.org> | 2019-10-04 22:56:14 +0100 |
commit | 843f104d5bc6d1f9b4b3f56c3a4e4278e608827f (patch) | |
tree | ea451e764d55e6941bf945e7254076fc1e531b97 /gcc/generic-match-head.c | |
parent | daa94de24b9afdf21c636532e53561aa3713910b (diff) | |
download | gcc-843f104d5bc6d1f9b4b3f56c3a4e4278e608827f.zip gcc-843f104d5bc6d1f9b4b3f56c3a4e4278e608827f.tar.gz gcc-843f104d5bc6d1f9b4b3f56c3a4e4278e608827f.tar.bz2 |
Add strftime format checking support for C2x %OB and %Ob (bug 82752).
C2x adds strftime %OB and %Ob formats, for alternative forms of month
names (for mainly Slavic languages where a month name on its own is
declined differently from a month name together with a date within
that month). This patch adds corresponding format checking support.
(glibc support for these formats was added in glibc 2.27.)
Bootstrapped with no regressions on x86_64-pc-linux-gnu.
PR c/82752
gcc/c-family:
* c-format.c (C_STD_VER): Handle C2x.
(C_STD_NAME): Likewise.
(strftime_flag_specs): Add 'O' modifier with 'p' flag.
(time_char_table): Use separate entry for 'B' and 'b', with 'O'
modifier allowed and 'p' flag.
* c-format.h (enum format_std_version): Add STD_C2X.
(struct format_char_info): Mention 'p' in comment on flags2.
gcc/testsuite:
* gcc.dg/format/c2x-strftime-1.c: New test.
From-SVN: r276605
Diffstat (limited to 'gcc/generic-match-head.c')
0 files changed, 0 insertions, 0 deletions