We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5ba236f commit 82d69f2Copy full SHA for 82d69f2
mlir/tools/mlir-tblgen/AttrOrTypeDefGen.cpp
@@ -1043,6 +1043,10 @@ getAllTypeConstraints(const llvm::RecordKeeper &records) {
1043
std::vector<Constraint> result;
1044
for (llvm::Record *def :
1045
records.getAllDerivedDefinitionsIfDefined("TypeConstraint")) {
1046
+ // Ignore constraints defined outside of the top-level file.
1047
+ if (llvm::SrcMgr.FindBufferContainingLoc(def->getLoc()[0]) !=
1048
+ llvm::SrcMgr.getMainFileID())
1049
+ continue;
1050
Constraint constr(def);
1051
// Generate C++ function only if "cppFunctionName" is set.
1052
if (!constr.getCppFunctionName())
0 commit comments