1 | static S replaceFirstLong(S s, long l) { |
2 | ret replaceFirstLong(s, str(l)); |
3 | } |
4 | |
5 | static S replaceFirstLong(S s, S replacement) { |
6 | L<S> tok = javaTok(s); |
7 | int i = jfind(tok, "<int>"); |
8 | if (i < 0) ret s; |
9 | tok.set(i, replacement); |
10 | ret join(tok); |
11 | } |
Began life as a copy of #1005548
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: | #1011284 |
Snippet name: | replaceFirstLong - replace first long in string |
Eternal ID of this version: | #1011284/5 |
Text MD5: | 95a15e36b72014831c443c3c84c1fae9 |
Author: | stefan |
Category: | javax / parsing |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2018-12-23 19:26:15 |
Source code size: | 258 bytes / 11 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 437 / 448 |
Version history: | 4 change(s) |
Referenced in: | [show references] |