mirror of
https://github.com/NixOS/nix.git
synced 2024-11-25 16:23:02 +00:00
Merge pull request #11114 from DeterminateSystems/fix-warning
Pos::getSnippetUpTo(): Fix warning
This commit is contained in:
commit
9300f855fc
@ -119,12 +119,12 @@ std::optional<std::string> Pos::getSnippetUpTo(const Pos & end) const {
|
|||||||
if (auto source = getSource()) {
|
if (auto source = getSource()) {
|
||||||
|
|
||||||
auto firstLine = LinesIterator(*source);
|
auto firstLine = LinesIterator(*source);
|
||||||
for (auto i = 1; i < this->line; ++i) {
|
for (uint32_t i = 1; i < this->line; ++i) {
|
||||||
++firstLine;
|
++firstLine;
|
||||||
}
|
}
|
||||||
|
|
||||||
auto lastLine = LinesIterator(*source);
|
auto lastLine = LinesIterator(*source);
|
||||||
for (auto i = 1; i < end.line; ++i) {
|
for (uint32_t i = 1; i < end.line; ++i) {
|
||||||
++lastLine;
|
++lastLine;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user