Skip to content

added default case in switch statements within non void functions#13

Open
paulignari wants to merge 1 commit intoConnorKirkpatrick:masterfrom
paulignari:defaultReturn
Open

added default case in switch statements within non void functions#13
paulignari wants to merge 1 commit intoConnorKirkpatrick:masterfrom
paulignari:defaultReturn

Conversation

@paulignari
Copy link
Copy Markdown

Compiling with latest version of platformio I got this error several times:

error: control reaches end of non-void function

so I added a default case in every switch statement within a non void function to get rid of compiler errors.

Return values are arbitrary ("N/A" for string, -1 for int) but hopefully they should not be used as all cases are already covered by checks.

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 this pull request may close these issues.

1 participant