Re: [css-houdini-drafts] [css-typed-om-1] Should "negate" handle a CSSMathSum of CSSMathNegates?

Depends. If we do add a shortcut like this, then yeah, we should be open to more in the future.  My current shortcuts, tho, are limited to three simple principles that won't result in future changes: (1) produce the same result whether you do the op as a single n-ary operation or N binary operations (so `v1.add(v2, v3)` gives the same result as `v1.add(v2).add(v3)`; (2) when an operation self-reverses (negation and inverse), don't double-stack them; and (3) when operating on just unit values of the same unit, produce another unit value, rather than a math function (so `v1.add(v2)` gives the same result as `v1.value += v2.value`)

I would *prefer* to not have the result change over time, so I think I'd prefer to stick with these simple principles for shortcuts and nothing more. But like I said, I'm not wedded to this if people think more shortcuts are indeed worthwhile.

-- 
GitHub Notification of comment by tabatkins
Please view or discuss this issue at https://github.com/w3c/css-houdini-drafts/issues/675#issuecomment-366389409 using your GitHub account

Received on Friday, 16 February 2018 23:36:39 UTC