Commit Graph
80 Commits
Author SHA1 Message Date
Karoy Lorentey f5b320c29f Merge pull request #657 from natecook1000/iterable 2026-06-17 19:08:16 -07:00
Karoy Lorentey 3d68fc1107 Clean up the UniqueBox/Ref/MutableRef situation
- UniqueBox is public API, so we cannot remove it in favor of the stdlib’s
- Remove Ref and MutableRef. Keep an internal _MutableRef to work around stdlib limitations.
2026-06-17 18:29:41 -07:00
Karoy Lorentey 7c853751c6 Add IterableIteratorProtocol.mapError 2026-06-17 18:24:03 -07:00
Karoy Lorentey f37fe8e662 Define SwiftStdlib 6.4 with actual version numbers 2026-06-17 14:57:06 -07:00
Karoy Lorentey 816b887369 Update CMake and Xcode build configurations 2026-06-17 14:40:07 -07:00
Karoy Lorentey e31c04143e Update CMake & Xcode build configurations 2026-06-05 18:45:56 -07:00
Karoy Lorentey c3ba833517 Add basic tests for Collections module 2026-05-15 16:57:22 -07:00
Karoy Lorentey 8ecf8c711c [Xcode] Don’t enable traits by default 2026-05-07 16:25:00 -07:00
Karoy Lorentey f196269e7f Define placeholder availability macro for SwiftStdlib 6.5 2026-05-07 16:16:34 -07:00
Karoy Lorentey f83bd74aea Move FormatterFixtures into a nested package 2026-05-07 16:15:02 -07:00
Karoy Lorentey 40c730869d [ContainersPreview] Add more detailed tests for MutableRef’s API surface 2026-05-06 18:34:57 -07:00
Karoy Lorentey 16d6b8e1fe [ContainersPreview] Inout ⟹ MutableRef 2026-05-06 18:28:07 -07:00
Karoy Lorentey a6fd64697a [ContainersPreview] Borrow ⟹ Ref
Also update the type’s public API surface to reflect SE-0519, leaving deprecated aliases for the old names.
2026-05-06 18:00:13 -07:00
Karoy Lorentey 146056a641 [ContainersPreview] Box ⟹ UniqueBox
Also update the type’s public API surface to reflect SE-0517, leaving deprecated aliases for the old names.
2026-05-05 17:31:05 -07:00
Karoy Lorentey 022795168a [BasicContainers] Enable APIs scheduled to ship in 1.5.0
- `RigidArray.nextMutableSpan(after:maximumCount:)`
- `UniqueArray.nextMutableSpan(after:maximumCount:)`
- `RigidDeque.nextMutableSpan(after:maximumCount:)`
- `UniqueDeque.nextMutableSpan(after:maximumCount:)`
- `UniqueArray.init(minimumCapacity:)` (replacing `.init(capacity:)`)
- `UniqueDeque.init(minimumCapacity:)` (replacing `.init(capacity:)`)
- `RigidDeque.index(before:)`
- `UniqueDeque.index(before:)`
- `RigidDeque.formIndex(before:)`
- `UniqueDeque.formIndex(before:)`
2026-05-05 16:01:31 -07:00
Karoy Lorentey 1c95e19aeb [ContainersPreview] Don’t require Container.Index to conform to Comparable
This slows down the default implementations of `distance(from:to:)` and `index(_:offsetBy:limitedBy:)`, but it allows linked lists to conform to `Container`. The trade off seems fair.

While we’re here, flesh out the `BidirectionalContainer` refinements a little, and add `Container.isEmpty` and `._custom[Last]IndexOfEquatableElement(_:)`.

This code is still untested.
2026-04-16 18:04:37 -07:00
Nate Cook efdc1bbd96 Remove BorrowingSequence experimental feature flag
This prevents accidental usage of the experimental stdlib feature,
where the library's implementation is intended instead.
2026-03-27 10:56:44 -05:00
Karoy Lorentey 419e2f7df2 [ContainersPreview] Exhibit A in the case against prototyping things in the stdlib 😞 2026-03-26 17:14:45 -07:00
Karoy Lorentey 1a8db43736 [ContainersPreview] Link BorrowingSequenceTests to xcodeproj; fix its imports 2026-03-26 16:06:49 -07:00
Karoy Lorentey e2b980a4cc SuppressedAssociatedTypes ⟹ SuppressedAssociatedTypesWithDefaults 2026-03-26 14:51:37 -07:00
Karoy Lorentey 70a25f1f69 [ContainersPreview] Bump required toolchain to 6.4 for new protocols 2026-03-26 14:51:08 -07:00
Karoy Lorentey 2364daa6bf [ContainersPreview] Update CMake & Xcode build files 2026-03-17 13:32:12 -07:00
Karoy Lorentey 2e277a949b [ContainersPreview] Add a BorrowingIteratorProtocol.copy() algorithm to turn borrowing iterators into producers 2026-03-17 13:32:11 -07:00
Karoy Lorentey 121462fe19 [ContainersPreview] Add some implementations of .filter 2026-03-16 15:04:30 -07:00
Karoy Lorentey ea00086c7a [ContainersPreview] Update CMake/Xcode build configurations 2026-03-13 10:41:06 -07:00
Karoy Lorentey d9b09ecde8 Update copyright dates 2026-03-05 19:39:20 -08:00
Karoy Lorentey b29e7861b2 Update build configurations 2026-03-05 15:33:27 -08:00
Karoy Lorentey 4160bcb98d [BasicContainers] RigidDictionary, UniqueDictionary: Add debugging methods 2026-03-05 15:33:25 -08:00
Karoy Lorentey ffdc48e67e [BasicContainers] Finalize requirements for hashed containers
- UnstableNoncopyableKeys → UnstableHashedContainers
- Delete the GeneralizedEquatable and GeneralizedHashable protocols, replacing them with the standard generalizations in the 6.4 stdlib
- Require Swift 6.4 for {Rigid,Unique}{Set,Dictionary}.
2026-03-03 16:01:45 -08:00
Karoy Lorentey 978ebeda02 [BasicContainers] Fix spelling of a source file
Renaming `_Htable+Debugging.swift` to `_HTable+Debugging.swift` did not stick — rename the file to `_HTable+Debug.swift` to get rid of the lowercase t for good.
2026-03-02 16:14:20 -08:00
Karoy Lorentey 6ca3b59890 [manifest] Define SwiftStdlib 6.3 2026-02-27 18:05:24 -08:00
Karoy Lorentey d453fa1816 [BasicContainers] RigidSet: Test bulk insertions 2026-02-27 18:02:40 -08:00
Karoy Lorentey 318ac805ea [BasicContainers] Add Index to hashed containers. Implement dictionary iteration using indices 2026-02-27 12:19:54 -08:00
Karoy Lorentey 4df9b24789 [BasicContainers] Fix typo in filename 2026-02-26 16:10:38 -08:00
Karoy Lorentey e8cbb2f528 [BasicContainers] Make some tiny headway into UniqueDictionary test coverage 2026-02-24 16:48:51 -08:00
Karoy Lorentey 0538000ffd [BasicContainers] Hashed containers: Add Equatable/Hashable conformances and related methods 2026-02-24 16:40:45 -08:00
Karoy Lorentey 0e12c9e748 Update CMake and Xcode build configurations 2026-02-23 14:13:42 -08:00
Karoy Lorentey 3941dab5b0 [BasicContainers] Implement removals on RigidSet and UniqueSet
Dictionaries are still to be done.
2026-02-20 18:19:51 -08:00
Karoy Lorentey d318a65867 [BasicContainers] Add UniqueDictionary 2026-02-19 17:57:34 -08:00
Karoy Lorentey a1902c30aa [BasicContainers] Make _HTable nonfrozen and most of its operations noninlinable
This is a nongeneric type, so it makes sense to see if Swift has matured enough to use opaque/resilient types in high-performance contexts. It would be ideal if the core hash table implementation would remain flexible.

We may need to sprinkle some effect attributes over these.
2026-02-19 17:56:22 -08:00
Karoy Lorentey 099aa3b312 [BasicContainers] Add UniqueSet 2026-02-18 22:05:22 -08:00
Karoy Lorentey bf9a7033a0 [BasicContainers] Add early drafts for RigidSet/RigidDictionary 2026-02-16 17:15:59 -08:00
Karoy Lorentey 653a60b8e7 replaceSubrange(_:...) → replace(removing:...) 2026-02-05 14:56:51 -08:00
Karoy Lorentey 6c1d4ab9c8 Update Xcode and CMake build configurations 2026-02-04 23:24:11 -08:00
Karoy Lorentey 030f751515 [BasicContainers] RigidArray, UniqueArray: Fill out missing indexing APIs 2026-02-03 14:06:03 -08:00
Karoy Lorentey 0c376aceb6 [BasicContainers] Move array implementations into subdirectories
(This sets the stage for more data structures in BasicContainers)
2026-02-03 13:05:03 -08:00
Karoy Lorentey eac10abae2 Stop using @_exported import
- Stop using unstable import attributes with undefined/flaky semantics in package contexts.
- Freeze the contents of the Collections module. Do not make the new RigidDeque/UniqueDeque types from there, at least not yet. Replace reexported types with typealiases, and reexported protocol extensions with redefinitions forwarding to a common implementation in the original module.
2026-01-30 12:07:28 -08:00
Karoy Lorentey 27655b8a92 Update Xcode project 2026-01-26 12:31:37 -08:00
Karoy Lorentey 006ab60c42 Xcode/Collections.xcodeproj: Fix ability to build & test BigString 2025-10-10 15:53:16 -07:00
Karoy Lorentey bb8d566833 Adopt package access modifier and get rid of gybbing 2025-09-29 11:56:14 -07:00