mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
ModuleInterface: Test printing of qualified types from submodules.
This commit is contained in:
@@ -0,0 +1 @@
|
||||
struct HasSubmoduleType {};
|
||||
1
test/ModuleInterface/Inputs/submodule-type/Submodule.h
Normal file
1
test/ModuleInterface/Inputs/submodule-type/Submodule.h
Normal file
@@ -0,0 +1 @@
|
||||
struct SubmoduleType {};
|
||||
@@ -0,0 +1,8 @@
|
||||
module HasSubmodule {
|
||||
header "HasSubmodule.h"
|
||||
export *
|
||||
explicit module Submodule {
|
||||
header "Submodule.h"
|
||||
export *
|
||||
}
|
||||
}
|
||||
11
test/ModuleInterface/submodule-type.swift
Normal file
11
test/ModuleInterface/submodule-type.swift
Normal file
@@ -0,0 +1,11 @@
|
||||
// RUN: %target-swift-emit-module-interface(%t.swiftinterface) %s -module-name ImportsSubmodule -I %S/Inputs/submodule-type
|
||||
// RUN: %target-swift-typecheck-module-from-interface(%t.swiftinterface) -module-name ImportsSubmodule -I %S/Inputs/submodule-type
|
||||
// RUN: %FileCheck %s < %t.swiftinterface
|
||||
|
||||
import HasSubmodule.Submodule
|
||||
|
||||
// CHECK: public func takesHasSubmoduleType(_ x: HasSubmodule.HasSubmoduleType)
|
||||
public func takesHasSubmoduleType(_ x: HasSubmoduleType) {}
|
||||
|
||||
// CHECK: public func takesSubmoduleType(_ x: HasSubmodule.SubmoduleType)
|
||||
public func takesSubmoduleType(_ x: SubmoduleType) {}
|
||||
Reference in New Issue
Block a user