stdenv: throwEvalHelp performance (#19779)

This commit is contained in:
Alexander Ried 2016-10-22 20:24:56 +02:00 committed by Vladimír Čunát
parent c78ccb92ec
commit a0ac2ae35e

View file

@ -128,8 +128,7 @@ let
throwEvalHelp = { reason, errormsg }:
# uppercase the first character of string s
let up = s: with lib;
let cs = lib.stringToCharacters s;
in concatStrings (singleton (toUpper (head cs)) ++ tail cs);
(toUpper (substring 0 1 s)) + (substring 1 (stringLength s) s);
in
assert builtins.elem reason ["unfree" "broken" "blacklisted"];