forked from lix-project/lix
tilde paths: get HOME at parse time
This commit is contained in:
parent
4646e94610
commit
4b7c9f834c
|
@ -379,9 +379,7 @@ expr_simple
|
||||||
| HPATH {
|
| HPATH {
|
||||||
auto path = string{$1 + 1};
|
auto path = string{$1 + 1};
|
||||||
$$ = new ExprConcatStrings(CUR_POS, false, new vector<Expr *>{
|
$$ = new ExprConcatStrings(CUR_POS, false, new vector<Expr *>{
|
||||||
new ExprPath("/"),
|
new ExprPath(getEnv("HOME", "/")),
|
||||||
new ExprApp(new ExprVar(data->symbols.create("__getEnv")),
|
|
||||||
new ExprString(data->symbols.create("HOME"))),
|
|
||||||
new ExprString(data->symbols.create(path))});
|
new ExprString(data->symbols.create(path))});
|
||||||
}
|
}
|
||||||
| SPATH {
|
| SPATH {
|
||||||
|
|
Loading…
Reference in a new issue