
Change the error message from "export declaration can only be used within a module purview" to "export declaration can only be used within a module interface" to be technically accurate. The previous message was misleading because export declarations are actually within a module purview when used in module implementation units, but they are only allowed in module interface units. This addresses the issue pointed out in GitHub issue #149008 where Bigcheese noted that the diagnostic wording was incorrect. Fixes #149008
5 lines
195 B
C++
5 lines
195 B
C++
// RUN: %clang_cc1 -std=c++20 %s -fsyntax-only -verify
|
|
export struct Unit { // expected-error {{export declaration can only be used within a module interface}}
|
|
bool operator<(const Unit &);
|
|
};
|