Fixed for Swift 1.0