1 | svoid gazelle_sortBeforeCommit(L<GazelleTree> l, O... _) { |
2 | bool debug = boolPar debugSorting(_); |
3 | sort(l, new Comparator<GazelleTree> { |
4 | public int compare(GazelleTree a, GazelleTree b) { |
5 | if (debug) print("sorting: " + a.line + " / " + b.line); |
6 | int c = ai_goodBadToInt(b.prediction) - ai_goodBadToInt(a.prediction); |
7 | if (debug) print(" " + c); |
8 | if (c != 0) ret c; |
9 | c = gazelle_historyLevelRequired(b.rule()) - gazelle_historyLevelRequired(a.rule()); |
10 | if (debug) print(" " + c); |
11 | ret c; |
12 | } |
13 | }); |
14 | } |
download show line numbers debug dex old transpilations
Travelled to 8 computer(s): bhatertpkbcr, cfunsshuasjs, gwrvuhgaqvyk, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1022550 |
Snippet name: | gazelle_sortBeforeCommit |
Eternal ID of this version: | #1022550/5 |
Text MD5: | b530d7127ad1e904f4dea17401b25e94 |
Author: | stefan |
Category: | javax / gazelle |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2019-03-21 10:09:14 |
Source code size: | 557 bytes / 14 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 342 / 376 |
Version history: | 4 change(s) |
Referenced in: | [show references] |