| commit | 504239f453887b4c1f3035b4e8104eda538868e9 | [log] [tgz] |
|---|---|---|
| author | Chris Lattner <sabre@nondot.org> | Wed Mar 18 04:02:57 2009 +0000 |
| committer | Chris Lattner <sabre@nondot.org> | Wed Mar 18 04:02:57 2009 +0000 |
| tree | 9e2ac5ddcca270b2a3eadc69d7479cfe79cd7d23 | |
| parent | 06c54f04066780ab2e42aa661478752d2b2b90cd [diff] [blame] |
teach codegen to handle noop casts as lvalues. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67164 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/CodeGen/exprs.c b/test/CodeGen/exprs.c index 8174267..db60b5a 100644 --- a/test/CodeGen/exprs.c +++ b/test/CodeGen/exprs.c
@@ -58,4 +58,12 @@ int x = fp - fp2; } +// noop casts as lvalues. +struct X { + int Y; +}; +struct X foo(); +int bar() { + return ((struct X)foo()).Y + 1; +}