blob: e37a0ffd324953fcf409ad7e3093ae242b1cbc38 [file] [log] [blame]
Nick Lewycky3f637852008-03-16 07:55:46 +00001; RUN: not llvm-as < %s |& grep {Invalid getelementptr indices}
Tanya Lattner2393a242004-11-06 23:08:26 +00002
Chris Lattner5051e9c2002-11-06 00:52:21 +00003; This testcase is invalid because we are indexing into a pointer that is
4; contained WITHIN a structure.
5
Nick Lewycky3f637852008-03-16 07:55:46 +00006define void @test({i32, i32*} * %X) {
7 getelementptr {i32, i32*} * %X, i32 0, i32 1, i32 0
Chris Lattner5051e9c2002-11-06 00:52:21 +00008 ret void
9}