diff options
author | Alexander Ried <ried@mytum.de> | 2016-10-22 20:24:56 +0200 |
---|---|---|
committer | Vladimír Čunát <vcunat@gmail.com> | 2016-10-22 20:24:56 +0200 |
commit | a0ac2ae35e45b28fe071300de17e51d0ef610507 (patch) | |
tree | 0b1d5e91be46499c8ec014fc52617f23a4bd3d97 /pkgs/stdenv | |
parent | c78ccb92ec0607b9d7b2b3da13643d6cbce71a34 (diff) |
stdenv: throwEvalHelp performance (#19779)
Diffstat (limited to 'pkgs/stdenv')
-rw-r--r-- | pkgs/stdenv/generic/default.nix | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/pkgs/stdenv/generic/default.nix b/pkgs/stdenv/generic/default.nix index 372fd3cfa5268..978da2e190707 100644 --- a/pkgs/stdenv/generic/default.nix +++ b/pkgs/stdenv/generic/default.nix @@ -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"]; |