Re: [swift-evolution] Synthesizing Equatable, Hashable, and Comparable for tuple types

2017-11-26 Thread John McCall via swift-evolution
> On Nov 27, 2017, at 1:43 AM, David Hart wrote: > On 27 Nov 2017, at 07:32, John McCall > wrote: > >> >>> On Nov 22, 2017, at 2:01 AM, David Hart via swift-evolution >>> mailto:swift-evolution@swift.org>> wrote: >>> >>> >>> On 22 Nov 2017, at 07:48, David Ha

Re: [swift-evolution] Synthesizing Equatable, Hashable, and Comparable for tuple types

2017-11-26 Thread David Hart via swift-evolution
> On 27 Nov 2017, at 07:32, John McCall wrote: > > >>> On Nov 22, 2017, at 2:01 AM, David Hart via swift-evolution >>> wrote: >>> >>> >>> >>> On 22 Nov 2017, at 07:48, David Hart via swift-evolution >>> wrote: >>> >>> >>> >>> On 22 Nov 2017, at 07:41, Douglas Gregor via swift-evoluti

Re: [swift-evolution] Synthesizing Equatable, Hashable, and Comparable for tuple types

2017-11-26 Thread John McCall via swift-evolution
> On Nov 22, 2017, at 2:01 AM, David Hart via swift-evolution > wrote: > > > >> On 22 Nov 2017, at 07:48, David Hart via swift-evolution >> mailto:swift-evolution@swift.org>> wrote: >> >> >> >> On 22 Nov 2017, at 07:41, Douglas Gregor via swift-evolution >> mailto:swift-evolution@swift.o

[swift-evolution] Proposal: Introduce User-defined "Dynamic Member Lookup" Types

2017-11-26 Thread Chris Lattner via swift-evolution
I’d like to formally propose the inclusion of user-defined dynamic member lookup types. Here is my latest draft of the proposal: https://gist.github.com/lattner/b016e1cf86c43732c8d82f90e5ae5438 https://github.com/apple/swift-evolution/pull/768 An implementation of this design is available here:

Re: [swift-evolution] [Pitch] Make Optional, Array, and Dictionary conditionally Equatable

2017-11-26 Thread John McCall via swift-evolution
> On Nov 22, 2017, at 1:08 PM, Douglas Gregor via swift-evolution > wrote: > > > > Sent from my iPhone > > On Nov 22, 2017, at 9:48 AM, Chris Lattner > wrote: > >> IMO this is obvious and you should put it in. >> >> The process serves a purpose: to ensure the e

Re: [swift-evolution] [Pitch] Nested types in protocols (and nesting protocols in types)

2017-11-26 Thread Benjamin Garrigues via swift-evolution
Is there another proposal directly related to namespacing ? This would seem like addressing a bit of the same issue.. As an example i would much prefer writing something like : Package UITableView Class Table : UIView Class Cell : UIView Protocol Delegate Protocol Datasource With each class in a

Re: [swift-evolution] [Pitch] Nested types in protocols (and nesting protocols in types)

2017-11-26 Thread Jonathan Hull via swift-evolution
I would use this pretty much constantly! I thought it was going to be in Swift 4, and have really been missing it… > On Nov 26, 2017, at 8:51 AM, Adrian Zubarev via swift-evolution > wrote: > > > What happened to this? Should we revive this talk? I’d love to finally be > able to nest proto

Re: [swift-evolution] [Pitch] Generalized supertype constraints

2017-11-26 Thread Karl Wagner via swift-evolution
I think this is essential for creating good, general-purpose abstractions with Swift. For example, currently I have a protocol which models a CRUD database. There is some ORM behaviour which translates the DB information in to model objects, but of course, each database might have different req

Re: [swift-evolution] [Pitch] Nested types in protocols (and nesting protocols in types)

2017-11-26 Thread Adrian Zubarev via swift-evolution
What happened to this? Should we revive this talk? I’d love to finally be able to nest protocols in Swift 5 and clean up my code. Am 18. Januar 2017 um 09:48:20, Slava Pestov via swift-evolution (swift-evolution@swift.org) schrieb: I left some review comments here: https://github.com/apple/sw

Re: [swift-evolution] [Pre-pitch] Conditional default arguments

2017-11-26 Thread Jonathan Hull via swift-evolution
I have wanted something similar to this for a while, and haven’t suggested it for a while for the same reason… I can’t really think of a good syntax. My best idea so far is to put it after the function declaration but before the open brace: func myCrazyFunction(myParam: T)->Int