forked from swiftlang/swift
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[SR-2660] Do not generate modules for
-g
The following two invocations of `swiftc` behave differently, despite their only difference being the `-g` option: ``` swiftc foo.swift bar.o baz.swiftmodule -o foo swiftc -g foo.swift bar.o baz.swiftmodule -o foo ``` The first invocation compiles `foo.swift`, links it with `bar.o`, and passes the AST information from `baz.swiftmodule` to the linker. The second invocation results in the following error: ``` <unknown>:0: error: cannot load module 'baz' as 'foo' ``` The source of the problem is that the driver determines whether to perform a merge-module action based on the level of debug info requested. Remove this logic so that merge-module actions are only performed when explicitly requested or when otherwise necessary (such as when an Objective-C header is requested to be emitted).
- Loading branch information
Showing
7 changed files
with
33 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters