summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorIvan Maidanski <ivmai@mail.ru>2012-10-07 16:54:02 +0400
committerIvan Maidanski <ivmai@mail.ru>2012-10-07 16:54:02 +0400
commiteb719a75a2029e8000f0a3da254ff4c260f1edca (patch)
treedf1586024c329b8580b71e43f7e5c66f2ff8a99e /tests
parent3cd00dfc57b6b95e1585afd152a4fa4e67fccf6b (diff)
downloadlibatomic_ops-eb719a75a2029e8000f0a3da254ff4c260f1edca.tar.gz
Fix double old/new_w local variables declaration in test_atomic_include
* tests/test_atomic_include.template (test_atomicXX): Move old_w and new_w local variables declaration up to precede the first statement (only if AO_HAVE_double_compare_and_swapXX).
Diffstat (limited to 'tests')
-rw-r--r--tests/test_atomic_include.template8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/test_atomic_include.template b/tests/test_atomic_include.template
index 8593047..8d4efc7 100644
--- a/tests/test_atomic_include.template
+++ b/tests/test_atomic_include.template
@@ -25,6 +25,10 @@ void test_atomicXX(void)
# if defined(AO_HAVE_test_and_setXX)
AO_TS_t z = AO_TS_INITIALIZER;
# endif
+# if defined(AO_HAVE_double_compare_and_swapXX)
+ AO_double_t old_w;
+ AO_double_t new_w;
+# endif
# if defined(AO_HAVE_compare_and_swap_doubleXX) \
|| defined(AO_HAVE_compare_double_and_swap_doubleXX) \
|| defined(AO_HAVE_double_compare_and_swapXX)
@@ -32,10 +36,6 @@ void test_atomicXX(void)
w.AO_val1 = 0;
w.AO_val2 = 0;
# endif
-# if defined(AO_HAVE_double_compare_and_swapXX)
- AO_double_t old_w;
- AO_double_t new_w;
-# endif
# if defined(AO_HAVE_nopXX)
AO_nopXX();