- **Explanation**: create the symlink from
libswiftCompatibilitySpan.dylib to libswiftCore.dylib in the Swift build
folder as a relative one instead of an absolute one, to support device
testing.
- **Scope**: CMake code that creates the symlink for
libswiftCompatibilitySpan.dylib during builds
- **Issues**: rdar://159314722
- **Original PRs**: #84200
- **Risk**: Low, scope is limited to configurations that run tests on a
machine different form the builder, regular CI tests are not affected
(since symlinks are valid on the builder itself), and packaging
regenerates the symlink with a different mechanism.
- **Testing**: ensured at desk that `stdlib/Span` test can run on a
different machine (i.e. using `remote-run`)
- **Reviewers**: waiting for reviews in the main PR
Explanation: There were some scenarios where we could call an unsafe
function without marking the expression as unsafe. These affect mostly
cases where the function's result is passed to another function or
returned. This PR makes sure we always flag functions with unsafe return
types, even if their result is not stored anywhere for later use.
Issues: rdar://157237301
Original PRs: #83520
Risk: Low, worst case scenario the user has to add redundant unsafe
keywords in strict memory safe mode.
Testing: Added a compiler test.
Reviewers: @DougGregor
This allows us to eliminate a comparison;
https://github.com/swiftlang/swift/pull/83172 will allow the compiler to
do it for us instead in the future.
**Explanation:** Changes the implementation of Span's subscript bounds
checks to use a single unsigned comparison instead of two signed
compares.
**Scope:** Narrow. Does not apply to any other API.
**Issues:** rdar://156068535
**Original PRs:** https://github.com/swiftlang/swift/pull/83150
**Risk:** Low. Minor implementation tweaks to API that is not widely
adopted.
**Testing:** CI
**Reviewers:** @glessard @meg-gupta
- Explanation:
Makes as many of the `span`, `bytes`, `mutableSpan` and `mutableRawSpan`
properties as possible available to backdeployed targets. This is
possible when the implementation only relies on pre-existing code.
- Resolves: rdar://153654652 (https://forums.swift.org/t/80513)
- Risk: low
- Main branch PR: https://github.com/swiftlang/swift/pull/82598
- Reviewed by: @atrick
- Testing: existing tests
**Explanation:** Replace some `precondition` usage that slipped into the
stdlib with `_precondition`
**Resolves:** rdar://152529291
**Main Branch PR:** #82641
**Risk:** Very Low.
**Reviewed By:** @Azoy
Cherry-pick from https://github.com/swiftlang/swift/pull/82641