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

Regression with custom precision #364

Closed
mgreter opened this issue May 19, 2014 · 19 comments
Closed

Regression with custom precision #364

mgreter opened this issue May 19, 2014 · 19 comments

Comments

@mgreter
Copy link
Contributor

mgreter commented May 19, 2014

Regression introduced in e231c6c
Breaks feature introduced in 07e9ead

Best regards!

@akhleung
Copy link

Interesting ... I suppose I could try storing only the precision in the To_String visitor instead of the entire Context object....

@akhleung akhleung mentioned this issue May 28, 2014
mgreter added a commit to mgreter/perl-libsass that referenced this issue Jul 2, 2014
@HamptonMakes
Copy link
Member

What's the status here...? I'm confused.

@mgreter
Copy link
Contributor Author

mgreter commented Oct 4, 2014

Just tested with perl bindings and it seems that custom precision is stil broken (nsams@e231c6c).

mgreter added a commit to mgreter/libsass that referenced this issue Oct 27, 2014
@mgreter
Copy link
Contributor Author

mgreter commented Oct 27, 2014

Reversed the logic @akhleung proposed and added a status bool to context, to flag this situation. Feels hackish, but IMO still better than breaking custom precision. Hope it works as intended.

@HamptonMakes
Copy link
Member

Remember though, we are targeting 3.4 which I believe doesn't actually allow this. :/

On Mon, Oct 27, 2014 at 5:17 PM, Marcel Greter notifications@github.com
wrote:

Reversed the logic @akhleung proposed and simply added a status bool to context, to flag this situation. Feels hackish, but IMO still better than breaking custom precision. Hope it works as intended.

Reply to this email directly or view it on GitHub:
#364 (comment)

@mgreter
Copy link
Contributor Author

mgreter commented Oct 27, 2014

Sorry, I dont really understand what you mean? Is custom precision not a feature of sass 3.4?

@xzyfer
Copy link
Contributor

xzyfer commented Oct 27, 2014

According to the changelog the --precision flag was introduces in 3.1.8 and defaulted to 3. In 3.2.0 it was defaulted to 5. Custom precisions via the --precision flag is still in a thing in ruby sass master.

@HamptonMakes
Copy link
Member

I swear I was reading a thread on sass that discussed that... let me look around. Ignore me until I find it as, it could have been a threaded fever dream.

On Mon, Oct 27, 2014 at 7:48 PM, Michael Mifsud notifications@github.com
wrote:

According to the changelog the --precision flag was introduces in 3.1.8 and defaulted to 3. In 3.2.0 it was defaulted to 5. Custom precisions via the --precision flag is still in a thing in ruby sass master.

Reply to this email directly or view it on GitHub:
#364 (comment)

HamptonMakes added a commit that referenced this issue Oct 28, 2014
Fixes regression with custom precision (#364)
@mgreter
Copy link
Contributor Author

mgreter commented Oct 29, 2014

Closing this issue as it is fixed in 12dbd03

@mgreter mgreter closed this as completed Oct 29, 2014
@xzyfer
Copy link
Contributor

xzyfer commented Oct 29, 2014

@mgreter there are reports that this change set is affecting compiling on Windows #586, sass/node-sass#487 (comment).

I'm also see compilation warnings on clang

context.cpp:66:5: warning: field 'subset_map' will be initialized after field '_skip_source_map_update' [-Wreorder]
    subset_map              (Subset_Map<string, pair<Complex_Selector*, Compound_Selector*> >()),
    ^
1 warning generated.

Could you please look into this issue?

/cc @am11

@mgreter
Copy link
Contributor Author

mgreter commented Oct 29, 2014

I saw this warning too. I have re-ordered it in my current WIP branch: mgreter@66e1b4b#diff-f2d6a4d46b2aeaccd8ce40e4d3ea753dR68. I fail to see why this should be an issue? Can someone from node-sass team (@am11) test if reversing the order for subset_map and _skip_source_map_update fixes the issue?

@am11
Copy link
Contributor

am11 commented Oct 29, 2014

Yes I will take a look now. :)

Actually that test was removed recently (sass/node-sass#492 (comment)). I will put it back in our repo and get back to you.

@mgreter
Copy link
Contributor Author

mgreter commented Oct 29, 2014

I'm pretty confident that this will solve the issue. I have already commited the change to master as it at least gets rid of the clang warning.

@xzyfer
Copy link
Contributor

xzyfer commented Oct 29, 2014

Thanks for that @mgreter

@am11
Copy link
Contributor

am11 commented Oct 29, 2014

👍

But I couldn't test it with windows due to this: #591 (comment) 😢

@xzyfer
Copy link
Contributor

xzyfer commented Oct 29, 2014

@am11 are you able to compile master on Windows now? @mgreter has pushed the _skip_source_map_update patch directly to master in 2fae47a

@am11
Copy link
Contributor

am11 commented Oct 29, 2014

Let me give it a try. (-8

@am11
Copy link
Contributor

am11 commented Oct 30, 2014

It compiled without any issue! 😄 👍
But that test is still failing. 😞 👎

@xzyfer
Copy link
Contributor

xzyfer commented Oct 30, 2014

Thanks for taking a look. I've reopened #586 to track this issue.

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

5 participants