Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Compiler error no return statement in function returning non-void #244

Closed
Labels
conclusion: resolvedIssue was resolved topic: codeRelated to content of the project itself type: imperfectionPerceived defect in any part of project
@ln-12

Description

I want to use this library in my PlatformIO/Arduino project unsing an Arduino Nano RP2040 Connect. Unfortunately, I get this compiler error because there are no return statements in these four functions:

.pio/libdeps/rp2040dev-unix-release/ArduinoBLE/src/utility/HCI.cpp: In member function 'virtual int HCIClass::saveNewAddress(uint8_t, uint8_t*, uint8_t*, uint8_t*)':
.pio/libdeps/rp2040dev-unix-release/ArduinoBLE/src/utility/HCI.cpp:469:1: error: no return statement in function returning non-void [-Werror=return-type]
 469 | }
 | ^
.pio/libdeps/rp2040dev-unix-release/ArduinoBLE/src/utility/HCI.cpp: In member function 'virtual int HCIClass::leAddResolvingAddress(uint8_t, uint8_t*, uint8_t*, uint8_t*)':
.pio/libdeps/rp2040dev-unix-release/ArduinoBLE/src/utility/HCI.cpp:496:1: error: no return statement in function returning non-void [-Werror=return-type]
 496 | }
 | ^
.pio/libdeps/rp2040dev-unix-release/ArduinoBLE/src/utility/HCI.cpp: In member function 'virtual int HCIClass::writeLK(uint8_t*, uint8_t*)':
.pio/libdeps/rp2040dev-unix-release/ArduinoBLE/src/utility/HCI.cpp:540:1: error: no return statement in function returning non-void [-Werror=return-type]
 540 | }
 | ^
.pio/libdeps/rp2040dev-unix-release/ArduinoBLE/src/utility/HCI.cpp: In member function 'virtual int HCIClass::readStoredLKs()':
.pio/libdeps/rp2040dev-unix-release/ArduinoBLE/src/utility/HCI.cpp:544:1: error: no return statement in function returning non-void [-Werror=return-type]
 544 | }
 | ^

Am I missing something here or how is this supposed to compile?

Metadata

Metadata

Assignees

No one assigned

    Labels

    conclusion: resolvedIssue was resolved topic: codeRelated to content of the project itself type: imperfectionPerceived defect in any part of project

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /