2003-10-29 16:05:03 +00:00
|
|
|
#ifndef __PARSER_H
|
|
|
|
#define __PARSER_H
|
|
|
|
|
2004-02-04 16:03:29 +00:00
|
|
|
#include "eval.hh"
|
2003-10-29 16:05:03 +00:00
|
|
|
|
|
|
|
|
2003-11-22 18:45:56 +00:00
|
|
|
/* Parse a Nix expression from the specified file. If `path' refers
|
|
|
|
to a directory, the "/default.nix" is appended. */
|
2004-02-04 16:03:29 +00:00
|
|
|
Expr parseExprFromFile(EvalState & state, Path path);
|
2003-10-29 16:05:03 +00:00
|
|
|
|
2003-11-22 18:45:56 +00:00
|
|
|
/* Parse a Nix expression from the specified string. */
|
2004-02-04 16:03:29 +00:00
|
|
|
Expr parseExprFromString(EvalState & state, const string & s,
|
2003-11-22 18:45:56 +00:00
|
|
|
const Path & basePath);
|
|
|
|
|
2003-10-29 16:05:03 +00:00
|
|
|
|
|
|
|
#endif /* !__PARSER_H */
|