Invoke Explicit Interface Build when '-explicit-interface-module-build' is specified on a '-compile-module-from-interface' frontend action, using the CompilerInstance instantiated directly from the command-line in order to build the module.

This commit is contained in:
Artem Chikin
2022-08-05 07:41:34 -07:00
parent a90d3e2de1
commit aee45799b8
3 changed files with 21 additions and 12 deletions

View File

@@ -0,0 +1,12 @@
// swift-interface-format-version: 1.0
// swift-module-flags: -module-name DoesNotIgnoreFlags -module-interface-preserve-types-as-written
// REQUIRES: OS=macosx
// RUN: %empty-directory(%t)
// Without '-explicit-interface-module-build' this job fails because of the mismatch in 'module-name'
// RUN: %target-swift-frontend -compile-module-from-interface -module-name IgnoresFlags -explicit-interface-module-build -o %/t/IgnoresFlags.swiftmodule %s -verify
import Swift
extension Int {
public static var fortytwo: Int = 42
}