[swift-evolution] Property Getter Return Statement
    Jeremy Pereira 
    jeremy.j.pereira at googlemail.com
       
    Thu Oct 12 09:03:18 CDT 2017
    
    
  
> 
> I’m minorly opposed, because it feels like a slippery slope. What about function bodies? etc
> 
> func foo() -> Int { 3 } // should this be allowed?
Yes, why not? What is fundamentally different about a function body compared to a getter body (or a closure body ;-)) that means, if we accept it for getters, we should not also accept it for function bodies.
    
    
More information about the swift-evolution
mailing list