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

surge-au: Implicit conversion loses integer precision #48

Closed
esaruoho opened this issue Dec 4, 2018 · 5 comments
Closed

surge-au: Implicit conversion loses integer precision #48

esaruoho opened this issue Dec 4, 2018 · 5 comments

Comments

@esaruoho
Copy link
Collaborator

esaruoho commented Dec 4, 2018

Getting this Value Conversion issue on surge-au/libs/xml/tinyxmlparser.cpp line 928, with the bit of code saying

int tagIndex = tag->length();

shooting

Implicit conversion loses integer precision: 'std::__1::basic_string<char, 
std::__1::char_traits<char>, std::__1::allocator<char> >::size_type' (aka
 'unsigned long') to 'int')

tinyxmlparser_cpp

@baconpaul
Copy link
Collaborator

This warning goes away if you use size_t rather than int for tagIndex
Also (and this is on my Au-build branch) I replaced all the this && with a THIS_AND macro which is defaulted to blank since that was cluttering my life with warnings from the xml parser.
Don’t know if that will all make it into a PR but may help. Again you can see that over on the fork I posted on the other thread,.

@esaruoho
Copy link
Collaborator Author

esaruoho commented Dec 8, 2018

cool, sounds like your au-build is going to be a huge improvement on the current state! i've been attempting to apply the various PRs and branches to a private branch in my own fork, but so far haven't made much progress :)

@esaruoho
Copy link
Collaborator Author

@baconpaul should i close this ticket, or does this warning still appear?

@baconpaul
Copy link
Collaborator

Yeah I think I got this one. But there are others just like it in the codebass.

Once my au fix is merged I may open a bigger issue to get Mac au warning free (which will require some -w flags but also some code changes) so perhaps close this now.

Thanks!!

@esaruoho
Copy link
Collaborator Author

closing for now

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

No branches or pull requests

2 participants