llvm-project/clang/test/CXX/module
Alan Zhao 6f2b347895 Add missing `struct` keyword to the test p2-2.cpp
While working on D53847, I noticed that this test would fail once we
started recognizing the types in the modified `export` statement [0].
The tests would fail because Clang would emit a "declaration does not
declare anything" diagnostic instead of the expected namespace scope
diagnostic.

I believe that the test is currently incorrectly passing because Clang
doesn't parse the type and therefore doesn't treat the statement as a
declaration. My understanding is that the intention of this test case is
that it wants to export a `struct` type, which I believe requires a
`struct` keyword, even for types with template parameters. With this
change, the only error with these two statements should be the
namespace scope issue.

[0]: https://reviews.llvm.org/D53847?id=462032#inline-1297053

Reviewed By: erichkeane

Differential Revision: https://reviews.llvm.org/D134578
2022-09-28 09:48:00 -07:00
..
module.context [C++20] [Module] Support reachable definition initially/partially 2022-06-29 12:48:48 +08:00
module.import [C++20] [Module] Support reachable definition initially/partially 2022-06-29 12:48:48 +08:00
module.interface Add missing `struct` keyword to the test p2-2.cpp 2022-09-28 09:48:00 -07:00
module.private.frag [NFC] [C++20] [Modules] Add test to show private module fragment is not allowed in partition unit 2022-03-09 19:05:54 +08:00
module.reach [NFC] Add an invalid test case for clang/test/CXX/module/module.reach/ex1.cpp 2022-08-31 13:02:00 +08:00
module.unit [C++20] [Module] Support reachable definition initially/partially 2022-06-29 12:48:48 +08:00