svoid tok_expandPairL(L<S> tok) { if (!tok.contains("PairL")) ret; int n = l(tok)-6; for (int i = 1; i < n; i += 2) { continue unless eq(tok.get(i), "PairL") && eq(tok.get(i+2), "<"); int j = findEndOfTypeArgs(tok, i+2)-1; // j = index of > tok.set(i, "Pair<L"); tok.set(j, ">>"); reTok(tok, i, j+1); n = l(tok)-6; } }
Began life as a copy of #1017528
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, cfunsshuasjs, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1023486 |
Snippet name: | tok_expandPairL - PairL<...> to Pair<L<...>> |
Eternal ID of this version: | #1023486/1 |
Text MD5: | 40fd7624cb1cf209b1904cf0e1cb63f1 |
Author: | stefan |
Category: | javax / transpilation |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2019-06-25 01:06:57 |
Source code size: | 363 bytes / 12 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 287 / 326 |
Referenced in: | #1006654 - Standard functions list 2 (LIVE, continuation of #761) |