Skip to content
This repository was archived by the owner on Apr 2, 2020. It is now read-only.

Conversation

@slavapestov
Copy link
Member

No description provided.

…Address_Enum()

These two functions are identical, and don't do anything specific
to structs or enums, so let's combine them into one more general
function.
It's not really correct to unwrap existentials in tuple elements because
the resulting concrete tuple type has a different layout than the original
type.

This changes some test output but note that the old behavior was
inconsistent; we would only call GetDynamicTypeAndAddress_Tuple() if the
original type was already generic, so a type like (Error, T) for a generic
parameter 'T' would unwrap the Error payload, whereas a type like
(Error, Int) would not.
@adrian-prantl
Copy link
Member

great!

@adrian-prantl
Copy link
Member

@swift-ci test

@slavapestov
Copy link
Member Author

@adrian-prantl I haven't tested this locally yet. It might not even compile. I'm on it, don't worry.

…rorValue()

Existentials are represented as addresses of values, so a Swift error
existential should be the address of a pointer to an Error container
and not a pointer to the Error container itself.
… substitution

This will allow us to completely eliminate the generic parameter
path.
…generic parameters

This will allow a corresponding simplification on the IRGen side,
since we no longer need to emit debug info for dependent member
types.
They were actually unnecessary and doing the wrong thing when we had generic
parameters wrapping existentials.
@slavapestov
Copy link
Member Author

@swift-ci Please test

@slavapestov
Copy link
Member Author

Should be fixed now

@slavapestov
Copy link
Member Author

Ok, I need to cherry-pick some RemoteAST fixes to swift-5.1-branch on the Swift side too.

@slavapestov
Copy link
Member Author

swiftlang/swift#23285
@swift-ci Please test Linux

@slavapestov slavapestov merged commit 122b93e into apple:swift-5.1-branch Mar 14, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants