diff options
Diffstat (limited to 'tests/cplusplus.exp')
-rw-r--r-- | tests/cplusplus.exp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/cplusplus.exp b/tests/cplusplus.exp index 148ad96..20c4471 100644 --- a/tests/cplusplus.exp +++ b/tests/cplusplus.exp @@ -86,11 +86,21 @@ hash (str, len) { default: hval += asso_values[(unsigned char)str[6]]; +#if defined __cplusplus && __cplusplus >= 201703L + [[fallthrough]]; +#elif defined __GNUC__ && __GNUC__ >= 7 + __attribute__ ((__fallthrough__)); +#endif /*FALLTHROUGH*/ case 6: case 5: case 4: hval += asso_values[(unsigned char)str[3]]; +#if defined __cplusplus && __cplusplus >= 201703L + [[fallthrough]]; +#elif defined __GNUC__ && __GNUC__ >= 7 + __attribute__ ((__fallthrough__)); +#endif /*FALLTHROUGH*/ case 3: case 2: |