1 | static S snlApply(S snl, Map<S, Lisp> matches) { |
2 | ret snlFromTree(snlApply(snlToTree(snl), matches)); |
3 | } |
4 | |
5 | static Lisp snlApply(Lisp tree, Map<S, Lisp> matches) { |
6 | if (tree == null) ret null; |
7 | if (tree.isEmpty()) |
8 | ret or(matches.get(tree.head), tree); |
9 | |
10 | Lisp lisp = new Lisp(tree.head); |
11 | for (Lisp child : tree) |
12 | lisp.add(snlApply(child, matches)); |
13 | ret lisp; |
14 | } |
download show line numbers debug dex old transpilations
Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1002722 |
Snippet name: | snlApply |
Eternal ID of this version: | #1002722/1 |
Text MD5: | 1f5c8c19bd7f79032630e34661a5ef33 |
Author: | stefan |
Category: | nl bots |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2016-02-18 00:36:06 |
Source code size: | 386 bytes / 14 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 719 / 774 |
Referenced in: | [show references] |