Added predicate function "UnaryOperator::isIncrementOp()".

llvm-svn: 47181
diff --git a/clang/include/clang/AST/Expr.h b/clang/include/clang/AST/Expr.h
index 47f2269..453f754 100644
--- a/clang/include/clang/AST/Expr.h
+++ b/clang/include/clang/AST/Expr.h
@@ -435,6 +435,7 @@
   static bool isPostfix(Opcode Op);
 
   bool isPostfix() const { return isPostfix(Opc); }
+  bool isIncrementOp() const {return Opc==PreInc || Opc==PostInc; }
   bool isIncrementDecrementOp() const { return Opc>=PostInc && Opc<=PreDec; }
   bool isSizeOfAlignOfOp() const { return Opc == SizeOf || Opc == AlignOf; }
   bool isOffsetOfOp() const { return Opc == OffsetOf; }