forked from OSchip/llvm-project
[mlir] Take ValueRange instead of ArrayRef<Value> in StructuredIndexed
This was likely overlooked when ValueRange was first introduced. There is no reason why StructuredIndexed needs specifically an ArrayRef so use ValueRange for better type compatibility with the rest of the APIs. Reviewed By: nicolasvasilache, mehdi_amini Differential Revision: https://reviews.llvm.org/D87127
This commit is contained in:
parent
a5046f7ace
commit
1e1a4a4819
|
@ -190,7 +190,7 @@ public:
|
|||
TemplatedIndexedValue operator()(Value index, Args... indices) {
|
||||
return TemplatedIndexedValue(value, index).append(indices...);
|
||||
}
|
||||
TemplatedIndexedValue operator()(ArrayRef<Value> indices) {
|
||||
TemplatedIndexedValue operator()(ValueRange indices) {
|
||||
return TemplatedIndexedValue(value, indices);
|
||||
}
|
||||
|
||||
|
@ -319,7 +319,7 @@ public:
|
|||
}
|
||||
|
||||
private:
|
||||
TemplatedIndexedValue(Value value, ArrayRef<Value> indices)
|
||||
TemplatedIndexedValue(Value value, ValueRange indices)
|
||||
: value(value), indices(indices.begin(), indices.end()) {}
|
||||
|
||||
TemplatedIndexedValue &append() { return *this; }
|
||||
|
|
Loading…
Reference in New Issue