- MEM_ATTRIBUTE int field_width, nr_of_chars;
- MEM_ATTRIBUTE char plus_space_flag, left_adjust, l_L_modifier;
- MEM_ATTRIBUTE char h_modifier, alternate_flag;
- MEM_ATTRIBUTE char nonzero_value;
- MEM_ATTRIBUTE unsigned long ulong, div_factor;
-
-#ifndef CONFIG_PRINTF_NOFLOAT
- MEM_ATTRIBUTE long double fvalue;
+#if CONFIG_PRINTF_COUNT_CHARS
+ MEM_ATTRIBUTE int nr_of_chars;
+#endif
+ MEM_ATTRIBUTE int field_width;
+ MEM_ATTRIBUTE char format_flag;
+ enum PLUS_SPACE_FLAGS {
+ PSF_NONE, PSF_PLUS, PSF_MINUS
+ };
+ enum DIV_FACTOR {
+ DIV_DEC, DIV_HEX,
+#if CONFIG_PRINTF_OCTAL_FORMATTER
+ DIV_OCT,
+#endif
+ };
+ MEM_ATTRIBUTE struct {
+ enum PLUS_SPACE_FLAGS plus_space_flag : 2;
+#if CONFIG_PRINTF_OCTAL_FORMATTER
+ enum DIV_FACTOR div_factor : 2;
+#else
+ enum DIV_FACTOR div_factor : 1;
+#endif
+ bool left_adjust : 1;
+ bool l_L_modifier : 1;
+ bool h_modifier : 1;
+ bool alternate_flag : 1;
+ bool nonzero_value : 1;
+ bool zeropad : 1;
+#if CPU_HARVARD
+ bool progmem : 1;
+#endif
+ } flags;
+ MEM_ATTRIBUTE unsigned long ulong;
+
+#if CONFIG_PRINTF > PRINTF_NOFLOAT
+ MEM_ATTRIBUTE max_float_t fvalue;