[llvm] r238134 - Simplify boolean conditional return statements.

Rafael Espindola rafael.espindola at gmail.com
Mon May 25 06:50:21 PDT 2015


Author: rafael
Date: Mon May 25 08:50:21 2015
New Revision: 238134

URL: http://llvm.org/viewvc/llvm-project?rev=238134&view=rev
Log:
Simplify boolean conditional return statements.

Patch by Richard <legalize at xmission.com>

Modified:
    llvm/trunk/lib/Bitcode/Reader/BitstreamReader.cpp

Modified: llvm/trunk/lib/Bitcode/Reader/BitstreamReader.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Bitcode/Reader/BitstreamReader.cpp?rev=238134&r1=238133&r2=238134&view=diff
==============================================================================
--- llvm/trunk/lib/Bitcode/Reader/BitstreamReader.cpp (original)
+++ llvm/trunk/lib/Bitcode/Reader/BitstreamReader.cpp Mon May 25 08:50:21 2015
@@ -48,10 +48,7 @@ bool BitstreamCursor::EnterSubBlock(unsi
   if (NumWordsP) *NumWordsP = NumWords;
 
   // Validate that this block is sane.
-  if (CurCodeSize == 0 || AtEndOfStream())
-    return true;
-
-  return false;
+  return CurCodeSize == 0 || AtEndOfStream();
 }
 
 static uint64_t readAbbreviatedField(BitstreamCursor &Cursor,





More information about the llvm-commits mailing list