diff --git a/doc/fmt.css b/doc/fmt.css new file mode 100644 index 00000000..79e35455 --- /dev/null +++ b/doc/fmt.css @@ -0,0 +1,3 @@ +.docblock { + margin-left: 24px; +} diff --git a/doc/syntax.md b/doc/syntax.md index 8138eaaf..e765d2bd 100644 --- a/doc/syntax.md +++ b/doc/syntax.md @@ -12,14 +12,15 @@ The grammar for a replacement field is as follows:
-replacement_field ::= "{" [arg_id] [":" (format_spec | chrono_format_spec)] "}"
+replacement_field ::= "{" [arg_id] [":" (format_spec | chrono_format_spec)] "}"
arg_id ::= integer | identifier
integer ::= digit+
digit ::= "0"..."9"
identifier ::= id_start id_continue*
id_start ::= "a"..."z" | "A"..."Z" | "_"
id_continue ::= id_start | digit
+
In less formal terms, the replacement field can start with an *arg_id* that
@@ -74,7 +75,7 @@ The general form of a *standard format specifier* is:
-format_spec ::= [[fill]align][sign]["#"]["0"][width]["." precision]["L"][type]
+format_spec ::= [[fill]align][sign]["#"]["0"][width]["." precision]["L"][type]
fill ::= <a character other than '{' or '}'>
align ::= "<" | ">" | "^"
sign ::= "+" | "-" | " "
@@ -84,6 +85,7 @@ precision ::= integer | "{" [arg_id] "}"
type ::= "a" | "A" | "b" | "B" | "c" | "d" | "e" | "E" | "f" | "F" |
"g" | "G" | "o" | "p" | "s" | "x" | "X" | "?"
+
The *fill* character can be any Unicode code point other than `'{'` or `'}'`.
@@ -401,7 +403,7 @@ Format specifications for chrono duration and time point types as well as
-chrono_format_spec ::= [[fill]chrono_format_spec ::= [[fill]align][width]["." precision][chrono_specs] chrono_specs ::= conversion_spec |