Via objc.io and Max Howell's retweet, TIL about Swift's inline computed properties. Another one to try on Org Babel.
func greetWorld() {
var message = "hello"
var betterMessage: String {
return "\(message) world"
}
print(betterMessage)
}
greetWorld()