File tree Expand file tree Collapse file tree 2 files changed +4
-14
lines changed
include/mlir/Dialect/Utils Expand file tree Collapse file tree 2 files changed +4
-14
lines changed Original file line number Diff line number Diff line change 24
24
25
25
namespace mlir {
26
26
27
- // / Return true if `v` is an IntegerAttr with value `0` of a ConstantIndexOp
28
- // / with attribute with value `0`.
27
+ // / Return true if `v` is an IntegerAttr with value `0`.
29
28
bool isZeroIndex (OpFoldResult v);
30
29
31
- // / Return true if `v` is an IntegerAttr with value `1` of a ConstantIndexOp
32
- // / with attribute with value `1`.
30
+ // / Return true if `v` is an IntegerAttr with value `1`.
33
31
bool isOneIndex (OpFoldResult v);
34
32
35
33
// / Represents a range (offset, size, and stride) where each element of the
Original file line number Diff line number Diff line change 15
15
16
16
namespace mlir {
17
17
18
- bool isZeroIndex (OpFoldResult v) {
19
- if (!v)
20
- return false ;
21
- return isConstantIntValue (v, 0 );
22
- }
18
+ bool isZeroIndex (OpFoldResult v) { return isConstantIntValue (v, 0 ); }
23
19
24
- bool isOneIndex (OpFoldResult v) {
25
- if (!v)
26
- return false ;
27
- return isConstantIntValue (v, 1 );
28
- }
20
+ bool isOneIndex (OpFoldResult v) { return isConstantIntValue (v, 1 ); }
29
21
30
22
std::tuple<SmallVector<OpFoldResult>, SmallVector<OpFoldResult>,
31
23
SmallVector<OpFoldResult>>
You can’t perform that action at this time.
0 commit comments