This is an archive of the discontinued LLVM Phabricator instance.

[TableGen] Improve error report of unspecified arguments
ClosedPublic

Authored by wangpc on Aug 3 2023, 12:00 AM.

Details

Summary

Wrong error message is fixed and a note of argument is printed.

Tests are added in llvm/test/TableGen/template-args.td.

Diff Detail

Event Timeline

wangpc created this revision.Aug 3 2023, 12:00 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 3 2023, 12:00 AM
Herald added a subscriber: hiraditya. · View Herald Transcript
wangpc requested review of this revision.Aug 3 2023, 12:00 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 3 2023, 12:00 AM
wangpc updated this revision to Diff 546721.Aug 3 2023, 12:09 AM

Fix tests.

DavidSpickett accepted this revision.Aug 3 2023, 12:39 AM

LGTM, thanks for the quick fix!

llvm/test/TableGen/template-args.td
166

Just for my understanding, was it decided that :: would mean things in a multiclass? As opposed to single : in a normal class.

This revision is now accepted and ready to land.Aug 3 2023, 12:39 AM
wangpc marked an inline comment as done.Aug 3 2023, 2:12 AM

Thanks!
This patch needs to backport to LLVM Release 17 since it is a fix of bug introduced by named arguments patch.

llvm/test/TableGen/template-args.td
166

Yes! It is the way how TableGen normalizes argument names currently.
(But I think there is no need to distinguish them, I may post a patch to remove the difference later.)

This revision was automatically updated to reflect the committed changes.
wangpc marked an inline comment as done.