forked from swiftlang/swift
-
Notifications
You must be signed in to change notification settings - Fork 30
Resolve conflicts with upstream main
#3889
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
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
…eir new uses in the outlined call
…tend the borrow scope if needed
We remove the existing `swift_reflection_iterateAsyncTaskAllocations` API that attempts to provide all necessary information about a tasks's allocations starting from the task. Instead, we split it into two pieces: `swift_reflection_asyncTaskSlabPointer` to get the first slab for a task, and `+swift_reflection_asyncTaskSlabAllocations` to get the allocations in a slab, and a pointer to the next slab. We also add a dummy metadata pointer to the beginning of each slab. This allows tools to identify slab allocations on the heap without needing to locate every single async task object. They can then use `swift_reflection_asyncTaskSlabAllocations` on such allocations to find out about the contents. rdar://82549631
…ambiguous If there are multiple overloads and all of them require closure to have a parameter, let's diagnose that as such instead of ambiguity.
…d code While building a closure to inject `checkExpect` code, clone member references associated with assignment. Re-using AST nodes is generally invalid. This is visible with multi-statement closure inference enabled, because the body is type-checked together with enclosing context and both elements end up sharing `DeclRefExpr` and `MemberRefExpr`s.
This preserves previous behavior where multi-statement closures where always type-checked without context.
…Unchecked` flag Propagate `LeaveClosureBodyUnchecked` flag from `typeCheckASTNodeAtLoc` down to declaration checker to skip checking closures associated with pattern binding entry initializers. This is no-op until multi-statement inference becomes enabled by default.
…es when inference is enabled When multi-statement closure inference is enabled it's body is type-checked together with enclosing context, so they could be walked directly just like single-expressions ones.
… closures Extract diagnostic into a method and use it while type-checking `for-in` in top-level code and in closures.
…t inference is enabled Scope down previous check to avoid walking into patterns that appear in multi-statement closures if the inference is enabled.
Preserve pre SE-0326 for code completion, so it could be ported gradually.
Put some common logic related to local declaration to the base class and refactor other walkers to use it instead of `ASTWalker`.
…ic parameter holes Closure result type or generic parameter associated with such a location could bw inferred from a body of a multi-statement closure (when inference is enabled), so we need to give closure a chance to run before attemtping a hole for such positions in diagnostic mode.
Each of the elements in the result builder has to be fully pre-checked now that multi-statement inference has been enabled.
Allow `LinkedExprAnalyzer` to capture `??` operator and walk into its arguments because they could have valuable type information, but don't attempt to favor or link operators if `??` is present in a chain. Resolves: rdar://85277993
Despite being otherwise disconnected from the constraint system, it's possible for it to affect how we type-check tuple matches in certain cases. This is due to the fact that: - It can have a lower type variable ID than an opened generic parameter type, so becomes the representative when merged with it. And because it has a different locator, this can influence binding prioritization. - Tuple subtyping is broken, as it's currently a *weaker* relationship than conversion. Therefore, temporarily restore this bit of logic for language versions < 6. If possible, we should try and fix tuple subtying in Swift 6 mode to not accept label mismatches, so that it's not more permissive than tuple conversion. rdar://85263844
This is something that we'd like to fix to bring in line with tuple conversion, so start warning on cases where it occurs.
SwiftVersionType needs 5 components, and ClangVersionType needs to match SwiftVersionType because some build automation wants to mark the clang version as being the same as the Swift version while generating version numbers. Fixes rdar://85508050
[CSGen] Rework nil-coalescing operator handling in `LinkedExprAnalyzer`
…for-multi-stmt-closures [TypeChecker] SE-0326: Enable multi-statement closure inference by default
These were originally meant to be no-return functions since they're going to abort. They were accidentally changed to no-discard functions despite not having a return value.
…erns Model Sequence Archetypes
This is useful if one wants to quickly compile a stdlib with asan enabled without recompiling the toolchain.
…lab-inspection [Reflection] Add API for inspecting async task allocation slabs.
Fix OSSA Outliner for scoped guaranteed values
…ser-NINJA_STATUS [build] Don't overwrite user NINJA_STATUS
Silence Some Warnings
The latest Long Term Support NDK finally removed binutils, including the bfd/gold linkers and libgcc. This simplifies our Android support, including making lld the default linker for Android. Disable three reflection tests that now fail, likely related to issues with swift-reflection-dump and switching to lld.
…2287592abe13dbc50bbc76d [build-script] Add some standalone stdlib asan variants.
…ror-async-slab-inspection
# Conflicts: # cmake/modules/AddSwift.cmake
kateinoigakukun
approved these changes
Nov 19, 2021
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.