Function nix_string_realise

Source
pub unsafe extern "C" fn nix_string_realise(
    context: *mut nix_c_context,
    state: *mut EvalState,
    value: *mut nix_value,
    isIFD: bool,
) -> *mut nix_realised_string
Expand description

Realise a string context. This will

  • realise the store paths referenced by the string’s context, and
  • perform the replacement of placeholders.
  • create temporary garbage collection roots for the store paths, for the lifetime of the current process.
  • log to stderr

§Arguments

  • context [out] - Optional, stores error information
  • value [in] - Nix value, which must be a string
  • state [in] - Nix evaluator state
  • isIFD [in] - If true, disallow derivation outputs if setting allow-import-from-derivation is false. You should set this to true when this call is part of a primop. You should set this to false when building for your application’s purpose.

§Returns

NULL if failed, are a new nix_realised_string, which must be freed with nix_realised_string_free