[TableGen] Emit a warning for unused template args
Add a warning to TableGen for unused template arguments in classes and multiclasses, for example: multiclass Foo<int x> { def bar; } $ llvm-tblgen foo.td foo.td:1:20: warning: unused template argument: Foo::x multiclass Foo<int x> { ^ A flag '--no-warn-on-unused-template-args' is added to disable the warning. The warning is disabled for LLVM and sub-projects if 'LLVM_ENABLE_WARNINGS=OFF'. Reviewed By: RKSimon Differential Revision: https://reviews.llvm.org/D109359
Loading
Please sign in to comment