Libraryless. Click here for Pure Java version (3407L/22K).
1 | static ItIt<Matches> flexMatchIC_tok_iterator(Tok pat, Tok input) { |
2 | LS tokPat = pat.tok(), tokInput = input.tok(); |
3 | L<Int> varIndices = flexMatchIC_getVarIndices(tokPat, tokInput); |
4 | ifdef flexMatchIC_tok_iterator_debug |
5 | print(+varIndices); |
6 | endifdef |
7 | if (varIndices == null) ret emptyItIt(); |
8 | |
9 | ItIt<LS> spreadInputs = ai_spreadCertainIndices_2_iterator(pat.tok(), input.tok(), varIndices); |
10 | |
11 | ret mapI_notNulls(tok -> { |
12 | ifdef flexMatchIC_tok_iterator_debug |
13 | print(+tok); |
14 | endifdef |
15 | ret getMatches(tokPat, tok); |
16 | }, spreadInputs); |
17 | } |
Began life as a copy of #1026110
download show line numbers debug dex old transpilations
Travelled to 6 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1026191 |
Snippet name: | flexMatchIC_tok_iterator - takes tokenization/keeps punctuation |
Eternal ID of this version: | #1026191/4 |
Text MD5: | fee7054022f0a8d9318023d3099dd085 |
Transpilation MD5: | e2bc190b527c7e42f0e1046d93b2bd2c |
Author: | stefan |
Category: | javax / a.i. |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2019-11-28 14:05:06 |
Source code size: | 575 bytes / 17 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 229 / 327 |
Version history: | 3 change(s) |
Referenced in: | [show references] |