Skip to content
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

Make when(_ guarantees:) generic #806

Closed
wants to merge 1 commit into from
Closed

Make when(_ guarantees:) generic #806

wants to merge 1 commit into from

Conversation

samrayner
Copy link

I tried this out and it seems to work fine. Is there a reason you restricted when() to Void guarantees that I'm missing?

I'd like to also provide equivalents for the when(_:_:_:...) helpers but that doesn't seem possible without introducing ambiguity.

@samrayner
Copy link
Author

On second thoughts I suppose you'd want these in addition to the Void versions rather than instead of.

@samrayner samrayner closed this Mar 3, 2018
@samrayner samrayner deleted the when-guarantees branch March 3, 2018 09:38
@mxcl
Copy link
Owner

mxcl commented Mar 3, 2018

Yes, we should have this, mainly I haven't added it due to fear of ambiguity and the lack of an easy way to know in advance how it will affect the ambiguity of when. And yes the specialization for Void should stay.

Aside: it's a pity that Swift itself can’t specialize this for us, I'm sure they have reasons, but who ever wants: [Void]?

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.

None yet

2 participants