blob: 98c43850b12216ab91c04d47be01b2c272f1ab67 [file] [log] [blame]
Chandler Carruth4177e6f2012-07-02 12:47:22 +00001; RUN: not llvm-as < %s |& grep "invalid getelementptr indices"
Tanya Lattner2393a242004-11-06 23:08:26 +00002
Dan Gohmaneedff312008-05-16 00:16:32 +00003; This testcase is invalid because we are indexing into a pointer that is
4; contained WITHIN a structure.
Chris Lattner5051e9c2002-11-06 00:52:21 +00005
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}