diff options
author | schmidt <douglascraigschmidt@users.noreply.github.com> | 1997-08-08 06:33:13 +0000 |
---|---|---|
committer | schmidt <douglascraigschmidt@users.noreply.github.com> | 1997-08-08 06:33:13 +0000 |
commit | c41d853454849477434d752352640ebd72ddba71 (patch) | |
tree | 8e7bb91cbdea286d86c3eb26421666f9198ade17 /tests/Atomic_Op_Test.cpp | |
parent | 0c27513214115c196fa97c8b72bf1115e94470d1 (diff) | |
download | ATCD-c41d853454849477434d752352640ebd72ddba71.tar.gz |
*** empty log message ***
Diffstat (limited to 'tests/Atomic_Op_Test.cpp')
-rw-r--r-- | tests/Atomic_Op_Test.cpp | 23 |
1 files changed, 17 insertions, 6 deletions
diff --git a/tests/Atomic_Op_Test.cpp b/tests/Atomic_Op_Test.cpp index 38c54ce9025..1dce81cb674 100644 --- a/tests/Atomic_Op_Test.cpp +++ b/tests/Atomic_Op_Test.cpp @@ -22,13 +22,13 @@ #include "ace/Synch.h" #include "tests/test_config.h" +#if defined (ACE_HAS_THREADS) + int main (void) { ACE_START_TEST ("Atomic_Op_Test"); -#if defined (ACE_HAS_THREADS) - ACE_Atomic_Op <ACE_Thread_Mutex, long> foo (5L); ACE_ASSERT (foo == 5L); @@ -47,10 +47,6 @@ main (void) foo = 5L; ACE_ASSERT (foo == 5L); -#else - ACE_ERROR ((LM_ERROR, "threads not supported on this platform\n")); -#endif /* ACE_HAS_THREADS */ - ACE_END_TEST; return 0; } @@ -60,3 +56,18 @@ template class ACE_Atomic_Op<ACE_Thread_Mutex, long>; #elif defined (ACE_HAS_TEMPLATE_INSTANTIATION_PRAGMA) #pragma instantiate ACE_Atomic_Op<ACE_Thread_Mutex, long> #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ + +#else +int +main (void) +{ + ACE_START_TEST ("Atomic_Op_Test"); + + ACE_ERROR ((LM_ERROR, "threads not supported on this platform\n")); + + ACE_END_TEST; + return 0; +} +#endif /* ACE_HAS_THREADS */ + + |