diff options
Diffstat (limited to 'src/libexpr/eval.cc')
-rw-r--r-- | src/libexpr/eval.cc | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/libexpr/eval.cc b/src/libexpr/eval.cc index 820e934a635a..bbb1393f8388 100644 --- a/src/libexpr/eval.cc +++ b/src/libexpr/eval.cc @@ -64,30 +64,30 @@ ATerm expandRec(ATerm e, ATermList rbnds, ATermList nrbnds) /* Create the substitution list. */ ATermMap subs; for (ATermIterator i(rbnds); i; ++i) { - string s; + ATerm name; Expr e2; - if (!(atMatch(m, *i) >> "Bind" >> s >> e2)) + if (!(atMatch(m, *i) >> "Bind" >> name >> e2)) abort(); /* can't happen */ - subs.set(s, ATmake("Select(<term>, <str>)", e, s.c_str())); + subs.set(name, ATmake("Select(<term>, <term>)", e, name)); } /* Create the non-recursive set. */ ATermMap as; for (ATermIterator i(rbnds); i; ++i) { - string s; + ATerm name; Expr e2; - if (!(atMatch(m, *i) >> "Bind" >> s >> e2)) + if (!(atMatch(m, *i) >> "Bind" >> name >> e2)) abort(); /* can't happen */ - as.set(s, substitute(subs, e2)); + as.set(name, substitute(subs, e2)); } /* Copy the non-recursive bindings. !!! inefficient */ for (ATermIterator i(nrbnds); i; ++i) { - string s; + ATerm name; Expr e2; - if (!(atMatch(m, *i) >> "Bind" >> s >> e2)) + if (!(atMatch(m, *i) >> "Bind" >> name >> e2)) abort(); /* can't happen */ - as.set(s, e2); + as.set(name, e2); } return makeAttrs(as); |