[lld] r339867 - [LLD][ELF] - Add test case.
George Rimar via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 16 04:48:18 PDT 2018
Author: grimar
Date: Thu Aug 16 04:48:18 2018
New Revision: 339867
URL: http://llvm.org/viewvc/llvm-project?rev=339867&view=rev
Log:
[LLD][ELF] - Add test case.
To cover the following error message:
https://github.com/llvm-mirror/lld/blob/master/ELF/InputFiles.cpp#L463
Added:
lld/trunk/test/ELF/invalid/sht-group-wrong-section.test
Added: lld/trunk/test/ELF/invalid/sht-group-wrong-section.test
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/test/ELF/invalid/sht-group-wrong-section.test?rev=339867&view=auto
==============================================================================
--- lld/trunk/test/ELF/invalid/sht-group-wrong-section.test (added)
+++ lld/trunk/test/ELF/invalid/sht-group-wrong-section.test Thu Aug 16 04:48:18 2018
@@ -0,0 +1,22 @@
+# REQUIRES: x86
+# RUN: yaml2obj %s -o %t.o
+# RUN: not ld.lld %t.o %t.o -o %t.exe 2>&1 | FileCheck %s
+# CHECK: error: {{.*}}.o: invalid section index in group: 12345
+
+--- !ELF
+FileHeader:
+ Class: ELFCLASS64
+ Data: ELFDATA2LSB
+ Type: ET_REL
+ Machine: EM_X86_64
+Sections:
+ - Name: .group
+ Type: SHT_GROUP
+ Link: .symtab
+ Info: foo
+ Members:
+ - SectionOrType: GRP_COMDAT
+ - SectionOrType: 12345
+Symbols:
+ Global:
+ - Name: foo
More information about the llvm-commits
mailing list