Skip to content

Commit 2b48b88

Browse files
authored
Apply suggestions from code review
1 parent 55caa12 commit 2b48b88

File tree

3 files changed

+9
-8
lines changed

3 files changed

+9
-8
lines changed

spec/formatting.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@ The formatting of a _message_ is defined by the following operations:
1616
For a message with no _selectors_, this is simple as there is only one _pattern_.
1717
With _selectors_, this will depend on their resolution.
1818

19-
- **_<dfn>Formatting</dfn>_** takes the _resolved values_ of the selected _pattern_,
19+
- **_<dfn>Formatting</dfn>_** takes the _resolved values_ of
20+
the _text_ and _placeholder_ parts of the selected _pattern_,
2021
and produces the formatted result for the _message_.
2122
Depending on the implementation, this result could be a single concatenated string,
2223
an array of objects, an attributed string, or some other locally appropriate data type.
@@ -272,7 +273,7 @@ the following steps are taken:
272273
273274
The form that resolved _operand_ and _option_ values take is implementation-defined.
274275
275-
An implementation MAY pass additional arguments to the function,
276+
An implementation MAY pass additional arguments to the _function handler_,
276277
as long as reasonable precautions are taken to keep the function interface
277278
simple and minimal, and avoid introducing potential security vulnerabilities.
278279
@@ -286,16 +287,16 @@ the following steps are taken:
286287
additional detail about internal failures.
287288
Specifically, if the cause of the failure was that the datatype, value, or format of the
288289
_operand_ did not match that expected by the _function_,
289-
the _function_ might cause a _Bad Operand_ error to be emitted.
290+
the _function_ SHOULD cause a _Bad Operand_ error to be emitted.
290291
291292
In all failure cases, use the _fallback value_ for the _expression_ as its _resolved value_.
292293
293294
#### Function Handler
294295
295-
To resolve a _function_,
296-
a **_<dfn>function handler</dfn>_** is required.
297-
This is an implementation-defined process such as a function or method
296+
A **_<dfn>function handler</dfn>_** is an implementation-defined process
297+
such as a function or method
298298
which accepts a set of arguments and returns a _resolved value_.
299+
A _function handler_ is required to resolve a _function_.
299300
300301
An implementation MAY define its own functions and their handlers.
301302
An implementation MAY allow custom functions to be defined by users.

spec/registry.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -374,7 +374,7 @@ All other values produce a _Bad Operand_ error.
374374
### Digit Size Options
375375
376376
Some _options_ of number _functions_ are defined to take a "digit size option".
377-
_Function handlers_ of number _functions_ use these _options_ to control aspects of numeric display
377+
The _function handlers_ for number _functions_ use these _options_ to control aspects of numeric display
378378
such as the number of fraction, integer, or significant digits.
379379
380380
A "digit size option" is an _option_ value that the _function_ interprets

spec/syntax.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ Attempting to parse a _message_ that is not _valid_ will result in a _Data Model
9797

9898
A **_<dfn>message</dfn>_** is the complete template for a specific message formatting request.
9999

100-
A **_<dfn>variable</dfn>_** is a _name_ associated with a _resolved value_.
100+
A **_<dfn>variable</dfn>_** is a _name_ associated to a _resolved value_.
101101

102102
An **_<dfn>external variable</dfn>_** is a _variable_
103103
whose _name_ and initial value are supplied by the caller

0 commit comments

Comments
 (0)