manpagez: man pages & more
info gettext
Home | html | info | man

File: gettext.info,  Node: rust-format,  Next: go-format,  Prev: librep-format,  Up: Translators for other Languages

16.3.12 Rust Format Strings
---------------------------

   Rust format strings are those supported by the ‘formatx’ library
.  These are those supported by the
‘format!’ built-in  with the
restrictions listed in , section
"Limitations".

   A Rust format string consists of
   • an opening brace ‘{’,
   • an optional non-empty sequence of digits or an optional identifier,
   • optionally, a ‘:’ and a format specifier, where a format specifier
     is of the form
     ‘[[FILL]ALIGN][SIGN][#][0][MINIMUMWIDTH][.PRECISION][TYPE]’ where
        - the FILL character is any character,
        - the ALIGN flag is one of ‘<’, ‘>’, ‘^’,
        - the SIGN is one of ‘+’, ‘-’,
        - the # flag is ‘#’,
        - the 0 flag is ‘0’,
        - MINIMUMWIDTH is a non-empty sequence of digits,
        - PRECISION is a non-empty sequence of digits,
        - TYPE is ‘?’,
   • optional white-space,
   • a closing brace ‘}’.
Brace characters ‘{’ and ‘}’ can be escaped by doubling them: ‘{{’ and
‘}}’.

© manpagez.com 2000-2026
Individual documents may contain additional copyright information.