MLIR  19.0.0git
Public Member Functions | List of all members
mlir::irdl::AnyAttributeConstraint Class Reference

A constraint that is always satisfied. More...

#include "mlir/Dialect/IRDL/IRDLVerifiers.h"

+ Inheritance diagram for mlir::irdl::AnyAttributeConstraint:

Public Member Functions

virtual ~AnyAttributeConstraint ()=default
 
LogicalResult verify (function_ref< InFlightDiagnostic()> emitError, Attribute attr, ConstraintVerifier &context) const override
 Check that an attribute is satisfying the constraint. More...
 
- Public Member Functions inherited from mlir::irdl::Constraint
virtual ~Constraint ()=default
 

Detailed Description

A constraint that is always satisfied.

Definition at line 218 of file IRDLVerifiers.h.

Constructor & Destructor Documentation

◆ ~AnyAttributeConstraint()

virtual mlir::irdl::AnyAttributeConstraint::~AnyAttributeConstraint ( )
virtualdefault

Member Function Documentation

◆ verify()

LogicalResult AnyAttributeConstraint::verify ( function_ref< InFlightDiagnostic()>  emitError,
Attribute  attr,
ConstraintVerifier context 
) const
overridevirtual

Check that an attribute is satisfying the constraint.

Constraints may call other constraint verifiers. If that is the case, the constraint verifier will check if the variable is already assigned, and if so, check that the attribute is the same as the one assigned. If the variable is not assigned, the constraint verifier will assign the attribute to the variable, and check that the constraint is satisfied.

Implements mlir::irdl::Constraint.

Definition at line 211 of file IRDLVerifiers.cpp.


The documentation for this class was generated from the following files: