Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unit math breaks down when numbers have multiple units #2549

Closed
nex3 opened this issue Jan 23, 2018 · 0 comments
Closed

Unit math breaks down when numbers have multiple units #2549

nex3 opened this issue Jan 23, 2018 · 0 comments

Comments

@nex3
Copy link
Contributor

nex3 commented Jan 23, 2018

Libsass's unit math fails badly when working with numbers that have multiple numerator and denominator units. As a simple example, (1px * 1rad / 1ms) / 1rad should cancel out the two rad units and produce 1px/ms. However, in Libsass it currently produces 0.02646, without any units.

sass/sass-spec#1205 adds more thorough specs for these cases.

This is pretty high priority: unit arithmetic is already confusing for users, and having Libsass totally bail on moderately complex uses doesn't help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants