How does the xcode project for command line tool determine which swift file is the entry point?
I apparently did something wrong in my xcode project (v6.3.1) using Swift. When I try to build, my start statements in Main.swift are flagged with a compiler error: "Statements are not allowed at the top level." This project contains multiple targets, each of which creates multiple Swift files. It's just that my target for the command line is not built that way.
Is there a parameter somewhere in the project file that indicates which Swift file is the main entry point and thus allows top-level instructions to be executed?
source to share
No one has answered this question yet
Check out similar questions: