After updating the latest Xcode Version 10.2 (10E125), I am getting this error :
Argument labels '(stringInterpolationSegment:)' do not match any available overloads
Could not find any solution yet, any idea please ?
let interpolation1 = String(stringInterpolationSegment:self.addSpotAnnotation!.coordinate.latitude)
let interpolation2 = String(stringInterpolationSegment:self.addSpotAnnotation!.coordinate.longitude)
let coordinate:String = interpolation1 + "," + interpolation2
The error is due to changes to how string interpolation works in Swift 5.
The solution is not to replace
String(stringInterpolationSegment:)
withString(stringInterpolation:)
:The example you gave:
can much more easily be written as: