Search code examples
iosswiftswift-playground

(Swift Playground Template) Module compiled with Swift 5.1 cannot be imported by the Swift 5.1.3 compiler


I have a Swift Playground Template (Xcode 11.1) downloaded from here. While compiling, it told me:

Module compiled with Swift 5.1 cannot be imported by the Swift 5.1.3 compiler

I am using Xcode 11.3.1. Should I upgrade to the newest version or downgrade to some specific versions? How to fix that?


Solution

  • PlaygroundSupport is compiled with Swift 5.1(integrated with Xcode11.1) and it would not be compiled with the newer version of Xcode.

    For the most compatibility, you may download Xcode11.1 and run this template using Xcode11.1 as well.