> On May 10, 2017, at 3:17 PM, Michael Catanzaro <mcatanz...@igalia.com> wrote: > > On Tue, May 9, 2017 at 2:57 PM, Ryosuke Niwa <rn...@webkit.org> wrote: >> One annoying thing is that I've seen clang complaining about that >> return statement being an unreachable statement while gcc doesn't :(. >> So we probably shouldn't have return statement, not to mention that 0 >> may not be a valid enum value. > > In that case, I think I'll go with RELEASE_ASSERT_NOT_REACHED() for now... > since otherwise GCC is going to complain in release builds if there is no > return statement. (Won't clang complain about that too?)
Clang won’t complain if the switch is exhaustive and all cases return. Andy > > _______________________________________________ > webkit-dev mailing list > webkit-dev@lists.webkit.org > https://lists.webkit.org/mailman/listinfo/webkit-dev _______________________________________________ webkit-dev mailing list webkit-dev@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-dev