Skip to content

Conversation

nathawes
Copy link
Contributor

No description provided.

beccadax and others added 16 commits August 20, 2020 16:21
When @compatibility_alias is used with an ObjC generic class, this ends up importing as a generic typealias. PrintAsObjC previously didn’t handle declarations involving these types correctly; it would fail an assertion in asserts compilers, and potentially print an incorrect compatibility header in non-asserts compilers.

This PR makes it so that PrintAsObjC can now correctly use generic typealiases imported from Objective-C modules. It is, of course, still not possible to declare a generic typealias in Swift that will be printed into the Objective-C header.

Fixes rdar://67256866.
Codable's magic previously relied on the subject of every qualified lookup in an
unqualified lookup stack to force the synthesis of this member. This
allowed users to reference CodingKeys transitively through a non-primary input
without qualification. As part of the requestification of name lookup,
this synthesis was moved out of the normal qualified lookup path and into the
Type Checker's semantic lookup entrypoints in order to prevent wild
cycles caused by protocol conformance resolution. In the process, we
forget to restore the synthesis check at this entrypoint.

To patch up the source break this caused, we need to walk the context
stack again and force synthesis. Unfortunately, we're stuck with a hack like
this until we bring Codable's implementation back out of the realm of magic
once more. A future implementation of synthesizeSemanticMembersIfNeeded
should aim to just craft the AST for CodingKeys, but not actually run
any of the semantic checks until we check the conformance to CodingKey.

rdar://65088901, SR-13137
…sing specified additional arguments

To help solving rdar://67079780, this change allows swift-driver to configure scanner using additional
arguments passed down via the batch input JSON file for each module under scanning.
…-electric-boogaloo

Support generic @compatibility_alias in PrintAsObjC
…le-take-2

[Serialization] Serialize isUserAccessible on functions - Take 2
…input

DependenciesScanner: teach batch scanning mode to configure scanner using specified additional arguments
…cess

Patch A Regression in Lookup for CodingKeys
…out` parameters (swiftlang#33584)

Adds forward mode support for `apply` instruction with `inout` arguments.

Example of supported code:
```
func add(_ x: inout Float, _ y: inout Float) -> Float {
  var result = x
  result += y
  return result
}
print(differential(at: 1, 1, in: add)(1, 1)) // prints "2"
```
Fix total bit count for Decl and AbstractFunctionDecl bitfields.
@nathawes
Copy link
Contributor Author

@swift-ci please smoke test

@nathawes
Copy link
Contributor Author

@swift-ci clean smoke test

@nathawes nathawes merged commit 9501a69 into swiftlang:master-rebranch Aug 22, 2020
@nathawes nathawes deleted the fix-missing-include branch August 22, 2020 22:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants