[llvm-commits] [llvm] r123297 - /llvm/trunk/lib/Target/ARM/ARMMCCodeEmitter.cpp
Chris Lattner
clattner at apple.com
Thu Jan 13 13:53:01 PST 2011
>>
>> Please move the default case to the first part of the switch statement:
>> switch (whatever) {
>> default: assert(0 && ...
>> case 0:
>> that way, in non-assert builds, the compiler still thinks everything is
>> great.
>
> Got it, done in r123317. Is it worth mentioning this in the coding style docs?
I went to go do this, but I can't think of a single case that llvm_unreachable is the right answer for. I filed PR 8973 to track its removal. Thanks!
-Chris
More information about the llvm-commits
mailing list