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

Semantic issue cast from pointer to smaller type 'unsigned int' loses information when compile source as Objective-C++ #182

Closed
wood1986 opened this issue Jul 22, 2020 · 0 comments · Fixed by #183

Comments

@wood1986
Copy link

NSStringFromClass([self class]), (unsigned int) self, [self currentReachabilityFlags]];

For some reason, my project will compile the source as Objective-C++. It gives you Semantic issue as an error.

https://stackoverflow.com/questions/22419063/error-cast-from-pointer-to-smaller-type-int-loses-information-in-eaglview-mm

If I change it from (unsigned int) self to (unsigned int)(size_t) self, it works perfectly.

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

Successfully merging a pull request may close this issue.

1 participant