unsafeDiscardStringContext
lib.strings.unsafeDiscardStringContext
Primop
Docs pulled from | This Revision | 18 days ago
Nix manual
Takes 1 arguments
s
Discard the string context from a value that can be coerced to a string.
Noogle detected
Implementation
This function is implemented in c++ and is part of the native nix runtime.
src/libexpr/primops/context.cc:10
static void prim_unsafeDiscardStringContext(EvalState & state, CallSite callSite, Value * const * args, Value & v)
{
NixStringContext context;
auto s = state.coerceToString(
noPos, *args[0], context, "while evaluating the argument passed to builtins.unsafeDiscardStringContext");
v.mkString(*s, state.mem);
}
Implementation
The following is the current implementation of this function.
unsafeDiscardStringContext