Wandbox
SettingsLog
SettingsLog
Language
GitHubLogin
Ran/Viewed Log

Author

anonymous

about 4 years ago

Language

C++

Compiler

gcc HEAD 12.0.0 20210503 (experimental)

Options
Warnings
Boost 1.73.0
C++17
-pedantic

Author

anonymous

about 4 years ago

$ g++ prog.cc -Wall -Wextra -I/opt/wandbox/boost-1.73.0/gcc-head/include -std=c++17 -pedantic
prog.cc:89:21: error: declaration of 'usb::EndpointID usb::xhci::StopEndpointCommandTRB::EndpointID() const' changes meaning of 'EndpointID' [-fpermissive]
   89 |     usb::EndpointID EndpointID() const {
      |                     ^~~~~~~~~~
prog.cc:15:9: note: 'EndpointID' declared here as 'class usb::EndpointID'
   15 |   class EndpointID {
      |         ^~~~~~~~~~
prog.cc: In member function 'usb::EndpointID usb::xhci::StopEndpointCommandTRB::EndpointID() const':
prog.cc:90:35: warning: narrowing conversion of '(unsigned int)((const usb::xhci::StopEndpointCommandTRB*)this)->usb::xhci::StopEndpointCommandTRB::bits.usb::xhci::StopEndpointCommandTRB::<unnamed struct>::endpoint_id' from 'unsigned int' to 'int' [-Wnarrowing]
   90 |       return usb::EndpointID{bits.endpoint_id};
      |                              ~~~~~^~~~~~~~~~~
Exit Code:
1