Here is the likely story of someone trying to use the swiftc driver for the first time. Maybe they need to troubleshooot their build or provide a reduced test case.
`swiftc -help` lists a set of options. It doesn't explain which modes are supported by the driver: building an exe, building a dylib, building a swiftmodule, building a set of .o files, or whatever.
Since that isn't helpful, the next step is to look at the Swift package manager's output when they build their project. `swift build` output shows them something like:
That obviously implies that running swiftc on a set of swift files with "-emit-module -c" will produce a bunch of object files. So they try this:
The command runs with no diagnostics whatsoever, but fails to produce
any .o files, which is utterly baffling and gives no hint as to what to try next.
We obviously need to explain how to use the driver in `swiftc -help` or directly link to a documentation section.
We also need to print some diagnostics when someone tries to use the driver the same way that swiftpm does, explaining, in brief, how to correctly form a command line for what they are obviously trying to do.
I'm leaving it to Jordan Rose to make more specific suggestions and possibly split this up.