Libraryless. Click here for Pure Java version (2844L/17K).
1 | // returns actual CNC |
2 | static LLS tok_findImports_returnTokens(LS tok) { |
3 | new LLS imports; |
4 | int n = l(tok); |
5 | for (int i : indicesOf(tok, "import")) { |
6 | int j = indexOf(tok, ";", i+2); |
7 | if (j < 0) break; |
8 | imports.add(subList(tok, i-1, j+2)); |
9 | i = j; |
10 | } |
11 | ret imports; |
12 | } |
Began life as a copy of #1010092
download show line numbers debug dex old transpilations
Travelled to 4 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt
No comments. add comment
Snippet ID: | #1031305 |
Snippet name: | tok_findImports_returnTokens |
Eternal ID of this version: | #1031305/1 |
Text MD5: | b4d3431a8442316d3dc37b7e490ddfae |
Transpilation MD5: | 91271c6611f57624b03b893db1b5c36a |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2021-06-04 21:10:22 |
Source code size: | 293 bytes / 12 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 130 / 194 |
Referenced in: | [show references] |