File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
Sources/_TestingInternals Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -18,7 +18,8 @@ const char *swt_getTestingLibraryVersion(void) {
18
18
#if defined(SWT_TESTING_LIBRARY_VERSION)
19
19
// The current environment explicitly specifies a version string to return.
20
20
return SWT_TESTING_LIBRARY_VERSION;
21
- #elif __has_embed("../../VERSION.txt")
21
+ #elif __clang_major__ >= 19
22
+ #if __has_embed("../../VERSION.txt")
22
23
static constinit auto version = [] () constexpr {
23
24
// Read the version from version.txt at the root of the package's repo.
24
25
char version[] = {
@@ -43,6 +44,10 @@ const char *swt_getTestingLibraryVersion(void) {
43
44
#warning SWT_TESTING_LIBRARY_VERSION not defined and VERSION.txt not found: testing library version is unavailable
44
45
return nullptr ;
45
46
#endif
47
+ #else
48
+ #warning SWT_TESTING_LIBRARY_VERSION not defined and could not read from VERSION.txt at compile time: testing library version is unavailable
49
+ return nullptr ;
50
+ #endif
46
51
}
47
52
48
53
void swt_getTestingLibraryCommit (const char *_Nullable *_Nonnull outHash, bool *outModified) {
You can’t perform that action at this time.
0 commit comments