summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHuang-Ming Huang <huangh@ociweb.com>2016-09-21 14:29:22 -0500
committerHuang-Ming Huang <huangh@ociweb.com>2016-09-21 14:29:22 -0500
commiteb42ae1e7cbce5863f79e4519befccb13e8f9018 (patch)
tree543dd2d5675e80f65f7205f4e1ade449e55490dc
parent7771149a115f4225b32990e97b5dc01766058ca4 (diff)
downloadATCD-eb42ae1e7cbce5863f79e4519befccb13e8f9018.tar.gz
Fixed all explicit singleton template instantiation
-rw-r--r--TAO/examples/RTCORBA/Activity/Activity.cpp5
-rw-r--r--TAO/examples/RTCORBA/Activity/Task_Stats.cpp4
-rw-r--r--TAO/examples/RTScheduling/Fixed_Priority_Scheduler/test.cpp4
-rw-r--r--TAO/examples/RTScheduling/MIF_Scheduler/test.cpp4
-rw-r--r--TAO/examples/RTScheduling/Task_Stats.cpp5
-rw-r--r--TAO/orbsvcs/orbsvcs/AV/AV_Core.cpp5
-rw-r--r--TAO/orbsvcs/orbsvcs/AV/sfp.cpp4
-rw-r--r--TAO/orbsvcs/orbsvcs/FtRtEvent/EventChannel/GroupInfoPublisher.cpp4
-rw-r--r--TAO/orbsvcs/orbsvcs/Scheduler_Factory.cpp4
-rw-r--r--TAO/orbsvcs/tests/Notify/lib/LookupManager.cpp4
-rw-r--r--TAO/orbsvcs/tests/Notify/lib/Periodic_Supplier.cpp4
-rw-r--r--TAO/performance-tests/Cubit/TAO/MT_Cubit/Globals.cpp4
-rw-r--r--TAO/tests/Alt_Mapping/helper.cpp4
-rw-r--r--TAO/tests/Alt_Mapping/options.cpp4
-rw-r--r--TAO/tests/POA/DSI/Database_i.cpp4
-rw-r--r--TAO/tests/Param_Test/helper.cpp4
-rw-r--r--TAO/tests/Param_Test/options.cpp4
17 files changed, 20 insertions, 51 deletions
diff --git a/TAO/examples/RTCORBA/Activity/Activity.cpp b/TAO/examples/RTCORBA/Activity/Activity.cpp
index 67ebca5e150..89ff0aa17e5 100644
--- a/TAO/examples/RTCORBA/Activity/Activity.cpp
+++ b/TAO/examples/RTCORBA/Activity/Activity.cpp
@@ -401,6 +401,5 @@ ACE_TMAIN(int argc, ACE_TCHAR *argv[])
return rc;
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<Activity, ACE_Null_Mutex> *ACE_Singleton<Activity, ACE_Null_Mutex>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, Activity, ACE_Null_Mutex);
+
diff --git a/TAO/examples/RTCORBA/Activity/Task_Stats.cpp b/TAO/examples/RTCORBA/Activity/Task_Stats.cpp
index d76aba08b65..9998b2bf3b7 100644
--- a/TAO/examples/RTCORBA/Activity/Task_Stats.cpp
+++ b/TAO/examples/RTCORBA/Activity/Task_Stats.cpp
@@ -138,6 +138,4 @@ Task_Stats::dump_latency_stats (
tmin,tmax);
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<Base_Time, TAO_SYNCH_MUTEX> *ACE_Singleton<Base_Time, TAO_SYNCH_MUTEX>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, Base_Time, TAO_SYNCH_MUTEX);
diff --git a/TAO/examples/RTScheduling/Fixed_Priority_Scheduler/test.cpp b/TAO/examples/RTScheduling/Fixed_Priority_Scheduler/test.cpp
index df9a095bf50..92b8bcd4242 100644
--- a/TAO/examples/RTScheduling/Fixed_Priority_Scheduler/test.cpp
+++ b/TAO/examples/RTScheduling/Fixed_Priority_Scheduler/test.cpp
@@ -289,6 +289,4 @@ ACE_TMAIN(int argc, ACE_TCHAR *argv[])
return status;
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<DT_Test, TAO_SYNCH_MUTEX> *ACE_Singleton<DT_Test, TAO_SYNCH_MUTEX>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, DT_Test, TAO_SYNCH_MUTEX);
diff --git a/TAO/examples/RTScheduling/MIF_Scheduler/test.cpp b/TAO/examples/RTScheduling/MIF_Scheduler/test.cpp
index 33aae3ce537..612fc46bb0f 100644
--- a/TAO/examples/RTScheduling/MIF_Scheduler/test.cpp
+++ b/TAO/examples/RTScheduling/MIF_Scheduler/test.cpp
@@ -187,6 +187,4 @@ ACE_TMAIN(int argc, ACE_TCHAR *argv[])
return status;
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<DT_Test, TAO_SYNCH_MUTEX> *ACE_Singleton<DT_Test, TAO_SYNCH_MUTEX>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, DT_Test, TAO_SYNCH_MUTEX);
diff --git a/TAO/examples/RTScheduling/Task_Stats.cpp b/TAO/examples/RTScheduling/Task_Stats.cpp
index 37a0f835ef0..053ffaf63a2 100644
--- a/TAO/examples/RTScheduling/Task_Stats.cpp
+++ b/TAO/examples/RTScheduling/Task_Stats.cpp
@@ -97,6 +97,5 @@ Task_Stats::dump_samples (const ACE_TCHAR *file_name, const ACE_TCHAR *msg)
"Samples are ready to view\n"));
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<Task_Stats, TAO_SYNCH_MUTEX> *ACE_Singleton<Task_Stats, TAO_SYNCH_MUTEX>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, Task_Stats, TAO_SYNCH_MUTEX);
+
diff --git a/TAO/orbsvcs/orbsvcs/AV/AV_Core.cpp b/TAO/orbsvcs/orbsvcs/AV/AV_Core.cpp
index 5c6b24a29bc..258748474d7 100644
--- a/TAO/orbsvcs/orbsvcs/AV/AV_Core.cpp
+++ b/TAO/orbsvcs/orbsvcs/AV/AV_Core.cpp
@@ -1146,8 +1146,7 @@ TAO_AV_Core::get_control_flowname(const char *flowname)
return flowname;
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<TAO_AV_Core, ACE_Null_Mutex> *ACE_Singleton<TAO_AV_Core, ACE_Null_Mutex>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, TAO_AV_Core, ACE_Null_Mutex);
+
TAO_END_VERSIONED_NAMESPACE_DECL
diff --git a/TAO/orbsvcs/orbsvcs/AV/sfp.cpp b/TAO/orbsvcs/orbsvcs/AV/sfp.cpp
index 20067f9e90e..e3f519b6152 100644
--- a/TAO/orbsvcs/orbsvcs/AV/sfp.cpp
+++ b/TAO/orbsvcs/orbsvcs/AV/sfp.cpp
@@ -1320,9 +1320,7 @@ TAO_SFP_Frame_State::reset (void)
return 0;
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<TAO_SFP_Base, TAO_SYNCH_MUTEX> *ACE_Singleton<TAO_SFP_Base, TAO_SYNCH_MUTEX>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, TAO_SFP_Base, TAO_SYNCH_MUTEX);
TAO_END_VERSIONED_NAMESPACE_DECL
diff --git a/TAO/orbsvcs/orbsvcs/FtRtEvent/EventChannel/GroupInfoPublisher.cpp b/TAO/orbsvcs/orbsvcs/FtRtEvent/EventChannel/GroupInfoPublisher.cpp
index 2971584dfe6..7b204e99b7c 100644
--- a/TAO/orbsvcs/orbsvcs/FtRtEvent/EventChannel/GroupInfoPublisher.cpp
+++ b/TAO/orbsvcs/orbsvcs/FtRtEvent/EventChannel/GroupInfoPublisher.cpp
@@ -147,8 +147,6 @@ GroupInfoPublisherBase::update_info(GroupInfoPublisherBase::Info_ptr& info)
info_ = info;
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<GroupInfoPublisherBase, TAO_SYNCH_MUTEX> *ACE_Singleton<GroupInfoPublisherBase, TAO_SYNCH_MUTEX>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, GroupInfoPublisherBase, TAO_SYNCH_MUTEX);
TAO_END_VERSIONED_NAMESPACE_DECL
diff --git a/TAO/orbsvcs/orbsvcs/Scheduler_Factory.cpp b/TAO/orbsvcs/orbsvcs/Scheduler_Factory.cpp
index c894c027050..43f90c1aedb 100644
--- a/TAO/orbsvcs/orbsvcs/Scheduler_Factory.cpp
+++ b/TAO/orbsvcs/orbsvcs/Scheduler_Factory.cpp
@@ -775,8 +775,6 @@ ACE_Scheduler_Factory::set_preemption_priority
#endif /* HPUX && !g++ */
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<ACE_Scheduler_Factory_Data, ACE_Null_Mutex> *ACE_Singleton<ACE_Scheduler_Factory_Data, ACE_Null_Mutex>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, ACE_Scheduler_Factory_Data, ACE_Null_Mutex);
TAO_END_VERSIONED_NAMESPACE_DECL
diff --git a/TAO/orbsvcs/tests/Notify/lib/LookupManager.cpp b/TAO/orbsvcs/tests/Notify/lib/LookupManager.cpp
index f78102f88ef..492a6a2f2bf 100644
--- a/TAO/orbsvcs/tests/Notify/lib/LookupManager.cpp
+++ b/TAO/orbsvcs/tests/Notify/lib/LookupManager.cpp
@@ -219,6 +219,4 @@ TAO_Notify_Tests_LookupManager::resolve (CosNotifyFilter::FilterAdmin_var& filte
filter_admin = CosNotifyFilter::FilterAdmin::_narrow (object.in());
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<TAO_Notify_Tests_LookupManager, TAO_SYNCH_MUTEX> *ACE_Singleton<TAO_Notify_Tests_LookupManager, TAO_SYNCH_MUTEX>::singleton_;
-#endif /*ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, TAO_Notify_Tests_LookupManager, TAO_SYNCH_MUTEX);
diff --git a/TAO/orbsvcs/tests/Notify/lib/Periodic_Supplier.cpp b/TAO/orbsvcs/tests/Notify/lib/Periodic_Supplier.cpp
index 78415f88ea5..6fb6b4f1306 100644
--- a/TAO/orbsvcs/tests/Notify/lib/Periodic_Supplier.cpp
+++ b/TAO/orbsvcs/tests/Notify/lib/Periodic_Supplier.cpp
@@ -340,6 +340,4 @@ TAO_Notify_Tests_Periodic_Supplier::dump_stats (ACE_TCHAR* msg, int dump_samples
stats_.dump_samples (fname.c_str (), buf, dump_samples);
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<Base_Time, TAO_SYNCH_MUTEX> *ACE_Singleton<Base_Time, TAO_SYNCH_MUTEX>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, Base_Time, TAO_SYNCH_MUTEX);
diff --git a/TAO/performance-tests/Cubit/TAO/MT_Cubit/Globals.cpp b/TAO/performance-tests/Cubit/TAO/MT_Cubit/Globals.cpp
index 9d918022ac4..2a7be3a0ac0 100644
--- a/TAO/performance-tests/Cubit/TAO/MT_Cubit/Globals.cpp
+++ b/TAO/performance-tests/Cubit/TAO/MT_Cubit/Globals.cpp
@@ -220,6 +220,4 @@ MT_Priority::grain (void)
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<Globals, ACE_Null_Mutex> *ACE_Singleton<Globals, ACE_Null_Mutex>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, Globals, ACE_Null_Mutex);
diff --git a/TAO/tests/Alt_Mapping/helper.cpp b/TAO/tests/Alt_Mapping/helper.cpp
index 8921f8f74cd..b1c28b87cc1 100644
--- a/TAO/tests/Alt_Mapping/helper.cpp
+++ b/TAO/tests/Alt_Mapping/helper.cpp
@@ -104,6 +104,4 @@ Generator::gen_fixed_struct (void)
return this->fixed_struct_;
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<Generator, ACE_Recursive_Thread_Mutex> *ACE_Singleton<Generator, ACE_Recursive_Thread_Mutex>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, Generator, ACE_Recursive_Thread_Mutex);
diff --git a/TAO/tests/Alt_Mapping/options.cpp b/TAO/tests/Alt_Mapping/options.cpp
index 99a828a576a..fc146142491 100644
--- a/TAO/tests/Alt_Mapping/options.cpp
+++ b/TAO/tests/Alt_Mapping/options.cpp
@@ -162,6 +162,4 @@ Options::shutdown (void) const
return this->shutdown_;
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<Options, ACE_Recursive_Thread_Mutex> *ACE_Singleton<Options, ACE_Recursive_Thread_Mutex>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, Options, ACE_Recursive_Thread_Mutex);
diff --git a/TAO/tests/POA/DSI/Database_i.cpp b/TAO/tests/POA/DSI/Database_i.cpp
index 09554524fb5..7dae7d83b32 100644
--- a/TAO/tests/POA/DSI/Database_i.cpp
+++ b/TAO/tests/POA/DSI/Database_i.cpp
@@ -369,6 +369,4 @@ DatabaseImpl::Employee::operator delete (void *ptr, const ACE_nothrow_t&) throw
#endif /* ACE_HAS_NEW_NOTHROW */
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<DatabaseImpl::Simpler_Database_Malloc, ACE_Null_Mutex> *ACE_Singleton<DatabaseImpl::Simpler_Database_Malloc, ACE_Null_Mutex>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, DatabaseImpl::Simpler_Database_Malloc, ACE_Null_Mutex);
diff --git a/TAO/tests/Param_Test/helper.cpp b/TAO/tests/Param_Test/helper.cpp
index 576ab86f6f1..8e5b49caf59 100644
--- a/TAO/tests/Param_Test/helper.cpp
+++ b/TAO/tests/Param_Test/helper.cpp
@@ -113,6 +113,4 @@ Generator::gen_step (void)
return this->step_;
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<Generator, ACE_Recursive_Thread_Mutex> *ACE_Singleton<Generator, ACE_Recursive_Thread_Mutex>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, Generator, ACE_Recursive_Thread_Mutex);
diff --git a/TAO/tests/Param_Test/options.cpp b/TAO/tests/Param_Test/options.cpp
index 6539b3a8dcf..52dc12bd4ba 100644
--- a/TAO/tests/Param_Test/options.cpp
+++ b/TAO/tests/Param_Test/options.cpp
@@ -229,6 +229,4 @@ Options::shutdown (void) const
return this->shutdown_;
}
-#if defined (ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION)
-template ACE_Singleton<Options, ACE_Recursive_Thread_Mutex> *ACE_Singleton<Options, ACE_Recursive_Thread_Mutex>::singleton_;
-#endif /* ACE_HAS_EXPLICIT_STATIC_TEMPLATE_MEMBER_INSTANTIATION */
+ACE_SINGLETON_TEMPLATE_INSTANTIATE(ACE_Singleton, Options, ACE_Recursive_Thread_Mutex);