[
https://issues.apache.org/jira/browse/GEODE-8340?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17168297#comment-17168297
]
ASF GitHub Bot commented on GEODE-8340:
---------------------------------------
moleske commented on a change in pull request #625:
URL: https://github.com/apache/geode-native/pull/625#discussion_r463326531
##########
File path: cppcache/integration-test/testThinClientSecurityAuthorizationMU.cpp
##########
@@ -160,6 +160,7 @@ void initClientAuth(char UserType) {
case 'A':
credentialGeneratorHandler->getAllowedCredentialsForOps(ad, userCreds,
nullptr);
+ break;
default:
Review comment:
`default` is used here because this switch statement is checking string
characters. The others are checking an enum. Since an enum has a well defined
set of values, you do not need a default if you have a case statement for each
value. `no-covered-switch-default` and `no-switch-enum` help enforce that
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
> Enforce Switch compiler warnings as errors
> ------------------------------------------
>
> Key: GEODE-8340
> URL: https://issues.apache.org/jira/browse/GEODE-8340
> Project: Geode
> Issue Type: Improvement
> Components: native client
> Reporter: Michael Oleske
> Priority: Major
> Labels: pull-request-available
>
> Given I compile the code without exempting no-switch-enum and
> no-implicit-fallthrough and no-covered-switch-default
> Then it should compile
> Note - was marked as a todo, seems reasonable to tackle all these at once
--
This message was sent by Atlassian Jira
(v8.3.4#803005)