Skip to content

Commit

Permalink
Refactor: Simplify boolean expressions in libclang
Browse files Browse the repository at this point in the history
Simplify boolean expresions using true and false with clang-tidy.

Patch by Richard.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@232996 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
gribozavr committed Mar 23, 2015
1 parent 759addd commit 39476e8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tools/libclang/CIndex.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1718,7 +1718,7 @@ class DeclVisit : public VisitorJob {
return VJ->getKind() == DeclVisitKind;
}
const Decl *get() const { return static_cast<const Decl *>(data[0]); }
bool isFirst() const { return data[1] ? true : false; }
bool isFirst() const { return data[1] != nullptr; }
};
class TypeLocVisit : public VisitorJob {
public:
Expand Down

0 comments on commit 39476e8

Please sign in to comment.