Skip to content

Bug in option resolution #1053

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
aphillips opened this issue Mar 6, 2025 · 0 comments · Fixed by #1054
Closed

Bug in option resolution #1053

aphillips opened this issue Mar 6, 2025 · 0 comments · Fixed by #1054
Labels
formatting Issue pertains to the formatting section of the spec LDML48 LDML48 Release normative Issue affects normative text in the specification

Comments

@aphillips
Copy link
Member

The TAG review comments, @jyasskin notes:

In option resolution, "If rv is a fallback value: If supported, emit a Bad Option error." doesn't say what to do if the BadOption error isn't supported.

The refers to this algorithm:

1. For each _option_:
   1. Let `id` be the string value of the _identifier_ of the _option_.
   1. Let `rv` be the _resolved value_ of the _option value_.
   1. If `rv` is a _fallback value_:
      1. If supported, emit a _Bad Option_ error.
   1. Else:
      1. If the _option value_ consists of a _literal_:
         1. Mark `rv` as a _literal_ _option value_.
      1. Set `res[id]` to be `rv`.
1. Return `res`.

I think the desired algorithm is:

1. For each _option_:
   1. Let `id` be the string value of the _identifier_ of the _option_.
   1. Let `rv` be the _resolved value_ of the _option value_.
   1. If `rv` is a _fallback value_:
      1. If supported, emit a _Bad Option_ error.
   1. Else:
      1. If the _option value_ consists of a _literal_:
         1. Mark `rv` as a _literal_ _option value_.
   1. Set `res[id]` to be `rv`.
1. Return `res`.
@aphillips aphillips added normative Issue affects normative text in the specification formatting Issue pertains to the formatting section of the spec LDML48 LDML48 Release labels Mar 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
formatting Issue pertains to the formatting section of the spec LDML48 LDML48 Release normative Issue affects normative text in the specification
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant