Skip to content

Commit

Permalink
[mlir] Update comment about propertiesAttr (NFC) (#89634)
Browse files Browse the repository at this point in the history
The comment is misleading because `propertiesAttr` is not actually
ignored when the operation isn't unregistered.
  • Loading branch information
Mogball authored Apr 23, 2024
1 parent 03760ad commit e0c2848
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions mlir/include/mlir/IR/OperationSupport.h
Original file line number Diff line number Diff line change
Expand Up @@ -960,9 +960,12 @@ struct OperationState {
/// Regions that the op will hold.
SmallVector<std::unique_ptr<Region>, 1> regions;

// If we're creating an unregistered operation, this Attribute is used to
// build the properties. Otherwise it is ignored. For registered operations
// see the `getOrAddProperties` method.
/// This Attribute is used to opaquely construct the properties of the
/// operation. If we're creating an unregistered operation, the Attribute is
/// used as-is as the Properties storage of the operation. Otherwise, the
/// operation properties are constructed opaquely using its
/// `setPropertiesFromAttr` hook. Note that `getOrAddProperties` is the
/// preferred method to construct properties from C++.
Attribute propertiesAttr;

private:
Expand Down

0 comments on commit e0c2848

Please sign in to comment.