brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.6 KiB · aa16eb1 Raw
54 lines · plain
1// Ensure that when rebuilding a module we don't save its old modtime when2// building modules that depend on it.3 4// RUN: rm -rf %t5// RUN: mkdir -p %t6// RUN: split-file %s %t7 8// RUN: cat %t/t.h-1 > %t/t.h9 10// RUN: %clang_cc1 -fmodules -fimplicit-module-maps -fmodules-cache-path=%t -fdisable-module-hash \11// RUN:     -I %t -fsyntax-only %t/main.m -Rmodule-build 2>&1 \12// RUN: | FileCheck -check-prefix=REBUILD-ALL %t/main.m13// RUN: %clang_cc1 -fmodules -fimplicit-module-maps -fmodules-cache-path=%t -fdisable-module-hash \14// RUN:     -I %t -fsyntax-only %t/main.m -Rmodule-build -verify15 16// Add an identifier to ensure everything depending on t is out of date17// RUN: cat %t/t.h-1 %t/t.h-2 > %t/t.h18 19// RUN: %clang_cc1 -fmodules -fimplicit-module-maps -fmodules-cache-path=%t -fdisable-module-hash \20// RUN:     -I %t -fsyntax-only %t/main.m -Rmodule-build 2>&1 \21// RUN: | FileCheck -check-prefix=REBUILD-ALL %t/main.m22// RUN: %clang_cc1 -fmodules -fimplicit-module-maps -fmodules-cache-path=%t -fdisable-module-hash \23// RUN:     -I %t -fsyntax-only %t/main.m -Rmodule-build -verify24 25//--- b.h26@import l; @import r;27 28//--- l.h29@import t; // fromt l30 31//--- r.h32@import t; // fromt r33 34//--- t.h-135// top36 37//--- t.h-238extern int a;39 40//--- module.modulemap41module b { header "b.h" } module l { header "l.h" }42module r { header "r.h" } module t { header "t.h" }43 44//--- main.m45 46// REBUILD-ALL: building module 'b'47// REBUILD-ALL: building module 'l'48// REBUILD-ALL: building module 't'49// REBUILD-ALL: building module 'r'50 51// Use -verify when expecting no modules to be rebuilt.52// expected-no-diagnostics53@import b;54