Commit Graph

4 Commits

Author SHA1 Message Date
Jordan Rose
22f9853b76 [ParseableInterface] Turn on -enable-parseable-module-interface always (#23331)
...and remove the option. This is ~technically~ CLI-breaking because
Swift 5 shipped this as a hidden driver option, but it wouldn't have
/done/ anything in Swift 5, so I think it's okay to remove.

Note that if a parseable interface (.swiftinterface) and a binary
interface (.swiftmodule) are both present, the binary one will still
be preferred. This just /allows/ parseable interfaces to be used.

rdar://problem/36885834
2019-03-16 15:31:11 -07:00
Nathan Hawes
e146630b63 [ParseableInterface] Fix failing to build a module when the importing file has errors.
We were checking the parent invocation's DiagnosticEnginer rather than the
subinstance's to determine if there were any errors building the module, which
meant we would fail to load the module if there were errors prior to the import
statement in the importing file.

This also meant code completion would fail to load the module, because it always
emits a bogus error in order to mark the AST as erroneous so that different
parts of the compiler (e.g. the verifier) have less strict assumptions.

rdar://problem/43906499
2019-02-12 12:32:32 -08:00
Brent Royal-Gordon
031166e25b Revert "[ParseableInterface] Fix failing to build a module when the importing file has errors." 2019-02-11 15:59:42 -08:00
Nathan Hawes
2a746da9bc [ParseableInterface] Fix failing to build a module when the importing file has errors.
We were checking the parent invocation's DiagnosticEnginer rather than the
subinstance's to determine if there were any errors building the module, which
meant we would fail to load the module if there were errors prior to the import
statement in the importing file.

This also meant code completion would fail to load the module, because it always
emits a bogus error in order to mark the AST as erroneous so that different
parts of the compiler (e.g. the verifier) have less strict assumptions.

rdar://problem/43906499
2019-02-08 09:08:27 -08:00