W3C home > Mailing lists > Public > public-css-archive@w3.org > August 2020

[csswg-drafts] [css-syntax-3] <percentage-token> type flag is never set (#5483)

From: Fayti1703 via GitHub <sysbot+gh@w3.org>
Date: Fri, 28 Aug 2020 15:27:32 +0000
To: public-css-archive@w3.org
Message-ID: <issues.opened-688155415-1598628451-sysbot+gh@w3.org>
Fayti1703 has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-syntax-3] <percentage-token> type flag is never set ==

[Tokenization](https://drafts.csswg.org/css-syntax-3/#tokenization) defines the `type` flag on three tokens -- `<number-token>`, `<percentage-token>` and `<dimension-token>`, and assigns it a default value of "integer".

[Consume a numeric token](https://drafts.csswg.org/css-syntax-3/#consume-numeric-token) specifically sets the `type` flag on `<number-token>`s and `<dimension-token>`s to the one in the `number` returned from [Consume a number](https://drafts.csswg.org/css-syntax-3/#consume-a-number), using the wording
> create a <xxx-token> with the same value and type flag as *number*

However, this `type` flag isn't assigned for `<percentage-token>`s, as that just says
> create a <percentage-token> with the same value as *number*, and return it.

A strict reading of the spec suggests that therefore, a `<percentage-token>` always has a `type` of "integer", even if it's `value` is, for instance, `50.90`, which seems wrong.

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/5483 using your GitHub account

Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Friday, 28 August 2020 15:27:34 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:42:13 UTC