1 | static S matchBigX(S pat, S s) {
|
2 | L<S> tokPat = javaTokC(pat), tok = javaTokC(s); |
3 | if (l(tokPat) != l(tok)) null; |
4 | new Var<S> x; |
5 | for i over tokPat: {
|
6 | S p = tokPat.get(i), t = tok.get(i); |
7 | if (eq(p, "X")) {
|
8 | if (!strictSetIC(x, t)) null; |
9 | } else if (neqic(p, t)) null; |
10 | } |
11 | ret unnull(x!); |
12 | } |
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: | #1013195 |
| Snippet name: | matchBigX |
| Eternal ID of this version: | #1013195/5 |
| Text MD5: | 6710996b77e82cfa655f58455f8eb7c4 |
| Author: | stefan |
| Category: | javax / a.i. |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2017-12-27 06:59:55 |
| Source code size: | 324 bytes / 12 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 611 / 637 |
| Version history: | 4 change(s) |
| Referenced in: | [show references] |