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

Warning Implicit conversion loses integer precision: #291

Open
dimitre opened this issue Apr 5, 2022 · 0 comments
Open

Warning Implicit conversion loses integer precision: #291

dimitre opened this issue Apr 5, 2022 · 0 comments

Comments

@dimitre
Copy link

dimitre commented Apr 5, 2022

I'm now using macOs / XCode. it is not an issue but a suggestion of supress some c++ warnings.

Implicit conversion loses integer precision: 'ItemCount' (aka 'unsigned long') to 'unsigned int'

rtmidi/RtMidi.cpp

Line 1066 in 454e1ce

unsigned int nSrc = MIDIGetNumberOfSources();

rtmidi/RtMidi.cpp

Line 1177 in 454e1ce

return MIDIGetNumberOfSources();

rtmidi/RtMidi.cpp

Line 1273 in 454e1ce

nConnected = CFDataGetLength( connections ) / sizeof(MIDIUniqueID);

rtmidi/RtMidi.cpp

Line 1397 in 454e1ce

return MIDIGetNumberOfDestinations();

rtmidi/RtMidi.cpp

Line 1433 in 454e1ce

unsigned int nDest = MIDIGetNumberOfDestinations();

I can make a PR if needed but preferred to open an issue to see how it is best.
maybe cast to data types like this?

  unsigned int nDest = (unsigned int)MIDIGetNumberOfDestinations();

cheers

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

1 participant