gitoria

tracker

All repositories: gitoria

ReadmeCodePull requestsReleasesTicketsSettings
Commit4b59c03d4b59c03dHM50 mission: doc pathmre4b59c03d/lib/catalog-entries.hl

610 B

  1. // Packed persistent rows; stable sort materializes only temporary comparisons.
  2. import CatalogList from './catalog-list.hl'
  3. import { sortDesc } from './util.hl'
  4. static entryAt = (&list, Number i) => { return list.fetch(i) }
  5. static appendEntry = (&list, &id, &key) => {
  6. list.insert(list.length, id, key)
  7. return null
  8. }
  9. static sortEntries = (&list) => {
  10. rows = []
  11. for (let i = 0; i < list.length; i = i + 2) {
  12. rows.push({ id = entryAt(&list, i) key = entryAt(&list, i + 1) })
  13. }
  14. sorted = sortDesc(&rows)
  15. out = new CatalogList()
  16. for (row of sorted) { appendEntry(&out, &row.id, &row.key) }
  17. return out
  18. }

Branches

Latest commits

  • 4b59c03dHM50 mission: doc pathmre
  • ed526d67HM50 missionmre
  • 2f986ca3Log: RT50 passmre
  • 1c4715a4RT50 mission: day50 repro retestmre
  • 57d1c0dcLog: day50 retest requestmre
  • 60b1f419Log: Anton #336 result, wake checkmre
  • 919a18aalog: scratchmre
  • 6b504440status tidymre
  • 9332bd10log: DP70 livemre
  • be11daa0DP70 brief fixmre
  • 886a7028DP70 brief, HM67 mergedmre
  • b41cdd6dMerge hm67-searchids: packed search IDsmre
  • 385904eaReport HM67 matched heap measurements and gate proofmre
  • e5c9b659Pack retained search IDs into UTF-8 bytesmre
  • 62a5f6c7HM67 brief, HM66 mergedmre
  • b32b8440Merge hm66-catalogindex: packed catalog indexmre
  • 2db0f7adReport HM66 heap measurements and validationmre
  • 6ce15623Pack catalog lists and membership maps in UTF-8 bytesmre
  • 71134e21HM66 briefmre
  • ed4cbab2status timemre