updates for latest Swift version