2012-07-18 21:59:03 +03:00
|
|
|
#pragma once
|
2006-07-26 18:05:15 +03:00
|
|
|
|
2010-10-04 20:55:38 +03:00
|
|
|
#include "eval.hh"
|
|
|
|
|
2006-07-26 18:05:15 +03:00
|
|
|
#include <string>
|
|
|
|
#include <map>
|
|
|
|
|
2006-09-05 00:06:23 +03:00
|
|
|
namespace nix {
|
|
|
|
|
2019-04-08 15:20:58 +03:00
|
|
|
MakeError(AttrPathNotFound, Error);
|
2020-02-07 15:22:01 +02:00
|
|
|
MakeError(NoPositionInfo, Error);
|
2019-04-08 15:20:58 +03:00
|
|
|
|
2022-03-04 20:31:59 +02:00
|
|
|
std::pair<Value *, PosIdx> findAlongAttrPath(
|
2022-02-25 17:00:00 +02:00
|
|
|
EvalState & state,
|
|
|
|
const std::string & attrPath,
|
|
|
|
Bindings & autoArgs,
|
|
|
|
Value & vIn);
|
2006-07-26 18:05:15 +03:00
|
|
|
|
2019-10-28 22:22:38 +02:00
|
|
|
/* Heuristic to find the filename and lineno or a nix value. */
|
2022-03-04 21:54:50 +02:00
|
|
|
std::pair<std::string, uint32_t> findPackageFilename(EvalState & state, Value & v, std::string what);
|
2019-10-23 18:21:10 +03:00
|
|
|
|
2020-06-18 14:44:40 +03:00
|
|
|
std::vector<Symbol> parseAttrPath(EvalState & state, std::string_view s);
|
|
|
|
|
2006-09-05 00:06:23 +03:00
|
|
|
}
|