1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-27 21:01:16 +02:00

Revert "Get rid of unicode quotes (#1140)"

This reverts commit f78126bfd6. There
really is no need for such a massive change...
This commit is contained in:
Eelco Dolstra 2016-11-26 00:37:43 +01:00
parent f78126bfd6
commit 215b70f51e
No known key found for this signature in database
GPG key ID: 8170B4726D7198DE
96 changed files with 670 additions and 670 deletions

View file

@ -45,7 +45,7 @@ template<class N> N getIntArg(const string & opt,
Strings::iterator & i, const Strings::iterator & end, bool allowUnit)
{
++i;
if (i == end) throw UsageError(format("'%1%' requires an argument") % opt);
if (i == end) throw UsageError(format("%1% requires an argument") % opt);
string s = *i;
N multiplier = 1;
if (allowUnit && !s.empty()) {
@ -55,13 +55,13 @@ template<class N> N getIntArg(const string & opt,
else if (u == 'M') multiplier = 1ULL << 20;
else if (u == 'G') multiplier = 1ULL << 30;
else if (u == 'T') multiplier = 1ULL << 40;
else throw UsageError(format("invalid unit specifier '%1%'") % u);
else throw UsageError(format("invalid unit specifier %1%") % u);
s.resize(s.size() - 1);
}
}
N n;
if (!string2Int(s, n))
throw UsageError(format("'%1%' requires an integer argument") % opt);
throw UsageError(format("%1% requires an integer argument") % opt);
return n * multiplier;
}