blob: 9b1787bb749b973df49261a3e10a7e185201ac68 [file] [log] [blame]
// RUN: %target-swift-frontend -emit-interface-path - -emit-module -o /dev/null %s -I %S/Inputs/imports-submodule-order/ | %FileCheck %s
// RUN: %target-swift-frontend -emit-interface-path - -emit-module -o /dev/null %s -I %S/Inputs/imports-submodule-order/ -D XY | %FileCheck %s
#if XY
@_exported import X.Submodule
@_exported import Y.Submodule
#else
@_exported import Y.Submodule
@_exported import X.Submodule
#endif
// The order below is not alphabetical, just deterministic given a set of
// imports across any number of files and in any order.
// CHECK-NOT: import
// CHECK: import X.Submodule{{$}}
// CHECK-NEXT: import Y.Submodule{{$}}
// CHECK-NEXT: import X{{$}}
// CHECK-NEXT: import Y{{$}}
// CHECK-NOT: import