
Fixes a regression introduced in commit da00c60dae0040185dc45039c4397f6e746548e9 This functionality was originally added in commit 5834996fefc937d6211dc8c8a5b200068753391a Co-authored-by: Tomasz Kaminski <tomasz.kaminski@sonarsource.com>
27 lines
781 B
C++
27 lines
781 B
C++
// RUN: rm -rf %t
|
|
// RUN: split-file %s %t
|
|
// RUN: cd %t
|
|
|
|
// RUN: %clang_cc1 -std=c++23 m.cppm -emit-module-interface -o m.pcm -fallow-pcm-with-compiler-errors -verify
|
|
// RUN: %clang_cc1 -std=c++23 main.cpp -fmodule-file=m=m.pcm -verify -fallow-pcm-with-compiler-errors -verify
|
|
|
|
// RUN: %clang_cc1 -std=c++23 m.cppm -fmodules-reduced-bmi -emit-module-interface -o m.pcm -fallow-pcm-with-compiler-errors -verify
|
|
// RUN: %clang_cc1 -std=c++23 main.cpp -fmodule-file=m=m.pcm -verify -fallow-pcm-with-compiler-errors -verify
|
|
|
|
//--- m.cppm
|
|
export module m;
|
|
|
|
export int f() {
|
|
return 0;
|
|
}
|
|
|
|
export struct Foo {
|
|
__Int bar; // expected-error {{unknown type name '__Int'}}
|
|
};
|
|
|
|
//--- main.cpp
|
|
// expected-no-diagnostics
|
|
import m; // ok
|
|
|
|
static_assert(__is_same(decltype(f), int())); // ok
|