Libraryless. Click here for Pure Java version (2872L/17K).
1 | // A = type of literals (e.g. String) |
2 | static noeq record LineCompedSingle<A>(L<A> literals, L<IntPair> pairs, L<Int> main) { |
3 | long roughCount() { ret l(literals) + l(pairs)*2 + l(main); } |
4 | int nLiterals() { ret l(literals); } |
5 | int nItems() { ret l(literals) + l(pairs); } |
6 | |
7 | IntPair getPair(int symbol) { ret pairs.get(symbol-l(literals)); } |
8 | } |
Began life as a copy of #1028253
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: | #1028479 |
Snippet name: | LineCompedSingle - result of LineComp compression for a single "file" |
Eternal ID of this version: | #1028479/3 |
Text MD5: | 60277813fec3f9b0c89e1a27ffae3d1f |
Transpilation MD5: | 1edf2796bf8b476d5a5b7bc851982459 |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2021-05-20 02:40:49 |
Source code size: | 355 bytes / 8 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 257 / 559 |
Version history: | 2 change(s) |
Referenced in: | [show references] |