Closed zhusjfaker closed 1 year ago
I'm trying to fix this issue, there have been many discussions about math rules in less. This is an issue of historical discussions https://github.com/less/less.js/issues/1880
I found in the documentation the new operation description in less 4
https://github.com/less/less-docs/blob/master/content/usage/less-options.md
Another issue also verified my view
https://github.com/less/less.js/issues/3586
My understanding is that, we should throw error in there 7 situations.
// parse fail
@c:20px + 20px / 2px;
// parse fail
@c:20px - 20px / 2px;
// parse fail
@c:20px / 20px / 2px;
// parse fail
@c:20px * 20px / 2px;
// parse fail
@c:20px / 20px + 2px;
// parse fail
@c:20px /20px - 2px;
// parse fail
@c:20px / 20px * 2px;
I'm not sure my understanding is correct. I need your advice to modify pr. @matthew-dean @iChenLei
Yes, the failures are expected in the current Less math mode. See: https://github.com/less/less-docs/blob/master/content/usage/less-options.md#math
To reproduce:
Current behavior:
less.js the operation of variables is inconsistent in multiplication and division
Expected behavior:
consistent behavior
Environment information:
less
version: 3.13.0nodejs
version: 16.13operating system
: darwinplease do not forcibly close issue