<div style="width: calc(2px - 100%)"></div> <script>alert(document.querySelector('div').style.width)</script> This testcase prints "calc(2px + -100%)" on stylo. Both firefox and chrome prints "calc(2px - 100%)". This is not wrong, it is valid calc value, but definitely weird. We should do the same with other browsers here.
Just for the record, this comes from bug 1390496 comment 6.
With the fix in https://github.com/servo/servo/pull/18131 (which has been merged to m-c https://hg.mozilla.org/mozilla-central/rev/c7832d380dce), now the testcase in comment 0 prints "calc(-100% + 2px)" on stylo. Is this difference between stylo and other browsers is expected? If so, then we can resolve this bug.
Yeah, it's intentional per the issue you linked.
Status: NEW → RESOLVED
Last Resolved: 10 months ago
Resolution: --- → FIXED
Assignee: nobody → emilio+bugs
You need to log in before you can comment on or make changes to this bug.