-
-
Notifications
You must be signed in to change notification settings - Fork 36
The data model uses "name" for both namespaced and non-namespaced names #575
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
Comments
I think the core question here is: is namespace a separate item in the data model? If it is, it's a separate optional field and If it isn't that implies that |
#543 was roughly the same as this issue. It said: In #524 (review), @stasm asked:
@eemeli replied:
This issue is to discuss whether we should separate namespace in the data model or not. |
Option (2) seems desirable, since an external tool processing a data model should treat function Without adding the namespace as a separate field, such a tool would have to do additional parsing on the |
Where do we say this? |
I guess we don't. I must have been thinking of an old discussion. However, I still have the same preference, but for a different reason.
-- step 2 of "Function Resolution" in the spec If the namespace isn't a separate field in the data model, then the implementation either has to parse the function name every time, or use its own internal data model that does have a separate "namespace" field. In general, a data model is a parsed representation of the syntax. Since the grammar includes:
parsing includes splitting an identifier into a |
In the 2024-02-15 F2F call, we decided to keep the word "name" in data model, but add text that says something like "sometimes, names can be identifiers" |
* Address #575: say that data model uses `name` for `identifier` Per our discussion of #575, we want to say that the field `name` in the data model encompasses the production `identifier` in cases where the name is an identifier. Fixes #575. * Apply suggestions from code review Co-authored-by: Eemeli Aro <eemeli@mozilla.com> * link syntax --------- Co-authored-by: Eemeli Aro <eemeli@mozilla.com>
We currently have
message-format-wg/spec/data-model/README.md
Lines 168 to 171 in 2a69d2a
but also
message-format-wg/spec/data-model/README.md
Lines 183 to 193 in 2a69d2a
In the former, the "name" is a non-namespaced
name
, while in the latter it's anidentifier
, which may also include a namespace.Which of the following should we do?
This issue was originally raised by @aphillips in #574 (comment), as markup will also be affected.
The text was updated successfully, but these errors were encountered: