CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
54 lines
2.8 KiB
C++
54 lines
2.8 KiB
C++
// RUN: rm -rf %t
|
|
// RUN: mkdir %t
|
|
// RUN: split-file --leading-lines %s %t
|
|
// RUN: %clang_cc1 -std=c++20 -pedantic-errors -fexceptions -fcxx-exceptions -triple x86_64-unknown-unknown %t/cwg279_A.cppm -emit-module-interface -o %t/cwg279_A.pcm
|
|
// RUN: %clang_cc1 -std=c++20 -pedantic-errors -fexceptions -fcxx-exceptions -triple x86_64-unknown-unknown %t/cwg279.cpp -fmodule-file=cwg279_A=%t/cwg279_A.pcm -verify=since-cxx20
|
|
// RUN: %clang_cc1 -std=c++23 -pedantic-errors -fexceptions -fcxx-exceptions -triple x86_64-unknown-unknown %t/cwg279_A.cppm -emit-module-interface -o %t/cwg279_A.pcm
|
|
// RUN: %clang_cc1 -std=c++23 -pedantic-errors -fexceptions -fcxx-exceptions -triple x86_64-unknown-unknown %t/cwg279.cpp -fmodule-file=cwg279_A=%t/cwg279_A.pcm -verify=since-cxx20
|
|
// RUN: %clang_cc1 -std=c++2c -pedantic-errors -fexceptions -fcxx-exceptions -triple x86_64-unknown-unknown %t/cwg279_A.cppm -emit-module-interface -o %t/cwg279_A.pcm
|
|
// RUN: %clang_cc1 -std=c++2c -pedantic-errors -fexceptions -fcxx-exceptions -triple x86_64-unknown-unknown %t/cwg279.cpp -fmodule-file=cwg279_A=%t/cwg279_A.pcm -verify=since-cxx20
|
|
|
|
// cwg279: no
|
|
|
|
//--- cwg279_A.cppm
|
|
export module cwg279_A;
|
|
|
|
export {
|
|
struct S; // #cwg279-S
|
|
extern S *q; // #cwg279-q
|
|
|
|
struct S2 {}; // #cwg279-S2
|
|
extern S2 *q2; // #cwg279-q2
|
|
|
|
struct S3 {}; // #cwg279-S3
|
|
extern S3 *q3; // #cwg279-q3
|
|
} // export
|
|
|
|
//--- cwg279.cpp
|
|
import cwg279_A;
|
|
|
|
// FIXME: We should use markers instead. They are less fragile,
|
|
// but -verify doesn't support them across modules yet.
|
|
// FIXME: This is well-formed. Previous "definition" is actually just a declaration.
|
|
typedef struct {} S;
|
|
// since-cxx20-error@-1 {{typedef redefinition with different types ('struct S' vs 'S')}}
|
|
// since-cxx20-note@cwg279_A.cppm:17 {{previous definition is here}}
|
|
extern S *q;
|
|
// since-cxx20-error@-1 {{declaration of 'q' in the global module follows declaration in module cwg279_A}}
|
|
// since-cxx20-note@cwg279_A.cppm:18 {{previous declaration is here}}
|
|
|
|
typedef struct {} S2;
|
|
// since-cxx20-error@-1 {{typedef redefinition with different types ('struct S2' vs 'S2')}}
|
|
// since-cxx20-note@cwg279_A.cppm:20 {{previous definition is here}}
|
|
extern S2 *q2;
|
|
// since-cxx20-error@-1 {{declaration of 'q2' in the global module follows declaration in module cwg279_A}}
|
|
// since-cxx20-note@cwg279_A.cppm:21 {{previous declaration is here}}
|
|
|
|
// FIXME: This is well-formed, because [basic.def.odr]/15 is satisfied.
|
|
struct S3 {};
|
|
// since-cxx20-error@-1 {{declaration of 'S3' in the global module follows declaration in module cwg279_A}}
|
|
// since-cxx20-note@cwg279_A.cppm:23 {{previous declaration is here}}
|
|
extern S3 *q3;
|
|
// since-cxx20-error@-1 {{declaration of 'q3' in the global module follows declaration in module cwg279_A}}
|
|
// since-cxx20-note@cwg279_A.cppm:24 {{previous declaration is here}}
|