Karoy Lorentey
dbc2866bb5
[Heap] removeAll(where:): Fix exception safety
2025-05-15 21:39:55 -07:00
Karoy Lorentey
333760bd9c
[Heap] Add a test for throwing midway through removeAll(where:)
2025-05-15 21:39:54 -07:00
Dakshin Devanand
c7c38028cd
Add Heap.removeAll(where:)
2025-05-15 21:39:50 -07:00
Karoy Lorentey
ace6afa65b
Merge pull request #455 from DakshinD/heap-max-func
...
Align Heap._UnsafeHandle min/maxValue tie-breaking with Swift.min/max
2025-05-15 21:08:49 -07:00
Karoy Lorentey
225159599d
[Heap] Fix remaining tie break inconsistency in popMax
2025-05-15 17:34:16 -07:00
Karoy Lorentey
4e48f1d0c6
[Heap] Add quick tests for consistent tie breaks
2025-05-15 17:34:14 -07:00
Karoy Lorentey
d93a6ab8a1
[Heap] Follow the spelling of stdlib’s min/max; add note explaining expectations
...
The existing expressions had the same effect, but they used different operators (`<=` instead of `<` and `>` instead of `>=`). The distinction is usually irrelevant, but there is no reason not to just follow what the stdlib is doing exactly.
2025-05-15 17:30:25 -07:00
Karoy Lorentey
e63f444a26
Merge pull request #456 from 3405691582/nocapacity
...
ManagedBuffer.capacity is unavailable on OpenBSD.
2025-05-15 14:57:30 -07:00
Karoy Lorentey
42fd02dd1a
Merge pull request #452 from pm-dev/ordered-set-appending
...
[OrderedSet] Add `OrderedSet.appending(contentsOf:)`
2025-05-15 14:19:55 -07:00
Evan Wilde
302b122f61
Merge pull request #470 from etcwilde/ewilde/install-module-triples
...
Install swiftmodules with full module triple
2025-05-14 16:50:47 -07:00
Evan Wilde
a7fec81fc4
Use full module triple for swift modules
...
Install swiftmodules with the full module triple expected by the
compiler instead of attempting to compute the correct architecture name
in CMake.
2025-05-12 20:34:02 -07:00
Evan Wilde
a9ff98fce6
Remove CMP0091 check
...
CMP0091 was added in CMake 3.15. The minimum version is CMake 3.16 so
we don't need to do the check anymore.
2025-05-12 20:33:56 -07:00
3405691582 and Karoy Lorentey
25509c0b88
Update Sources/HashTreeCollections/HashNode/_HashTreeStatistics.swift
...
Co-authored-by: Karoy Lorentey <klorentey@apple.com >
2025-05-02 17:04:54 -04:00
3405691582
9523b6a85d
ManagedBuffer.capacity is unavailable on OpenBSD.
...
ManagedBuffer.capacity depends on malloc introspection (e.g.,
`malloc_size`), which is not available on this platform -- and is thus
marked as such.
Here, _HashNode.Storage is a ManagedBuffer. Thankfully, the uses of
.capacity are fairly limited: one for statistic purposes, which we just
completely omit on the platform, and the other, setting a minimum
capacity in the header by the buffer's .capacity; the alternative being
setting that minimum capacity directly.
2025-03-29 13:12:52 -04:00
Dakshin Devanand
5edd1be23c
Make Heap._UnsafeHandle min/maxValue tie-breaker consistent with Swift.min/max
2025-03-08 10:08:39 -06:00
Peter Meyers
c5ac12e2bc
Add test
2025-02-20 15:34:26 -05:00
Peter Meyers
e00243217e
[OrderedSet] Add OrderedSet.appending(contentsOf:)
2025-02-20 15:34:04 -05:00
Karoy Lorentey
78b544fbe2
Merge pull request #445 from Gyuni/main
...
[OrderedDictionary Documentation] fix a typo
2025-02-06 17:49:32 -08:00
김봉균
4450b7c622
fix typo
2025-01-07 11:26:40 +09:00
Mishal Shah
52a1f698d5
Merge pull request #426 from apple/github-actions-ci-support
...
[CI] Pull Request testing support via GitHub Actions
2024-11-21 09:01:28 -08:00
Karoy Lorentey
b33922ed29
Disable api-breakage-check
2024-11-18 11:39:08 -08:00
Karoy Lorentey
4442fa0b06
Disable license-header-check
2024-11-18 11:27:13 -08:00
Mishal Shah
214fa1dcca
Update the CI checks
2024-10-25 09:38:36 -07:00
Mishal Shah
c34f6e09cf
Update the CI checks
2024-10-25 00:03:27 -07:00
Mishal Shah
5a152a7e33
Update the CODE_OF_CONDUCT.md to https://swift.org/code-of-conduct
2024-10-24 23:12:39 -07:00
Mishal Shah
f0a95e596c
Merge remote-tracking branch 'origin/main' into github-actions-ci-support
2024-10-24 23:07:38 -07:00
Karoy Lorentey
54e9986195
Merge pull request #427 from lorentey/fix-linter-issues
...
[BTree][NFC] Rephrase some comments
2024-10-21 11:38:42 -07:00
Karoy Lorentey
84087c786e
[BTree] Rephrase some comments
2024-10-21 11:03:33 -07:00
Mishal Shah
4ceb2149ed
[CI] Pull Request testing support via GitHub Actions
2024-10-20 15:45:24 -07:00
Karoy Lorentey
11433b688d
Merge pull request #410 from lorentey/merge-release-1.1→main
2024-08-05 20:42:08 -07:00
Karoy Lorentey
5dd817c33d
Merge branch 'release/1.1'
2024-08-05 20:10:26 -07:00
Yuta Saito
38602cff9f
Merge pull request #408 from kateinoigakukun/yt/wasm-archs
...
[CMake] Add support for WebAssembly target architectures
2024-08-02 01:02:02 +09:00
Yuta Saito
effb33569a
[CMake] Add support for WebAssembly target architectures
...
To repair the swift-corelibs-foundation build on WebAssembly, we need to
add support for Wasm targets to swift-collections' CMake build system.
2024-08-01 00:30:34 +00:00
Karoy Lorentey
293314a584
Merge pull request #403 from quokkaKyu/release/1.1
...
add 'final' keyword to class
2024-07-18 14:38:35 -07:00
Karoy Lorentey
2db08b3d06
Merge pull request #405 from apple/accidentally-quadratic-BigString-init
...
[BigString] Fix accidentally quadratic `BigString.init`
2024-07-15 15:33:11 -07:00
Karoy Lorentey
5e1fe6e8f0
[BigString] Fix accidentally quadratic BigString.init
...
When ingesting a `String` instance, `BigString` assumes that the input string has a reasonably efficient UTF-8 view.
Unfortunately, that is very much not the case when the input happens to be backed by a bridged NSString object — it appears that in this case, the ingester loop invokes some operation(s) with linear complexity in the size of the entire input, rendering the ingester’s overall complexity quadratic.
The BigString ingester is only expected to operate within a single chunk at the time. It’s unclear precisely which operation triggers the quadratic behavior; ideally we should figure it out and resolve it with a more targeted fix.
In the meantime, a blunt stopgap fix is to force-transcode the input string to UTF-8 at the time the ingester is initialized. This unnecessarily wastes some (temporary) memory on holding the transcoded string, but it avoids the quadratic cliff.
2024-07-15 13:13:44 -07:00
quokkakyu
6b8276e252
add 'final' keyword to class
2024-07-15 09:27:27 +09:00
Jeremy Schonfeld
3d2dc41a01
[CMake] Reduce the size of the _FoundationCollections module ( #395 )
1.1.2
2024-07-08 11:23:21 -07:00
Jeremy Schonfeld
3e120b48bb
[CMake] Reduce path lengths in single-module build ( #392 )
...
* Eliminate relative paths from the cmake single-module build
* Attempt to reduce length of paths in single module build
2024-06-26 08:39:11 -07:00
Jeremy Schonfeld
af8349c392
Install the foundation toolchain module during the static swift build ( #391 )
2024-06-18 15:09:16 -07:00
Karoy Lorentey
c60d2f274d
Merge pull request #386 from lorentey/merge.1.1→main
...
Merge release/1.1 to main
2024-06-07 12:16:42 -07:00
Karoy Lorentey
21264913c5
[manifest] Update name of shared utilities module
2024-06-05 18:35:19 -07:00
Karoy Lorentey
ad79ce5b6a
Merge branch 'release/1.1'
...
# Conflicts:
# .swiftci/5_10_ubuntu2204
# .swiftci/5_7_ubuntu2204
# .swiftci/5_8_ubuntu2204
# .swiftci/5_9_ubuntu2204
# .swiftci/nightly_6_0_macos
# .swiftci/nightly_6_0_ubuntu2204
# .swiftci/nightly_main_macos
# .swiftci/nightly_main_ubuntu2204
2024-06-05 10:28:47 -07:00
Jeremy Schonfeld
ee97538f5b
Add Single Module Build Mode to CMake for Foundation ( #385 )
...
* Add new single-module and foundation-toolchain-module modes to CMake build
* Fix allowable client flag syntax
1.1.1
2024-06-03 16:15:50 -07:00
Karoy Lorentey
8253d6d89d
Merge pull request #384 from lorentey/rope-cow-violation
...
[Rope] Fix copy-on-write violation in Rope.join
2024-06-03 09:36:23 -07:00
Karoy Lorentey
a0b839d7de
[Rope] Fix copy-on-write violation in Rope.join
...
Rope.join has a logic error where it fails to properly ensure uniqueness of child node references before zipping the two b-trees together.
rdar://128450202
2024-05-31 17:12:07 -07:00
Karoy Lorentey
6c31865359
[test] Add tests for Rope.join’s copy-on-write behavior
2024-05-31 16:59:25 -07:00
Karoy Lorentey
e166904974
Merge pull request #382 from lorentey/rename-underscored-module
...
Rename _CollectionsUtilities to InternalCollectionsUtilities
2024-05-29 14:58:55 -07:00
Karoy Lorentey
35d5746117
Rename _CollectionsUtilities to InternalCollectionsUtilities
...
We are forced to do this due to an Xcode issue (#364 ) with underscored module names.
This module remains unstable, despite the removal of the underscore. Directly importing it from outside the package remains unsupported. This module and/or its entire contents may go away or change in incompatible ways in any future swift-collections release.
2024-05-29 14:00:13 -07:00
Karoy Lorentey
e74e76afa7
Merge pull request #370 from lorentey/stop-polluting-test-output
...
[test] TreeDictionary.Keys: Remove stray print that’s flooding test output
2024-05-28 17:00:20 -07:00