Skip to content

Commit

Permalink
Merge pull request #1511 from mmcgr/reachability
Browse files Browse the repository at this point in the history
Use unreachable macro for all compilers
  • Loading branch information
mmcgr authored Jun 29, 2020
2 parents bdd5424 + b6d5121 commit d75c5eb
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions src/utility/MiscUtil.h
Original file line number Diff line number Diff line change
Expand Up @@ -123,12 +123,7 @@ template <typename... Args>
abort();
}

// HACK: Workaround for GCC <= 9.2 which does not perform exhaustive switch analysis.
// This is intended to be used to suppress spurious reachability warnings.
#if defined(__GNUC__) && __GNUC__ < 10
// HACK: Workaround to suppress spurious reachability warnings.
#define UNREACHABLE_BAD_CASE_ANALYSIS fatal("unhandled switch branch");
#else
#define UNREACHABLE_BAD_CASE_ANALYSIS (void);
#endif

} // namespace souffle

0 comments on commit d75c5eb

Please sign in to comment.