W3C home > Mailing lists > Public > www-style@w3.org > December 2013

Re: [css-variables] cycles involving a single variable

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Mon, 16 Dec 2013 09:58:02 -0800
Message-ID: <CAAWBYDBGB7mUELgs8JZVXuXxCfL_FG80JOfU5aAY1A7=Zu3Z3Q@mail.gmail.com>
To: Cameron McCormack <cam@mcc.id.au>
Cc: www-style list <www-style@w3.org>
On Sun, Dec 15, 2013 at 3:34 PM, Cameron McCormack <cam@mcc.id.au> wrote:
> I just noticed that the text in the spec that I quoted in my previous mail:
>   Custom properties may use variables in their own values to build up
>   composite variables. This can create cyclic dependencies where two or
>   more custom properties each attempt to use the variable that the
>   other defines; doing so makes all the custom properties involved in
>   the cycle compute to their initial value (which is a guaranteed-
>   invalid value).
> doesn't account for cycles that involve a single variable, for example:
>   p { var-a: var(a); }
> since it talks about two or more custom properties.  I don't think there is
> anything else in the spec that talks about how to resolve the above
> (although it is obvious that it should be invalid).

Sorry about that, fixed.

> What is less obvious, but more along the lines of my previous mail, is:
>   p { var-a: var(a, 1); }
> I think this should also be invalid.

I'll attend to this in the other thread.

Received on Monday, 16 December 2013 17:58:49 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:08:37 UTC