summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/Sema.h
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2009-04-29 22:16:16 +0000
committerDouglas Gregor <dgregor@apple.com>2009-04-29 22:16:16 +0000
commit0cfbdab0cf8adc00d5f0dae665e0f35c510be383 (patch)
treecff0eb4e6e9a516f4ce3c0cc86954cd38307680a /clang/lib/Sema/Sema.h
parenta74841e22c7a2c5073080a541feb75b2a3993604 (diff)
downloadbcm5719-llvm-0cfbdab0cf8adc00d5f0dae665e0f35c510be383.tar.gz
bcm5719-llvm-0cfbdab0cf8adc00d5f0dae665e0f35c510be383.zip
Implement semantic analysis for transparent unions. This is largely
based on a patch from Anders Johnsen. CodeGen support is incomplete, in that we do not properly coerce to the first field's type. llvm-svn: 70419
Diffstat (limited to 'clang/lib/Sema/Sema.h')
-rw-r--r--clang/lib/Sema/Sema.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/clang/lib/Sema/Sema.h b/clang/lib/Sema/Sema.h
index faaeb7989e5..d04394d94fd 100644
--- a/clang/lib/Sema/Sema.h
+++ b/clang/lib/Sema/Sema.h
@@ -2355,11 +2355,17 @@ public:
/// This routine is only used by the following two methods. C99 6.5.16.
AssignConvertType CheckAssignmentConstraints(QualType lhs, QualType rhs);
- // CheckSingleAssignmentConstraints - Currently used by ActOnCallExpr,
+ // CheckSingleAssignmentConstraints - Currently used by
// CheckAssignmentOperands, and ActOnReturnStmt. Prior to type checking,
// this routine performs the default function/array converions.
AssignConvertType CheckSingleAssignmentConstraints(QualType lhs,
Expr *&rExpr);
+
+ // \brief If the lhs type is a transparent union, check whether we
+ // can initialize the transparent union with the given expression.
+ AssignConvertType CheckTransparentUnionArgumentConstraints(QualType lhs,
+ Expr *&rExpr);
+
// CheckCompoundAssignmentConstraints - Type check without performing any
// conversions. For compound assignments, the "Check...Operands" methods
// perform the necessary conversions.
OpenPOWER on IntegriCloud