13 lines · plain
1// RUN: not llvm-tblgen -gen-subtarget -I %p/../../include %s 2>&1 | FileCheck %s -DFILE=%s2// Verify that subtarget features with same names result in an error.3 4include "llvm/Target/Target.td"5 6def MyTarget : Target;7 8def FeatureB : SubtargetFeature<"NameA", "", "", "">;9 10// CHECK: [[FILE]]:[[@LINE+2]]:5: error: Feature `NameA` is already defined.11// CHECK: [[FILE]]:[[@LINE-3]]:5: note: Previous definition here.12def FeatureA : SubtargetFeature<"NameA", "", "", "">;13