Lines Matching defs:constraints
63 /// prevent using rewrites within a match context, matcher constraints within
76 /// constraints, requires operation expressions to have names, etc.
281 ArrayRef<ast::ConstraintRef> constraints);
284 ArrayRef<ast::ConstraintRef> constraints);
288 SmallVectorImpl<ast::ConstraintRef> &constraints);
296 /// existing constraints that have already been parsed for the same entity
298 /// allows the use of inline Type constraints, e.g. `Value<valueType: Type>`.
305 /// argument or result variable. The constraints for these variables do not
306 /// allow inline type constraints, and only permit a single constraint.
378 ArrayRef<ast::ConstraintRef> constraints);
386 /// Validate the constraints used to constraint a variable decl.
387 /// `inferredType` is the type of the variable inferred by the constraints
389 /// the constraints. Returns success if the constraint list is valid, failure
392 validateVariableConstraints(ArrayRef<ast::ConstraintRef> constraints,
413 ArrayRef<ast::ConstraintRef> constraints);
564 /// A counter used when naming anonymous constraints and rewrites.
927 /// Attr constraints.
937 /// Type constraints.
1612 ArrayRef<ast::ConstraintRef> constraints) {
1620 constraints);
1626 ast::VariableDecl::create(ctx, nameDecl, type, initExpr, constraints);
1633 ArrayRef<ast::ConstraintRef> constraints) {
1635 constraints);
1639 SmallVectorImpl<ast::ConstraintRef> &constraints) {
1643 typeConstraint, constraints, /*allowInlineTypeConstraints=*/true);
1646 constraints.push_back(*constraint);
1669 "inline `Attr`, `Value`, and `ValueRange` type constraints are not "
1911 SmallVector<ast::ConstraintRef> constraints;
1912 if (failed(parseVariableDeclConstraintList(constraints)))
1915 if (failed(validateVariableConstraints(constraints, type)))
1917 return createInlineVariableExpr(type, name, nameLoc, constraints);
1963 // Only native constraints are supported after negation
2239 // Parse the constraints for the expression.
2240 SmallVector<ast::ConstraintRef> constraints;
2241 if (failed(parseVariableDeclConstraintList(constraints)))
2245 if (failed(validateVariableConstraints(constraints, type)))
2247 return createInlineVariableExpr(type, name, nameLoc, constraints);
2336 // Parse the optional set of constraints.
2337 SmallVector<ast::ConstraintRef> constraints;
2339 failed(parseVariableDeclConstraintList(constraints)))
2350 // Check that the constraints are compatible with having an initializer,
2351 // e.g. type constraints cannot be used with initializers.
2352 for (ast::ConstraintRef constraint : constraints) {
2360 "type constraints are not permitted on variables with "
2372 createVariableDecl(varName, varLoc, initializer, constraints);
2542 ArrayRef<ast::ConstraintRef> constraints) {
2546 if (failed(validateVariableConstraints(constraints, type)))
2576 defineVariableDecl(name, loc, type, initializer, constraints);
2593 Parser::validateVariableConstraints(ArrayRef<ast::ConstraintRef> constraints,
2595 for (const ast::ConstraintRef &ref : constraints)
2708 return emitError(loc, "unable to negate non native constraints");
2761 ArrayRef<ast::ConstraintRef> constraints) {
2763 defineVariableDecl(name, loc, type, constraints);