HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
apple
swift-collections
Swift2021–2025
apple / swift-collections

swift-collections

Commonly used data structures for Swift

3Distinct people
3Mentions
0Explicit recommenders
4.6KGitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

Commonly used data structures for Swift

GitHub

Where it is used

No documented product use has been verified yet.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

No other repository is repeatedly linked in the same discussions.

This week on Hacker News

Nov 7–Nov 14 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/14/2026, 3:56:07 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year3 dated mentions

Observed mentions: 2021-04-06 20:20:47 UTC to 2025-01-15 20:13:37 UTC.

012021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 1 mentions; 1 submissions, 0 comments20212022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 1 mentions; 1 submissions, 0 comments2023-01-01 00:00:00 UTC to 2024-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments20232024-01-01 00:00:00 UTC to 2025-01-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2025-01-01 00:00:00 UTC to 2026-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2025

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC110
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC110
20232023-01-01 00:00:00 UTC2024-01-01 00:00:00 UTC000
20242024-01-01 00:00:00 UTC2025-01-01 00:00:00 UTC000
20252025-01-01 00:00:00 UTC2026-01-01 00:00:00 UTC101

What Hacker News says

3 sources
If you'd like an example of how this can be done, Swift's AttributedString type is exactly that. It manages the association of runs of attributes (font, kerning, color, etc.) with Unicode text, and its backing storage uses a rope type provided by the swift-collections package. (The rope module itself isn't stabilized yet, so it's really only used for AttributedString at this point, AFAIK.) https://github.com/swiftlang/swift-foundation/tree/main/Sour... https://github.com/apple/swift-collections/tree/main/Sources...
In Ropey – A UTF8 text rope for manipulating and editing large texts. in Rust

Show HN: Bike – macOS Native Outliner

Bike’s most original feature is the “fluid” text editing. Lots of text editors have animated some interactions (cursor movement, insert newline, etc), but I think Bike is the first designed from the ground up to support fluid editing. Give it a try, it feels different. (movie on home page if you don't have Mac) Other Features: • In text mode Bike works like a normal text editor. In outline mode rows are constrained to outline hierarchy. • .bike file format is HTML subset, so files are easy to parse and manipulate. Bike also supports .opml and .txt. • Scriptable via AppleScript. Javascript plugin API also expected in future, though no timing on that. • Architecture needed to support fluid editing also makes Bike faster/more scalable than most (all?) outliners and many text editors. I test performance using the Moby Dick Workout[^1]. Implem
Read the rest
entation Notes: • View is built using CALayers[^2]. • Animations are performed by Core animation and Motion[^3] lib. • View performance is determined by visible text, not document size. Model representation is interesting in that it’s just a flat list of rows. Each row has a `level` property, outline structure is determined dynamically. View implementation requires that each row has a unique ID. I’m using OrderedDictionary from Swift Collections[^4] to store rows. This is Bike’s performance bottleneck for large outlines. Eventually I may change to augmented b+tree and then should be able to work with gigabytes worth of outline. That will be fun, but not sure it’s actually needed. Already probably fast enough for 99% of use cases as is. Hope you find Bike interesting. I’m happy to answer any questions. [^1]: https://www.hogbaysoftware.com/posts/moby-dick-workout/ [^2]: https://developer.apple.com/documentation/quartzcore/calayer [^3]: https://github.com/b3ll/Motion [^4]: https://github.com/apple/swift-collections
513 points · Open discussion

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.