72,74c72,75
< if (ptr[1] != '%')
< goto processing;
<
---
> if (ptr[1] != '%') {
> process_flag();
> return;
> }
95a97
> }
97,99c99,101
< return;
<
< processing:
---
> void
> Print::process_flag()
> {
251d252
< }
252a254,267
> if (done) {
> if ((fmt.format == Format::integer) && have_precision) {
> // specified a . but not a float, set width
> fmt.width = fmt.precision;
> // precision requries digits for width, must fill with 0
> fmt.fill_zero = true;
> } else if ((fmt.format == Format::floating) && !have_precision &&
> fmt.fill_zero) {
> // ambiguous case, matching printf
> fmt.precision = fmt.width;
> }
> }
> } // end while
>