[mlir][tblgen] Improving error messages
authorwren romano <2998727+wrengr@users.noreply.github.com>
Mon, 27 Jun 2022 23:28:45 +0000 (16:28 -0700)
committerwren romano <2998727+wrengr@users.noreply.github.com>
Fri, 1 Jul 2022 01:25:53 +0000 (18:25 -0700)
commit46394861a3305bd530b1d0cf8ae5b7a36a4a0b4d
tree27687a28788801061a42e3b70dd17a2862eaa008
parent72a23cef7e661997118a1c4876c814cfd05d72e4
[mlir][tblgen] Improving error messages

This differential improves two error conditions, by detecting them earlier and by providing better messages to help users understand what went wrong.

Reviewed By: jpienaar

Differential Revision: https://reviews.llvm.org/D128555
mlir/lib/TableGen/AttrOrTypeDef.cpp
mlir/lib/TableGen/Builder.cpp
mlir/test/mlir-tblgen/attr-or-type-builder-invalid.td [new file with mode: 0644]