mondo: support variables
This commit is contained in:
parent
3c3832dbce
commit
2dd445c102
1 changed files with 3 additions and 0 deletions
|
|
@ -6,6 +6,9 @@ let runner = new MondoRunner(strudelScope, { pipepost: true, loc: true });
|
||||||
|
|
||||||
let getLeaf = (value, token) => {
|
let getLeaf = (value, token) => {
|
||||||
const [from, to] = token.loc;
|
const [from, to] = token.loc;
|
||||||
|
if (strudelScope[value]) {
|
||||||
|
return strudelScope[value].withLoc(from, to);
|
||||||
|
}
|
||||||
return reify(value).withLoc(from, to);
|
return reify(value).withLoc(from, to);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue