diff options
author | Nick Lewycky <nicholas@mxc.ca> | 2012-10-11 00:38:25 +0000 |
---|---|---|
committer | Nick Lewycky <nicholas@mxc.ca> | 2012-10-11 00:38:25 +0000 |
commit | 64ea275fe4e85f112ccfaf9c7b56fe64e11c771f (patch) | |
tree | 3528d07725139915c84087c2453458d8916dac58 /test | |
parent | a395f4df5b6d9c2feb661091ca75be2500d07cb0 (diff) | |
download | external_llvm-64ea275fe4e85f112ccfaf9c7b56fe64e11c771f.zip external_llvm-64ea275fe4e85f112ccfaf9c7b56fe64e11c771f.tar.gz external_llvm-64ea275fe4e85f112ccfaf9c7b56fe64e11c771f.tar.bz2 |
Don't crash if a .ll file contains a forward-reference that looks like a global
value but later turns out to be a function.
Unfortunately, we can't fold tests into a single file because we only get one
error out of llvm-as.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165680 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r-- | test/Assembler/invalid-fwdref1.ll | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/test/Assembler/invalid-fwdref1.ll b/test/Assembler/invalid-fwdref1.ll new file mode 100644 index 0000000..ef8b16c --- /dev/null +++ b/test/Assembler/invalid-fwdref1.ll @@ -0,0 +1,4 @@ +; RUN: not llvm-as %s -disable-output 2>&1 | grep "invalid forward reference to function as global value!" + +define i8* @test1() { ret i8* @test1a } +define void @test1a() { } |