Skip to content

Compiler warnings in Wire.cpp and USBCDC.cpp #155

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

Closed
rmlearney opened this issue Mar 5, 2021 · 1 comment
Closed

Compiler warnings in Wire.cpp and USBCDC.cpp #155

rmlearney opened this issue Mar 5, 2021 · 1 comment

Comments

@rmlearney
Copy link

I'm sure everyone is seeing these and they're trivial, but thought best to get them noted down:

/Users/xxxx/Library/Arduino15/packages/arduino/hardware/mbed/1.3.2/libraries/Wire/Wire.cpp: In member function 'void arduino::MbedI2C::receiveThd()':
/Users/xxxx/Library/Arduino15/packages/arduino/hardware/mbed/1.3.2/libraries/Wire/Wire.cpp:145:12: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
      if (c <= sizeof(buf)) {
          ~~^~~~~~~~~~
/Users/xxxx/Library/Arduino15/packages/arduino/hardware/mbed/1.3.2/cores/arduino/USB/USBCDC.cpp: In member function 'virtual const uint8_t* arduino::USBCDC::configuration_desc(uint8_t)':
/Users/xxxx/Library/Arduino15/packages/arduino/hardware/mbed/1.3.2/cores/arduino/USB/USBCDC.cpp:543:35: warning: narrowing conversion of '((((arduino::USBCDC*)this)->arduino::USBCDC::extraDescriptor != 0) ? 5 : 0)' from 'int' to 'uint8_t {aka unsigned char}' inside { } [-Wnarrowing]
         (extraDescriptor != NULL) ? 0x5 : 0x0, // iInterface
         ~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~
@zfields
Copy link
Contributor

zfields commented Mar 8, 2021

Resolved by #156

@facchinm facchinm closed this as completed Mar 9, 2021
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

3 participants