Re: [CSS3 Values] referencing width or height explicitly

On Fri, Aug 19, 2011 at 12:44 PM, Brian Manthos <brianman@microsoft.com> wrote:
> #3.At "/":
> # check: right side is "number"
> # return: the type of the left side
>
> This seems arbitrary to me.
>
> Why should "calc(5px * (8px / 4px))" get rejected at parse time rather than evaluate to 10px?

So we can detect division by zero at parse-time.  Otherwise, something like:

calc( 5px / (10px - 10%) )

...is valid or not based on the element's current width.

~TJ

Received on Friday, 19 August 2011 19:50:34 UTC