File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2412,10 +2412,18 @@ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24122412/* end confdefs.h. */
24132413
24142414#include <atomic>
2415- std::atomic<int> x{0};
2415+ #include <cstdint>
2416+ std::atomic<std::uint64_t> x1{0};
2417+ std::atomic<std::uint8_t> x2{0};
2418+ std::atomic<char*> x3{nullptr};
2419+ std::atomic<bool> x4{false};
24162420int main() {
2417- x.fetch_add(1);
2418- return 0;
2421+ x1.fetch_add(1);
2422+ x2.fetch_add(1);
2423+ char temp = 'a';
2424+ x3.store(&temp);
2425+ x4.store(true);
2426+ return 0;
24192427}
24202428
24212429_ACEOF
Original file line number Diff line number Diff line change @@ -63,10 +63,18 @@ echo $(($MAJOR*100000+$MINOR*100+$RELEASE))
6363# Check if simple C++ program using atomic header can compile using AC_COMPILE_IFELSE
6464AC_COMPILE_IFELSE ( [ AC_LANG_SOURCE ( [ [
6565#include <atomic>
66- std::atomic<int> x{0};
66+ #include <cstdint>
67+ std::atomic<std::uint64_t> x1{0};
68+ std::atomic<std::uint8_t> x2{0};
69+ std::atomic<char*> x3{nullptr};
70+ std::atomic<bool> x4{false};
6771int main() {
68- x.fetch_add(1);
69- return 0;
72+ x1.fetch_add(1);
73+ x2.fetch_add(1);
74+ char temp = 'a';
75+ x3.store(&temp);
76+ x4.store(true);
77+ return 0;
7078}
7179] ] ) ] , [ NEED_LIBATOMIC="no"] , [ NEED_LIBATOMIC="yes"] )
7280
You can’t perform that action at this time.
0 commit comments