mirror of
https://github.com/NixOS/nix
synced 2025-06-28 22:01:15 +02:00
Revert "Shut up a gcc warning"
This reverts commit 37b4a9ec66
. This
doesn't handle the case where there is no slash.
This commit is contained in:
parent
02d5c54555
commit
26ff9c1b37
1 changed files with 0 additions and 1 deletions
|
@ -40,7 +40,6 @@ SourcePath EvalState::decodePath(std::string_view s, PosIdx pos)
|
|||
|
||||
try {
|
||||
auto slash = s.find('/');
|
||||
if (slash > 20) throw std::invalid_argument("");
|
||||
size_t number = std::stoi(std::string(s.substr(0, slash)), nullptr, 16);
|
||||
s = slash == s.npos ? "" : s.substr(slash);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue