diff options
| author | Justin Bogner <mail@justinbogner.com> | 2016-08-17 20:30:52 +0000 |
|---|---|---|
| committer | Justin Bogner <mail@justinbogner.com> | 2016-08-17 20:30:52 +0000 |
| commit | cd1d5aaf2e317122ddb08bf8d026a6cf8b42a9d8 (patch) | |
| tree | a7454511a28342557b6b2722f014529f399ecffe /llvm/lib/Support | |
| parent | de3aea04129bcde27b025e4619519b4ff01be226 (diff) | |
| download | bcm5719-llvm-cd1d5aaf2e317122ddb08bf8d026a6cf8b42a9d8.tar.gz bcm5719-llvm-cd1d5aaf2e317122ddb08bf8d026a6cf8b42a9d8.zip | |
Replace a few more "fall through" comments with LLVM_FALLTHROUGH
Follow up to r278902. I had missed "fall through", with a space.
llvm-svn: 278970
Diffstat (limited to 'llvm/lib/Support')
| -rw-r--r-- | llvm/lib/Support/CommandLine.cpp | 6 | ||||
| -rw-r--r-- | llvm/lib/Support/FoldingSet.cpp | 4 | ||||
| -rw-r--r-- | llvm/lib/Support/raw_ostream.cpp | 8 |
3 files changed, 9 insertions, 9 deletions
diff --git a/llvm/lib/Support/CommandLine.cpp b/llvm/lib/Support/CommandLine.cpp index 102bc909889..551cdefcbe4 100644 --- a/llvm/lib/Support/CommandLine.cpp +++ b/llvm/lib/Support/CommandLine.cpp @@ -1228,7 +1228,7 @@ bool CommandLineParser::ParseCommandLineOptions(int argc, switch (PositionalOpts[i]->getNumOccurrencesFlag()) { case cl::Optional: Done = true; // Optional arguments want _at most_ one value - // FALL THROUGH + LLVM_FALLTHROUGH; case cl::ZeroOrMore: // Zero or more will take all they can get... case cl::OneOrMore: // One or more will take all they can get... ProvidePositionalOption(PositionalOpts[i], @@ -1282,7 +1282,7 @@ bool CommandLineParser::ParseCommandLineOptions(int argc, Opt.second->error("must be specified at least once!"); ErrorParsing = true; } - // Fall through + LLVM_FALLTHROUGH; default: break; } @@ -1337,7 +1337,7 @@ bool Option::addOccurrence(unsigned pos, StringRef ArgName, StringRef Value, case Required: if (NumOccurrences > 1) return error("must occur exactly one time!", ArgName); - // Fall through + LLVM_FALLTHROUGH; case OneOrMore: case ZeroOrMore: case ConsumeAfter: diff --git a/llvm/lib/Support/FoldingSet.cpp b/llvm/lib/Support/FoldingSet.cpp index 52baf865d83..a27d3174a4f 100644 --- a/llvm/lib/Support/FoldingSet.cpp +++ b/llvm/lib/Support/FoldingSet.cpp @@ -127,8 +127,8 @@ void FoldingSetNodeID::AddString(StringRef String) { // Pos will have overshot size by 4 - #bytes left over. // No need to take endianness into account here - this is always executed. switch (Pos - Size) { - case 1: V = (V << 8) | (unsigned char)String[Size - 3]; // Fall thru. - case 2: V = (V << 8) | (unsigned char)String[Size - 2]; // Fall thru. + case 1: V = (V << 8) | (unsigned char)String[Size - 3]; LLVM_FALLTHROUGH; + case 2: V = (V << 8) | (unsigned char)String[Size - 2]; LLVM_FALLTHROUGH; case 3: V = (V << 8) | (unsigned char)String[Size - 1]; break; default: return; // Nothing left. } diff --git a/llvm/lib/Support/raw_ostream.cpp b/llvm/lib/Support/raw_ostream.cpp index 275fe1d4945..c4a7b145588 100644 --- a/llvm/lib/Support/raw_ostream.cpp +++ b/llvm/lib/Support/raw_ostream.cpp @@ -344,10 +344,10 @@ void raw_ostream::copy_to_buffer(const char *Ptr, size_t Size) { // Handle short strings specially, memcpy isn't very good at very short // strings. switch (Size) { - case 4: OutBufCur[3] = Ptr[3]; // FALL THROUGH - case 3: OutBufCur[2] = Ptr[2]; // FALL THROUGH - case 2: OutBufCur[1] = Ptr[1]; // FALL THROUGH - case 1: OutBufCur[0] = Ptr[0]; // FALL THROUGH + case 4: OutBufCur[3] = Ptr[3]; LLVM_FALLTHROUGH; + case 3: OutBufCur[2] = Ptr[2]; LLVM_FALLTHROUGH; + case 2: OutBufCur[1] = Ptr[1]; LLVM_FALLTHROUGH; + case 1: OutBufCur[0] = Ptr[0]; LLVM_FALLTHROUGH; case 0: break; default: memcpy(OutBufCur, Ptr, Size); |

