Libraryless. Click here for Pure Java version (3732L/23K).
1 | svoid test_DeepWordIndex() { |
2 | new DeepWordIndex<S> index; |
3 | index.add("a", "for (int i = 0; i < 5; i++) {}"); |
4 | index.add("b", "for (S x : y) {}"); |
5 | assertEqualsVerbose(ll(pair("a", ll(0))), asList(index.lookupString_withPositions("for (int i = 0", debug := true))); |
6 | assertEqualsVerbose(ll(pair("a", ll(4))), asList(index.lookupString_withPositions("(int i = 0", debug := true))); |
7 | } |
Began life as a copy of #1029027
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv
No comments. add comment
Snippet ID: | #1029038 |
Snippet name: | test_DeepWordIndex (OK) |
Eternal ID of this version: | #1029038/7 |
Text MD5: | 980886714d75d566fcb43f26b73f883a |
Transpilation MD5: | 80339db95a06617eaa708df917bc2abd |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2020-07-17 14:04:18 |
Source code size: | 392 bytes / 7 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 191 / 293 |
Version history: | 6 change(s) |
Referenced in: | [show references] |