-
Notifications
You must be signed in to change notification settings - Fork 12.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[libc][pthread] fix -Wmissing-field-initializers (#126314)
Fixes: llvm-project/libc/test/integration/src/pthread/pthread_rwlock_test.cpp:59:29: warning: missing field '__preference' initializer [-Wmissing-field-initializers] 59 | pthread_rwlock_t rwlock = PTHREAD_RWLOCK_INITIALIZER; | ^ Also, add a test that demonstrates the same issue for PTHREAD_MUTEX_INITIALIZER, and fix that, too. PTHREAD_ONCE_INIT does not have this issue and does have test coverage.
- Loading branch information
1 parent
37952ef
commit 3e02069
Showing
3 changed files
with
36 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -328,6 +328,8 @@ add_macro_header( | |
pthread_macros | ||
HDR | ||
pthread-macros.h | ||
DEPENDS | ||
.null_macro | ||
) | ||
|
||
add_macro_header( | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters