diff options
Diffstat (limited to 'clang')
| -rw-r--r-- | clang/include/clang/AST/Stmt.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/include/clang/AST/Stmt.h b/clang/include/clang/AST/Stmt.h index 7d4d38ea1be..d321c9715c7 100644 --- a/clang/include/clang/AST/Stmt.h +++ b/clang/include/clang/AST/Stmt.h @@ -287,6 +287,11 @@ public: } const Stmt *getSubStmt() const { return SubExprs[SUBSTMT]; } + void setSubStmt(Stmt *S) { SubExprs[SUBSTMT] = S; } + void setLHS(Expr *Val) { SubExprs[LHS] = reinterpret_cast<Stmt*>(Val); } + void setRHS(Expr *Val) { SubExprs[RHS] = reinterpret_cast<Stmt*>(Val); } + + virtual SourceRange getSourceRange() const { return SourceRange(CaseLoc, SubExprs[SUBSTMT]->getLocEnd()); } |

