> > I believe that it is intended that '-' be included in %C, %Y, and %G > > for negative years, even without the '+' flag or a field width, > > although that is perhaps another area that deserves some > > clarification. I believe that the "if and only if" in the description > > of the '+' flag does not match existing practice. > > C99 only specifies %C conversion for the range 00-99, so the results are > unspecified for negative years. (For %G and %Y it doesn't > specify a range.) > > I thought that we were only adding requirements beyond C99 when the field > width and flags are used. > > If we want to require that negative years can be converted with a plain %C > then this would require an explicit statement about how this is > handled, with CX shading, not just a small modification to some unshaded text > about the number of characters placed in the array. > > -- > Geoff Clare <g.cl...@opengroup.org> > The Open Group, Apex Plaza, Forbury Road, Reading, RG1 1AX, England
Note that there is no universal definition of negative years, see https://en.wikipedia.org/wiki/Year_zero -- or does POSIX require astronomical year numbering?