brintos

brintos / llvm-project-archived public Read only

0
0
Text · 4.2 KiB · 0254444 Raw
83 lines · plain
1// RUN: rm -rf %t2 3// Including a header from the imported module4// RUN: echo '@import FromImportedModuleOK;' | \5// RUN:   %clang_cc1 -Wnon-modular-include-in-framework-module -fmodules -fimplicit-module-maps \6// RUN:     -fmodules-cache-path=%t -F %S/Inputs/require-modular-includes \7// RUN:     -Werror -fsyntax-only -x objective-c -8 9// Including a non-modular header10// RUN: echo '@import FromImportedModuleFail;' | \11// RUN:   %clang_cc1 -Wnon-modular-include-in-framework-module -fmodules -fimplicit-module-maps \12// RUN:     -fmodules-cache-path=%t -F %S/Inputs/require-modular-includes \13// RUN:     -I %S/Inputs/require-modular-includes \14// RUN:     -fsyntax-only -x objective-c - 2>&1 | FileCheck %s15 16// Including a header from a subframework17// RUN: echo '@import FromSubframework;' | \18// RUN:   %clang_cc1 -Wnon-modular-include-in-framework-module -fmodules -fimplicit-module-maps \19// RUN:     -fmodules-cache-path=%t -F %S/Inputs/require-modular-includes \20// RUN:     -Werror -fsyntax-only -x objective-c -21 22// Including a header from a subframework (fail)23// RUN: echo '@import FromNonModularSubframework;' | \24// RUN:   %clang_cc1 -Wnon-modular-include-in-framework-module -fmodules -fimplicit-module-maps \25// RUN:     -fmodules-cache-path=%t -F %S/Inputs/require-modular-includes \26// RUN:     -I %S/Inputs/require-modular-includes \27// RUN:     -fsyntax-only -x objective-c - 2>&1 | FileCheck %s28 29// Including a non-modular header from a submodule30// RUN: echo '@import FromImportedSubModule;' | \31// RUN:   %clang_cc1 -Wnon-modular-include-in-framework-module -fmodules -fimplicit-module-maps \32// RUN:     -fmodules-cache-path=%t -F %S/Inputs/require-modular-includes \33// RUN:     -I %S/Inputs/require-modular-includes \34// RUN:     -fsyntax-only -x objective-c - 2>&1 | FileCheck %s35 36// Including a non-modular header (directly) with -fmodule-name set37// RUN: echo '#include "NotInModule.h"' | \38// RUN:   %clang_cc1 -Wnon-modular-include-in-framework-module -fmodules -fimplicit-module-maps \39// RUN:     -fmodules-cache-path=%t -I %S/Inputs/require-modular-includes \40// RUN:     -Werror -fmodule-name=A -fsyntax-only -x objective-c -41 42// Including an excluded header43// RUN: echo '@import IncludeExcluded;' | \44// RUN:   %clang_cc1 -Wnon-modular-include-in-framework-module -fmodules -fimplicit-module-maps \45// RUN:     -fmodules-cache-path=%t -F %S/Inputs/require-modular-includes \46// RUN:     -Werror -fsyntax-only -x objective-c -47 48// Including a header from another module49// RUN: echo '@import FromAnotherModule;' | \50// RUN:   %clang_cc1 -Wnon-modular-include-in-framework-module -fmodules -fimplicit-module-maps \51// RUN:     -fmodules-cache-path=%t -F %S/Inputs/require-modular-includes \52// RUN:     -I %S/Inputs/require-modular-includes \53// RUN:     -Werror -fsyntax-only -x objective-c -54 55// Including an excluded header from another module56// RUN: echo '@import ExcludedFromAnotherModule;' | \57// RUN:   %clang_cc1 -Wnon-modular-include-in-framework-module -fmodules -fimplicit-module-maps \58// RUN:     -fmodules-cache-path=%t -F %S/Inputs/require-modular-includes \59// RUN:     -I %S/Inputs/require-modular-includes \60// RUN:     -Werror -fsyntax-only -x objective-c -61 62// Including a header from an umbrella directory63// RUN: echo '@import FromUmbrella;' | \64// RUN:   %clang_cc1 -Wnon-modular-include-in-framework-module -fmodules -fimplicit-module-maps \65// RUN:     -fmodules-cache-path=%t -F %S/Inputs/require-modular-includes \66// RUN:     -I %S/Inputs/require-modular-includes \67// RUN:     -Werror -fsyntax-only -x objective-c -68 69// A includes B includes non-modular C70// RUN: echo '@import A;' | \71// RUN:   %clang_cc1 -Wnon-modular-include-in-framework-module -fmodules -fimplicit-module-maps \72// RUN:     -fmodules-cache-path=%t -F %S/Inputs/require-modular-includes \73// RUN:     -I %S/Inputs/require-modular-includes \74// RUN:     -fsyntax-only -x objective-c - 2>&1 | FileCheck %s75 76// Non-framework module (pass)77// RUN: echo '@import NotFramework;' | \78// RUN:   %clang_cc1 -Wnon-modular-include-in-framework-module -fmodules -fimplicit-module-maps \79// RUN:     -fmodules-cache-path=%t -I %S/Inputs/require-modular-includes \80// RUN:     -Werror -fsyntax-only -x objective-c -81 82// CHECK: include of non-modular header83