Swift has the nil-coalescing operator a ?? b which is shorthand for a != nil ? a : b. Does Swift have the opposite operator, a shorthand for a == nil ? a : b or in other words, a == nil ? nil : b?
I would use it to map an optional value to something else, like so:
let x = dict["key"] != nil ? mapValue(dict["key"]) : nil
// ideally: let x = dict["key"] ¿¿ mapValue(dict["key"])