aboutsummaryrefslogtreecommitdiff
path: root/lib/AST/ExprCXX.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2008-04-08 04:40:51 +0000
committerChris Lattner <sabre@nondot.org>2008-04-08 04:40:51 +0000
commit04421087832a031c90bd58f128c7c0e741db8dd2 (patch)
treec80c38dcc7ecb4d31cf5c10faa49e00fc373ea81 /lib/AST/ExprCXX.cpp
parent5db17c9b5edb43e12196e565389b73e91a4fcb65 (diff)
Add support for C++ default arguments, and rework Parse-Sema
interaction for function parameters, fixing PR2046. Patch by Doug Gregor! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@49369 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AST/ExprCXX.cpp')
-rw-r--r--lib/AST/ExprCXX.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/AST/ExprCXX.cpp b/lib/AST/ExprCXX.cpp
index 3bc32e75d8..03faf8b8b5 100644
--- a/lib/AST/ExprCXX.cpp
+++ b/lib/AST/ExprCXX.cpp
@@ -45,3 +45,11 @@ Stmt::child_iterator CXXThrowExpr::child_end() {
return reinterpret_cast<Stmt**>(&Op)+0;
return reinterpret_cast<Stmt**>(&Op)+1;
}
+
+// CXXDefaultArgExpr
+Stmt::child_iterator CXXDefaultArgExpr::child_begin() {
+ return reinterpret_cast<Stmt**>(Param->getDefaultArg());
+}
+Stmt::child_iterator CXXDefaultArgExpr::child_end() {
+ return reinterpret_cast<Stmt**>(Param->getDefaultArg())+1;
+}