diff --git a/src/libexpr/primops.cc b/src/libexpr/primops.cc index c90bccc97..eebb63831 100644 --- a/src/libexpr/primops.cc +++ b/src/libexpr/primops.cc @@ -1,20 +1,14 @@ -#include "derivations.hh" -#include "eval.hh" -#include "eval-settings.hh" -#include "gc-small-vector.hh" -#include "json-to-value.hh" -#include "store-api.hh" #include "primops.hh" - -#include -#include - -#include -#include -#include - -#include -#include +#include // for time +#include // for max +#include "canon-path.hh" // for CanonPath +#include "config.hh" // for Setting, ExperimentalFeatureSettings +#include "eval-settings.hh" // for EvalSettings, evalSettings +#include "eval.hh" // for EvalState, PrimOp, Env +#include "nixexpr.hh" // for StaticEnv +#include "ref.hh" // for ref +#include "search-path.hh" // for SearchPath +#include "store-api.hh" // for Store namespace nix { diff --git a/src/libexpr/primops/arithmetic.cc b/src/libexpr/primops/arithmetic.cc index 327fbb81c..254eb08e8 100644 --- a/src/libexpr/primops/arithmetic.cc +++ b/src/libexpr/primops/arithmetic.cc @@ -1,4 +1,10 @@ -#include "primops.hh" +#include // for ceil, floor +#include // for numeric_limits +#include "eval-error.hh" // for EvalError, EvalErrorBuilder +#include "eval.hh" // for EvalState, PrimOp +#include "pos-idx.hh" // for PosIdx, noPos +#include "primops.hh" // for CompareValues, prim_lessThan +#include "value.hh" // for Value, nFloat, NixInt, NixFloat namespace nix { diff --git a/src/libexpr/primops/attrset.cc b/src/libexpr/primops/attrset.cc index 9bd55da9c..577dce18c 100644 --- a/src/libexpr/primops/attrset.cc +++ b/src/libexpr/primops/attrset.cc @@ -1,5 +1,21 @@ -#include "gc-small-vector.hh" -#include "primops.hh" +#include // for size_t, memcpy, strcmp +#include // for sort, min, set_difference +#include // for small_vector +#include // for operator+, operator- +#include // for back_insert_iterator +#include // for map, _Rb_tree_iterator +#include // for set +#include // for string_view, operator<=> +#include // for pair +#include // for vector +#include "attr-set.hh" // for Attr, Bindings, Bindings... +#include "eval-error.hh" // for TypeError, EvalErrorBuilder +#include "eval.hh" // for EvalState, PrimOp, prim_... +#include "gc-small-vector.hh" // for SmallValueVector +#include "pos-idx.hh" // for PosIdx, noPos +#include "primops.hh" // for CompareValues, ValueList +#include "symbol-table.hh" // for Symbol, SymbolTable, Sym... +#include "value.hh" // for Value, ValueVector, Valu... namespace nix { diff --git a/src/libexpr/primops/context.cc b/src/libexpr/primops/context.cc index 93ddd064c..714c1976b 100644 --- a/src/libexpr/primops/context.cc +++ b/src/libexpr/primops/context.cc @@ -1,8 +1,31 @@ -#include "downstream-placeholder.hh" -#include "eval-settings.hh" -#include "primops.hh" -#include "derivations.hh" -#include "store-api.hh" +#include // for map, _Rb_tree_const_iterator +#include // for shared_ptr +#include // for basic_string, operator<=>, char... +#include // for move, pair +#include // for visit, get_if +#include // for vector +#include "attr-set.hh" // for Attr, Bindings, BindingsBuilder +#include "config.hh" // for Setting, ExperimentalFeatureSet... +#include "derivations.hh" // for isDerivation +#include "derived-path.hh" // for DerivedPath, makeConstantStoreP... +#include "downstream-placeholder.hh" // for DownstreamPlaceholder +#include "error.hh" // for Error +#include "eval-error.hh" // for EvalError, EvalErrorBuilder +#include "eval-settings.hh" // for EvalSettings, evalSettings +#include "eval.hh" // for EvalState, PrimOp +#include "experimental-features.hh" // for ExperimentalFeature, Xp +#include "fmt.hh" // for HintFmt +#include "globals.hh" // for Settings, settings +#include "outputs-spec.hh" // for OutputsSpec +#include "path.hh" // for StorePath, StorePathSet +#include "pos-idx.hh" // for PosIdx, noPos +#include "ref.hh" // for ref +#include "store-api.hh" // for Store, resolveDerivedPath, copy... +#include "symbol-table.hh" // for SymbolStr, Symbol, SymbolTable +#include "types.hh" // for StringMap, BackedStringView +#include "util.hh" // for overloaded, enumerate +#include "value.hh" // for Value +#include "value/context.hh" // for NixStringContextElem, NixString... namespace nix { diff --git a/src/libexpr/primops/control.cc b/src/libexpr/primops/control.cc index a1cd299c1..e6db0d9c1 100644 --- a/src/libexpr/primops/control.cc +++ b/src/libexpr/primops/control.cc @@ -1,8 +1,24 @@ +#include // for list +#include // for basic_string +#include "attr-set.hh" // for BindingsBuilder +#include "error.hh" // for Trace, Error, lvlInfo, ErrorInfo +#include "eval-error.hh" // for Abort, ThrownError, EvalErrorBuilder #include "eval-settings.hh" -#include "primops.hh" +#include "eval.hh" // for EvalState, PrimOp, DebugTrace, ValMap +#include "fmt.hh" // for HintFmt +#include "pos-idx.hh" // for PosIdx +#include "pos-table.hh" // for PosTable +#include "ref.hh" // for ref +#include "symbol-table.hh" // for Symbol +#include "types.hh" // for BackedStringView +#include "util.hh" // for MaintainCount +#include "value.hh" // for Value +#include "value/context.hh" // for NixStringContext namespace nix { +enum class ReplExitStatus; + /** * builtins.abort */ diff --git a/src/libexpr/primops/debug.cc b/src/libexpr/primops/debug.cc index aa45998b2..41695cfa1 100644 --- a/src/libexpr/primops/debug.cc +++ b/src/libexpr/primops/debug.cc @@ -1,5 +1,16 @@ -#include "eval-settings.hh" -#include "primops.hh" +#include // for list +#include // for basic_string +#include "attr-set.hh" // for Bindings +#include "eval-settings.hh" // for EvalSettings, evalSettings +#include "eval.hh" // for EvalState, PrimOp, DebugTrace +#include "logging.hh" // for Logger, printError +#include "pos-idx.hh" // for PosIdx +#include "pos-table.hh" // for PosTable +#include "position.hh" // for Pos +#include "primops.hh" // for makePositionThunks, prim_second, prim_trace +#include "print.hh" // for ValuePrinter +#include "symbol-table.hh" // for SymbolTable +#include "value.hh" // for Value, nString namespace nix { diff --git a/src/libexpr/primops/derivation.cc b/src/libexpr/primops/derivation.cc index 201df528b..224bc3b7b 100644 --- a/src/libexpr/primops/derivation.cc +++ b/src/libexpr/primops/derivation.cc @@ -1,8 +1,39 @@ -#include "primops.hh" -#include "store-api.hh" -#include "value-to-json.hh" - -#include +#include // for _Rb_tree_const_ite... +#include // for allocator, shared_ptr +#include // for basic_json +#include // for json +#include // for optional, operator== +#include // for set +#include // for char_traits, basic... +#include // for operator==, basic_... +#include // for move, pair +#include // for visit +#include "attr-set.hh" // for Attr, Bindings +#include "config.hh" // for ExperimentalFeatur... +#include "content-address.hh" // for ContentAddressMethod +#include "derivations.hh" // for Derivation, Deriva... +#include "derived-path-map.hh" // for DerivedPathMap +#include "error.hh" // for Error, lvlChatty +#include "eval-error.hh" // for EvalError, EvalErr... +#include "eval.hh" // for EvalState, PrimOp +#include "experimental-features.hh" // for ExperimentalFeature +#include "fmt.hh" // for HintFmt +#include "hash.hh" // for parseHashTypeOpt +#include "logging.hh" // for Logger, printMsg +#include "path.hh" // for StorePath, StorePa... +#include "pos-idx.hh" // for PosIdx, noPos +#include "pos-table.hh" // for PosTable +#include "position.hh" // for Pos, operator<< +#include "primops.hh" // for getAttr, mkOutputS... +#include "ref.hh" // for ref +#include "store-api.hh" // for Store +#include "symbol-table.hh" // for Symbol, SymbolStr +#include "sync.hh" // for Sync +#include "types.hh" // for Strings, BackedStr... +#include "util.hh" // for get, tokenizeString +#include "value-to-json.hh" // for printValueAsJSON +#include "value.hh" // for Value, nNull +#include "value/context.hh" // for NixStringContextElem namespace nix { diff --git a/src/libexpr/primops/fetchClosure.cc b/src/libexpr/primops/fetchClosure.cc index ee49cda10..36a569f71 100644 --- a/src/libexpr/primops/fetchClosure.cc +++ b/src/libexpr/primops/fetchClosure.cc @@ -1,7 +1,20 @@ -#include "primops.hh" -#include "store-api.hh" -#include "make-content-addressed.hh" -#include "url.hh" +#include // for optional +#include // for allocator, char_tr... +#include "attr-set.hh" // for Attr, Bindings +#include "error.hh" // for Error, Trace +#include "eval.hh" // for EvalState, PrimOp +#include "experimental-features.hh" // for ExperimentalFeature +#include "fmt.hh" // for HintFmt +#include "make-content-addressed.hh" // for makeContentAddressed +#include "path-info.hh" // for ValidPathInfo +#include "path.hh" // for StorePath +#include "pos-idx.hh" // for PosIdx +#include "realisation.hh" // for RealisedPath +#include "store-api.hh" // for Store, copyClosure +#include "url.hh" // for ParsedURL, parseURL +#include "util.hh" // for getEnv, operator+ +#include "value.hh" // for Value, nString +#include "value/context.hh" // for NixStringContext namespace nix { diff --git a/src/libexpr/primops/fetchMercurial.cc b/src/libexpr/primops/fetchMercurial.cc index 1ee81b524..b9cccdbd6 100644 --- a/src/libexpr/primops/fetchMercurial.cc +++ b/src/libexpr/primops/fetchMercurial.cc @@ -1,10 +1,23 @@ -#include "primops.hh" -#include "eval-inline.hh" -#include "eval-settings.hh" -#include "store-api.hh" -#include "fetchers.hh" -#include "url.hh" -#include "url-parts.hh" +#include // for optional +#include // for regex_match +#include // for allocator, char_traits, basic_string +#include // for operator==, basic_string_view, string_view +#include // for move +#include "attr-set.hh" // for Attr, BindingsBuilder, Bindings +#include "attrs.hh" // for Attrs +#include "error.hh" // for Error +#include "eval-error.hh" // for EvalError, EvalErrorBuilder +#include "eval-settings.hh" // for EvalSettings, evalSettings +#include "eval.hh" // for EvalState, PrimOp +#include "fetchers.hh" // for Input, Tree +#include "hash.hh" // for Hash, HashType +#include "pos-idx.hh" // for PosIdx +#include "ref.hh" // for ref +#include "symbol-table.hh" // for Symbol, SymbolStr, SymbolTable +#include "types.hh" // for BackedStringView +#include "url-parts.hh" // for revRegex +#include "value.hh" // for Value, nAttrs +#include "value/context.hh" // for NixStringContext namespace nix { diff --git a/src/libexpr/primops/fetchTree.cc b/src/libexpr/primops/fetchTree.cc index 2392c2ce5..ad403f1ee 100644 --- a/src/libexpr/primops/fetchTree.cc +++ b/src/libexpr/primops/fetchTree.cc @@ -1,15 +1,36 @@ -#include "primops.hh" -#include "eval-inline.hh" -#include "eval-settings.hh" -#include "store-api.hh" -#include "fetchers.hh" -#include "filetransfer.hh" -#include "registry.hh" -#include "url.hh" - -#include -#include -#include +#include // for assert +#include // for uint64_t +#include // for gmtime +#include // for put_time, operator<< +#include // for operator==, map +#include // for optional, operator== +#include // for regex_match, regex... +#include // for char_traits, basic... +#include // for operator==, basic_... +#include // for move, pair +#include "attr-set.hh" // for Attr, BindingsBuilder +#include "attrs.hh" // for maybeGetStrAttr +#include "config.hh" // for Setting, Experimen... +#include "content-address.hh" // for FileIngestionMethod +#include "eval-error.hh" // for EvalError, EvalErr... +#include "eval-settings.hh" // for EvalSettings, eval... +#include "eval.hh" // for EvalState, PrimOp +#include "experimental-features.hh" // for ExperimentalFeature +#include "fetchers.hh" // for Input, Tree, downl... +#include "fmt.hh" // for fmt +#include "hash.hh" // for Hash, HashType, Base +#include "path-info.hh" // for ValidPathInfo +#include "path.hh" // for StorePath +#include "pos-idx.hh" // for PosIdx +#include "ref.hh" // for ref +#include "registry.hh" // for lookupInRegistries +#include "store-api.hh" // for Store +#include "symbol-table.hh" // for Symbol, SymbolTable +#include "types.hh" // for BackedStringView +#include "url.hh" // for ParsedURL +#include "util.hh" // for baseNameOf +#include "value.hh" // for Value, nAttrs, nBool +#include "value/context.hh" // for NixStringContext namespace nix { diff --git a/src/libexpr/primops/fromTOML.cc b/src/libexpr/primops/fromTOML.cc index 1d4fa8dfd..65312d73f 100644 --- a/src/libexpr/primops/fromTOML.cc +++ b/src/libexpr/primops/fromTOML.cc @@ -1,8 +1,27 @@ -#include "primops.hh" -#include "eval-inline.hh" - -#include -#include +#include // for size_t +#include // for int64_t +#include // for exception +#include // for function +#include // for char_traits, basic_ostringstream +#include // for runtime_error +#include // for basic_string, operator<<, operat... +#include // for operator<< +#include // for operator<< +#include // for get +#include // for parse +#include // for operator<< +#include // for value_t +#include // for value, table +#include // for unordered_map, _Node_iterator +#include // for pair +#include // for vector +#include "attr-set.hh" // for BindingsBuilder +#include "config.hh" // for ExperimentalFeatureSettings, exp... +#include "eval-error.hh" // for EvalError, EvalErrorBuilder +#include "eval.hh" // for EvalState, PrimOp +#include "experimental-features.hh" // for ExperimentalFeature, Xp +#include "pos-idx.hh" // for PosIdx +#include "value.hh" // for Value, NixFloat namespace nix { diff --git a/src/libexpr/primops/hash.cc b/src/libexpr/primops/hash.cc index b62e82a5e..e174a89ce 100644 --- a/src/libexpr/primops/hash.cc +++ b/src/libexpr/primops/hash.cc @@ -1,5 +1,11 @@ #include "hash.hh" -#include "primops.hh" +#include "eval-error.hh" // for EvalError, EvalErrorBuilder +#include "eval.hh" // for EvalState, PrimOp +#include "pos-idx.hh" // for PosIdx +#include "primops.hh" // for realisePath +#include "source-path.hh" // for SourcePath +#include "value.hh" // for Value +#include "value/context.hh" // for NixStringContext namespace nix { diff --git a/src/libexpr/primops/import.cc b/src/libexpr/primops/import.cc index f4c95b2ad..f8fff48a3 100644 --- a/src/libexpr/primops/import.cc +++ b/src/libexpr/primops/import.cc @@ -1,6 +1,26 @@ -#include "derivations.hh" -#include "primops.hh" -#include "store-api.hh" +#include // for dlerror, dlopen, dlsym, RTLD_LAZY, RTLD_... +#include // for allocator, __shared_ptr_access, shared_ptr +#include // for optional, nullopt, nullopt_t +#include // for basic_string, char_traits, string, opera... +#include // for pair +#include "attr-set.hh" // for BindingsBuilder, Bindings, Attr +#include "canon-path.hh" // for CanonPath +#include "derivations.hh" // for Derivation, DerivationOutput, isDerivation +#include "derived-path.hh" // for makeConstantStorePathRef, SingleDerivedPath +#include "eval-error.hh" // for EvalError, EvalErrorBuilder +#include "eval.hh" // for EvalState, PrimOp, Env, resolveExprPath +#include "logging.hh" // for Logger, debug +#include "nixexpr.hh" // for StaticEnv, Expr +#include "path.hh" // for StorePath +#include "pos-idx.hh" // for PosIdx +#include "primops.hh" // for realisePath, prim_importNative, mkOutput... +#include "ref.hh" // for ref +#include "source-path.hh" // for SourcePath +#include "store-api.hh" // for Store +#include "symbol-table.hh" // for Symbol +#include "util.hh" // for enumerate +#include "value.hh" // for Value, allocRootValue +#include "value/context.hh" // for NixStringContextElem namespace nix { diff --git a/src/libexpr/primops/json.cc b/src/libexpr/primops/json.cc index 172eb47b4..edb39ad62 100644 --- a/src/libexpr/primops/json.cc +++ b/src/libexpr/primops/json.cc @@ -1,6 +1,11 @@ -#include "json-to-value.hh" -#include "primops.hh" -#include "value-to-json.hh" +#include // for basic_ostringstream, basic_ios, basic_os... +#include "eval.hh" // for PrimOp, EvalState +#include "json-to-value.hh" // for JSONParseError, parseJSON +#include "pos-idx.hh" // for PosIdx +#include "pos-table.hh" // for PosTable +#include "value-to-json.hh" // for printValueAsJSON +#include "value.hh" // for Value +#include "value/context.hh" // for NixStringContext namespace nix { diff --git a/src/libexpr/primops/list.cc b/src/libexpr/primops/list.cc index 792d88e21..0df82c341 100644 --- a/src/libexpr/primops/list.cc +++ b/src/libexpr/primops/list.cc @@ -1,5 +1,19 @@ -#include "gc-small-vector.hh" -#include "primops.hh" +#include // for memcpy, size_t +#include // for stable_sort +#include // for vector +#include // for function +#include // for set +#include // for basic_string, allocator, opera... +#include // for pair +#include "attr-set.hh" // for BindingsBuilder, Bindings +#include "eval-error.hh" // for EvalError, EvalErrorBuilder +#include "eval.hh" // for EvalState, PrimOp +#include "gc-small-vector.hh" // for SmallTemporaryValueVector, Sma... +#include "pos-idx.hh" // for PosIdx, noPos +#include "primops.hh" // for getAttr, CompareValues, prim_l... +#include "symbol-table.hh" // for Symbol, SymbolTable +#include "util.hh" // for enumerate +#include "value.hh" // for Value, ValueVector namespace nix { diff --git a/src/libexpr/primops/path.cc b/src/libexpr/primops/path.cc index a538768e4..dab5b540f 100644 --- a/src/libexpr/primops/path.cc +++ b/src/libexpr/primops/path.cc @@ -1,8 +1,42 @@ -#include "eval-settings.hh" -#include "fetch-to-store.hh" -#include "path-references.hh" -#include "primops.hh" -#include "store-api.hh" +#include // for stat, S_ISDIR, S_I... +#include // for list +#include // for optional, operator!= +#include // for _Rb_tree_const_ite... +#include // for basic_string, char... +#include // for string_view +#include // for move, pair +#include // for get_if +#include "attr-set.hh" // for Attr, Bindings +#include "canon-path.hh" // for CanonPath +#include "content-address.hh" // for FileIngestionMethod +#include "derivations.hh" // for hashPlaceholder +#include "derived-path.hh" // for SingleDerivedPath +#include "error.hh" // for Error, SysError +#include "eval-error.hh" // for EvalError, EvalErr... +#include "eval-settings.hh" // for EvalSettings, eval... +#include "eval.hh" // for EvalState, PrimOp +#include "experimental-features.hh" // for ExperimentalFeature +#include "fetch-to-store.hh" // for fetchToStore +#include "globals.hh" // for Settings, settings +#include "hash.hh" // for Hash, newHashAllow... +#include "input-accessor.hh" // for InputAccessor +#include "outputs-spec.hh" // for OutputNameView +#include "path-info.hh" // for ValidPathInfo +#include "path-references.hh" // for PathRefScanSink +#include "path.hh" // for StorePath, StorePa... +#include "pos-idx.hh" // for PosIdx, noPos +#include "pos-table.hh" // for PosTable +#include "primops.hh" // for RealisePathFlags +#include "ref.hh" // for ref, make_ref +#include "search-path.hh" // for SearchPath +#include "serialise.hh" // for operator<<, Sink +#include "source-path.hh" // for SourcePath, Symlin... +#include "store-api.hh" // for Store +#include "symbol-table.hh" // for Symbol, SymbolStr +#include "types.hh" // for BackedStringView +#include "util.hh" // for rewriteStrings +#include "value.hh" // for Value, nPath, nString +#include "value/context.hh" // for NixStringContext namespace nix { diff --git a/src/libexpr/primops/string.cc b/src/libexpr/primops/string.cc index 2e35b5677..e12a1460a 100644 --- a/src/libexpr/primops/string.cc +++ b/src/libexpr/primops/string.cc @@ -1,5 +1,24 @@ -#include "names.hh" -#include "primops.hh" +#include // for assert +#include // for size_t +#include // for distance +#include // for shared_ptr, __shared_ptr_access, make_sh... +#include // for regex_error, match_results, cregex_iterator +#include // for basic_string, char_traits, string +#include // for basic_string_view +#include // for unordered_map, operator==, _Node_iterator +#include // for move, pair +#include // for vector +#include "attr-set.hh" // for BindingsBuilder +#include "eval-error.hh" // for EvalError, EvalErrorBuilder +#include "eval.hh" // for EvalState, PrimOp, makeRegexCache, prim_... +#include "names.hh" // for DrvName, compareVersions, nextComponent +#include "pos-idx.hh" // for PosIdx +#include "primops.hh" // for RegexCache +#include "symbol-table.hh" // for Symbol +#include "types.hh" // for BackedStringView, Strings +#include "util.hh" // for baseNameOf, enumerate +#include "value.hh" // for Value, nString +#include "value/context.hh" // for NixStringContext namespace nix { diff --git a/src/libexpr/primops/system.cc b/src/libexpr/primops/system.cc index f9490994d..33b35cd38 100644 --- a/src/libexpr/primops/system.cc +++ b/src/libexpr/primops/system.cc @@ -1,8 +1,23 @@ -#include "eval-settings.hh" -#include "primops.hh" +#include // for optional +#include // for basic_string, char... +#include // for move +#include "canon-path.hh" // for CanonPath +#include "error.hh" // for Error +#include "eval-error.hh" // for EvalError, EvalErr... +#include "eval-settings.hh" // for EvalSettings, eval... +#include "eval.hh" // for EvalState, PrimOp +#include "pos-idx.hh" // for PosIdx +#include "pos-table.hh" // for PosTable +#include "primops.hh" // for prim_exec +#include "types.hh" // for BackedStringView +#include "util.hh" // for getEnv, runProgram +#include "value.hh" // for Value +#include "value/context.hh" // for NixStringContext namespace nix { +struct Expr; + /** * builtins.exec */ diff --git a/src/libexpr/primops/toXML.cc b/src/libexpr/primops/toXML.cc index cd044c4c3..214964b5e 100644 --- a/src/libexpr/primops/toXML.cc +++ b/src/libexpr/primops/toXML.cc @@ -1,5 +1,9 @@ -#include "primops.hh" -#include "value-to-xml.hh" +#include // for basic_ostringstream, basic_ios, basic_os... +#include "eval.hh" // for PrimOp, EvalState (ptr only) +#include "pos-idx.hh" // for PosIdx +#include "value.hh" // for Value +#include "value-to-xml.hh" // for printValueAsXML +#include "value/context.hh" // for NixStringContext namespace nix { diff --git a/src/libexpr/primops/types.cc b/src/libexpr/primops/types.cc index a30048b58..3ee06fe66 100644 --- a/src/libexpr/primops/types.cc +++ b/src/libexpr/primops/types.cc @@ -1,4 +1,12 @@ -#include "primops.hh" +#include // for abort +#include // for basic_string, char_traits, string +#include "attr-set.hh" // for BindingsBuilder +#include "eval-error.hh" // for TypeError, EvalErrorBuilder +#include "eval.hh" // for PrimOp, EvalState +#include "nixexpr.hh" // for ExprLambda, Formal, Formals +#include "pos-idx.hh" // for PosIdx +#include "symbol-table.hh" // for Symbol +#include "value.hh" // for Value, nAttrs, nBool, nFloat, nFunction namespace nix {