Chris Lattner | df98617 | 2009-01-02 07:01:27 +0000 | [diff] [blame] | 1 | ; RUN: not llvm-as < %s |& grep {invalid getelementptr indices} |
Tanya Lattner | 2393a24 | 2004-11-06 23:08:26 +0000 | [diff] [blame] | 2 | |
Dan Gohman | eedff31 | 2008-05-16 00:16:32 +0000 | [diff] [blame] | 3 | ; This testcase is invalid because we are indexing into a pointer that is |
| 4 | ; contained WITHIN a structure. |
Chris Lattner | 5051e9c | 2002-11-06 00:52:21 +0000 | [diff] [blame] | 5 | |
Nick Lewycky | 3f63785 | 2008-03-16 07:55:46 +0000 | [diff] [blame] | 6 | define void @test({i32, i32*} * %X) { |
| 7 | getelementptr {i32, i32*} * %X, i32 0, i32 1, i32 0 |
Chris Lattner | 5051e9c | 2002-11-06 00:52:21 +0000 | [diff] [blame] | 8 | ret void |
| 9 | } |