diff --git a/include/onnxruntime/core/framework/tensor_shape.h b/include/onnxruntime/core/framework/tensor_shape.h index 4db6b58adc..ef0cfcfa01 100644 --- a/include/onnxruntime/core/framework/tensor_shape.h +++ b/include/onnxruntime/core/framework/tensor_shape.h @@ -43,7 +43,7 @@ using InlinedShapeVector = absl::InlinedVector& span) { TensorShapeVector out; out.reserve(span.size()); - out.assign(span.cbegin(), span.cend()); + out.assign(span.begin(), span.end()); return out; } diff --git a/onnxruntime/core/framework/op_node_proto_helper.cc b/onnxruntime/core/framework/op_node_proto_helper.cc index 7268e957b2..960c997124 100644 --- a/onnxruntime/core/framework/op_node_proto_helper.cc +++ b/onnxruntime/core/framework/op_node_proto_helper.cc @@ -186,7 +186,7 @@ MUST_USE_RESULT Status OpNodeProtoHelper::GetAttrs(const std::string& na Status status = this->GetAttrsAsSpan(name, span); if (status.IsOK()) { out.reserve(span.size()); - out.assign(span.cbegin(), span.cend()); + out.assign(span.begin(), span.end()); } return status; }