forked from swiftlang/swift
-
Notifications
You must be signed in to change notification settings - Fork 30
Merge main 2022-06-18 #4653
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Merge main 2022-06-18 #4653
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Toolchain installers distributed on https://swift.org/download creates a symbolic link of the toolchain as `swift-latest.xctoolchain`, but postinstall script in this repo creates as `swift-latest`. This patch syncs the difference of symlink name.
3-spaces formatting is inconsistently used for some keys instead of 4 spaces. This change makes the formatting consistent in `update-checkout-config.json`.
The CI currently uses Xcode 13.0 beta 4. It is very likely that if the build starts failing with Xcode 12.x, this will go unnoticed. Let's warn the users to upgrade to a newer version of Xcode.
PR swiftlang#41550 changed from using `SmallVector::set_size` to `resize_for_overwrite` and `truncate`, but in `sourcekitd-repl` changing from `reserve` changed the size just prior to getting the `end()` of the output array, leading to retrieving the end of the resized array, rather than the array prior to resizing. The conversion needs to begin at the original output's end, rather than the resized-to-reserve output size, otherwise the conversion triggers the asserts at lines 101 and 116 (with `res == targetExhausted`).
The IBAction signature does not allow completion handlers, so making IBAction methods async doesn't make sense. Disallowing it statically so it doesn't just break people when they try.
This patch merges the two diagnostics complaining about asynchronous function declarations with incompatible attributes. The two are cdecl and ibaction at the moment.
The fix indentifies the conflicting variables and the expected "join" type e.g. `case .a(let x), .b(let x)` where `a(Int)` and `b(String)`.
Diagnose situations where pattern variables with the same name have conflicting types: ```swift enum E { case a(Int) case b(String) } func test(e: E) { switch e { case .a(let x), .b(let x): ... } } ``` In this example `x` is bound to `Int` and `String` at the same time which is incorrect.
… statements Avoid mutating case label items while solving, instead let's use types recorded in the constraint system for each pattern variable and use that for var reference in the case body. This also helps to detect and diagnose type conflicts while solving.
This adds a note with a possible way to fix the issue, recommending removing the `async` effect and wrapping the body of the function in a task.
This patch teaches the compiler to emit a fix-it to automatically wrap everything in the function in a Task and remove the effects from the function declaration.
See swiftlang#59144 for more on why this is a bad idea. Patch out the synthesized file unit accessor to only clear the source cache, then patch up all the places that were assuming they could iterate over the module's file list and see synthesized files. rdar://94164512
Make frontend flag `-enable-experimental-string-processing` default to true.
rdar://92963081
[cxx-interop] Disable SIL tests failing on aarch64
…ation for structs
Fix assert always triggering in `sourcekitd-repl`
Removed the field.
…tions Disallow async IBAction methods
[ASTContext] Fix unordered member initialization warning (NFC)
Ensure the last node after all of the destructuring really is a dependent generic param type. If it isn't, something has gone horribly wrong.
This seems to have been a thinko that got copied-and-pasted around this file.
…wiftlang#59513) When a distributed-actor-isolated witness is provided for a non-distributed-actor-isolated requirement, always hop to the distributed thunk. While here, mark distributed thunks as being `final`, to ensure that we always statically call them vs. trying to retrieve them from the vtable (since they aren't in the vtable).
[Gardening] Remove a Copy-Pasted Header
Switch From Bitwise to Logical And
…nderscored (swiftlang#59480)" This reverts commit a8ecfc9.
…eavus/underscored-protocols Revert "consider requirements of an underscored protocol to also be underscored"
…tArgument When ClangImporter::Implementation::inferDefaultArgument processes func/method arguments as part of omitNeedlessWordsInFunctionName it processes information about how the typenames for the parameters related to the parameter names to form a parameter names list. The parameter names list is used to determine if the argument label for a function should be clipped based on the typename. So for example a type like NSOrderedCollectionDifferenceCalculationOptions would cause a label ending with "Options" to get clipped so that for instance "withOptions" becomes simply "with". Unfortunately in the context of C++-Interop, the typename for the parameter often resolves to what the type backing the typedef or enum is and not the actual name of the typedef (so `typedef NSUInteger NSOrderedCollectionDifferenceCalculationOptions` resolves to a name of NSUInteger rather than NSOrderedCollectionDifferenceCalculationOptions). This patch seeks to collect a bit more information when processing NS_OPTIONS typedefs and providing that to the calling omitNeedlessWordsInFunctionName to handle more inteligently. In practice this fixes anywhere in Foundatio where `withOptions: NSOrderedCollectionDifferenceCalculationOptions` is used.
[interop][SwiftToCxx] Add support for emitting resilient struct bindings
…e-fixup [c++-interop] Providing information about enum types from inferDefaultArgument
The layout of constant static arrays differs from non-constant static arrays. Therefore use a different mangling to get symbol mismatches if for some reason two modules don't agree on which version a static array is.
Expands to, e.g. `x86_64-apple-macosx99.99` This is useful to test features which are available in a "future" runtime.
* `__swiftImmortalRefCount`: The bit pattern of the ref-count field of immortal objects * `__swiftStaticArrayMetadata`: The metadata used for static arrays.
So far, static arrays had to be put into a writable section, because the isa pointer and the (immortal) ref count field were initialized dynamically at the first use of such an array. But with a new runtime library, which exports the symbols for the (immortal) ref count field and the isa pointer, it's possible to put the whole array into a read-only section. I.e. make it a constant global. rdar://94185998
…rays IRGen: generate static arrays in read-only data sections.
…06-18 Conflicts: utils/darwin-installer-scripts/postinstall utils/update_checkout/update-checkout-config.json
Because it's been defaulted now
Builds will be repaired after swiftlang/swift-experimental-string-processing#500 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.