static L<S> definitions_dropInvalidated(Collection<S> l) {
new HashSet<S> invalidated;
new LinkedHashMap<S> data; // global ID -> entry
for (S s : l) {
S text = dropGlobalID(s);
S invalidates = regexpFirstGroup("^\\[invalidate (" + regexp_globalID() + "): .*\\]$", text);
if (invalidates != null)
invalidated.add(invalidates);
else
data.put(orNewGlobalID(getAppendedGlobalID(s)), s);
}
removeAll(data, invalidated);
ret valuesList(data);
}download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1017013 |
| Snippet name: | definitions_dropInvalidated |
| Eternal ID of this version: | #1017013/3 |
| Text MD5: | c4064e5d3564930cda9b201892b8879a |
| Author: | stefan |
| Category: | javax / a.i. |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2018-07-10 17:02:35 |
| Source code size: | 497 bytes / 15 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 871 / 881 |
| Version history: | 2 change(s) |
| Referenced in: | [show references] |