dawn_native: Use 'auto' to handle change of tint type

tint::Source::FileContent::lines has changed from a vector of std::string to std::string_view.
The dawn usage of the field works with both types without changes, so juse use `auto` to let tint roll.

Change-Id: I0d8309a13e94da7e3558bd32d0d98a4f27a1a4bc
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/77943
Reviewed-by: Brandon Jones <bajones@chromium.org>
Commit-Queue: Ben Clayton <bclayton@google.com>
This commit is contained in:
Ben Clayton 2022-01-25 20:34:10 +00:00 committed by Dawn LUCI CQ
parent 9c5dd769c8
commit 4a3503a610
1 changed files with 1 additions and 1 deletions

View File

@ -68,7 +68,7 @@ namespace dawn::native {
uint64_t length = 0;
if (lineNum && linePos && diagnostic.source.file_content) {
const std::vector<std::string>& lines = diagnostic.source.file_content->lines;
const auto& lines = diagnostic.source.file_content->lines;
size_t i = 0;
// To find the offset of the message position, loop through each of the first lineNum-1
// lines and add it's length (+1 to account for the line break) to the offset.