diff options
Diffstat (limited to 'ACE')
-rw-r--r-- | ACE/ace/Based_Pointer_Repository.cpp | 6 | ||||
-rw-r--r-- | ACE/ace/CDR_Base.cpp | 2 | ||||
-rw-r--r-- | ACE/ace/DLL_Manager.cpp | 2 | ||||
-rw-r--r-- | ACE/ace/Dev_Poll_Reactor.cpp | 2 | ||||
-rw-r--r-- | ACE/ace/Log_Msg.cpp | 2 | ||||
-rw-r--r-- | ACE/ace/Naming_Context.cpp | 4 | ||||
-rw-r--r-- | ACE/ace/Object_Manager.cpp | 2 | ||||
-rw-r--r-- | ACE/ace/Parse_Node.cpp | 5 | ||||
-rw-r--r-- | ACE/ace/Priority_Reactor.cpp | 4 | ||||
-rw-r--r-- | ACE/ace/Proactor.cpp | 2 | ||||
-rw-r--r-- | ACE/ace/Service_Config.cpp | 3 | ||||
-rw-r--r-- | ACE/ace/Service_Types.cpp | 6 | ||||
-rw-r--r-- | ACE/ace/Sig_Handler.cpp | 4 | ||||
-rw-r--r-- | ACE/ace/Svc_Conf_y.cpp | 8 | ||||
-rw-r--r-- | ACE/ace/TP_Reactor.cpp | 2 | ||||
-rw-r--r-- | ACE/ace/Thread_Manager.cpp | 6 | ||||
-rw-r--r-- | ACE/ace/Time_Value.cpp | 4 |
17 files changed, 30 insertions, 34 deletions
diff --git a/ACE/ace/Based_Pointer_Repository.cpp b/ACE/ace/Based_Pointer_Repository.cpp index 6ec16f555ca..1f318131a56 100644 --- a/ACE/ace/Based_Pointer_Repository.cpp +++ b/ACE/ace/Based_Pointer_Repository.cpp @@ -24,9 +24,9 @@ class ACE_Based_Pointer_Repository_Rep { public: // Useful typedefs. - typedef ACE_Map_Manager <void *, size_t, ACE_Null_Mutex> MAP_MANAGER; - typedef ACE_Map_Iterator <void *, size_t, ACE_Null_Mutex> MAP_ITERATOR; - typedef ACE_Map_Entry <void *, size_t> MAP_ENTRY; + using MAP_MANAGER = ACE_Map_Manager<void *, size_t, ACE_Null_Mutex>; + using MAP_ITERATOR = ACE_Map_Iterator<void *, size_t, ACE_Null_Mutex>; + using MAP_ENTRY = ACE_Map_Entry<void *, size_t>; /// Keeps track of the mapping between addresses and their associated /// values. diff --git a/ACE/ace/CDR_Base.cpp b/ACE/ace/CDR_Base.cpp index b87380ee507..05312ecfd61 100644 --- a/ACE/ace/CDR_Base.cpp +++ b/ACE/ace/CDR_Base.cpp @@ -819,7 +819,7 @@ ACE_CDR::Fixed ACE_CDR::Fixed::from_floating (LongDouble val) #elif defined NONNATIVE_LONGDOUBLE typedef LongDouble::NativeImpl BigFloat; #else - typedef LongDouble BigFloat; + using BigFloat = LongDouble; #endif Fixed f; diff --git a/ACE/ace/DLL_Manager.cpp b/ACE/ace/DLL_Manager.cpp index 39aa918d2fb..311a6768bf5 100644 --- a/ACE/ace/DLL_Manager.cpp +++ b/ACE/ace/DLL_Manager.cpp @@ -754,7 +754,7 @@ ACE_DLL_Manager::unload_dll (ACE_DLL_Handle *dll_handle, int force_unload) else { // Declare the type of the symbol: - typedef int (*dll_unload_policy)(void); + using dll_unload_policy = int (*)(); void * const unload_policy_ptr = dll_handle->symbol (ACE_TEXT ("_get_dll_unload_policy"), 1); diff --git a/ACE/ace/Dev_Poll_Reactor.cpp b/ACE/ace/Dev_Poll_Reactor.cpp index 55cb4d4d5a3..0fbd01f8efc 100644 --- a/ACE/ace/Dev_Poll_Reactor.cpp +++ b/ACE/ace/Dev_Poll_Reactor.cpp @@ -1081,7 +1081,7 @@ ACE_Dev_Poll_Reactor::dispatch (Token_Guard &guard) int ACE_Dev_Poll_Reactor::dispatch_timer_handler (Token_Guard &guard) { - typedef ACE_Member_Function_Command<Token_Guard> Guard_Release; + using Guard_Release = ACE_Member_Function_Command<Token_Guard>; Guard_Release release(guard, &Token_Guard::release_token); return this->timer_queue_->expire_single(release); diff --git a/ACE/ace/Log_Msg.cpp b/ACE/ace/Log_Msg.cpp index dbf09f5d3da..ec402e65730 100644 --- a/ACE/ace/Log_Msg.cpp +++ b/ACE/ace/Log_Msg.cpp @@ -999,7 +999,7 @@ ACE_Log_Msg::log (const ACE_TCHAR *format_str, #else // External decls. - typedef void (*PointerToFunction)(...); + using PointerToFunction = void (*)(...); // Check if there were any conditional values set. bool const conditional_values = this->conditional_values_.is_set_; diff --git a/ACE/ace/Naming_Context.cpp b/ACE/ace/Naming_Context.cpp index 52f70b31d1c..2cbd95003f3 100644 --- a/ACE/ace/Naming_Context.cpp +++ b/ACE/ace/Naming_Context.cpp @@ -23,8 +23,8 @@ ACE_BEGIN_VERSIONED_NAMESPACE_DECL // Make life easier later on... -typedef ACE_Local_Name_Space <ACE_MMAP_MEMORY_POOL, ACE_RW_Process_Mutex> LOCAL_NAME_SPACE; -typedef ACE_Local_Name_Space <ACE_LITE_MMAP_MEMORY_POOL, ACE_RW_Process_Mutex> LITE_LOCAL_NAME_SPACE; +using LOCAL_NAME_SPACE = ACE_Local_Name_Space<ACE_MMAP_Memory_Pool, ACE_RW_Process_Mutex>; +using LITE_LOCAL_NAME_SPACE = ACE_Local_Name_Space<ACE_Lite_MMAP_Memory_Pool, ACE_RW_Process_Mutex>; // The ACE_Naming_Context static service object is now defined // by the ACE_Object_Manager, in Object_Manager.cpp. diff --git a/ACE/ace/Object_Manager.cpp b/ACE/ace/Object_Manager.cpp index 40ab1983f49..77426f599b2 100644 --- a/ACE/ace/Object_Manager.cpp +++ b/ACE/ace/Object_Manager.cpp @@ -896,7 +896,7 @@ static ACE_Object_Manager_Manager ACE_Object_Manager_Manager_instance; // This is global so that it doesn't have to be declared in the header // file. That would cause nasty circular include problems. -typedef ACE_Cleanup_Adapter<ACE_Recursive_Thread_Mutex> ACE_Static_Object_Lock_Type; +using ACE_Static_Object_Lock_Type = ACE_Cleanup_Adapter<ACE_Recursive_Thread_Mutex>; static ACE_Static_Object_Lock_Type *ACE_Static_Object_Lock_lock = 0; // ACE_SHOULD_MALLOC_STATIC_OBJECT_LOCK isn't (currently) used by ACE. diff --git a/ACE/ace/Parse_Node.cpp b/ACE/ace/Parse_Node.cpp index c362f07637a..9427476454d 100644 --- a/ACE/ace/Parse_Node.cpp +++ b/ACE/ace/Parse_Node.cpp @@ -51,7 +51,7 @@ ACE_Stream_Node::apply (ACE_Service_Gestalt *config, int &yyerrno) typedef std::list<const ACE_Static_Node *, ACE_Allocator_Std_Adapter<const ACE_Static_Node *> > list_t; #else - typedef std::list<const ACE_Static_Node *> list_t; + using list_t = std::list<const ACE_Static_Node *>; #endif /* ACE_HAS_ALLOC_HOOKS */ list_t mod_list; const ACE_Static_Node *module; @@ -668,8 +668,7 @@ ACE_Function_Node::symbol (ACE_Service_Gestalt *, int &yyerrno, ACE_Service_Object_Exterminator *gobbler) { - typedef ACE_Service_Object *(*ACE_Service_Factory_Ptr) - (ACE_Service_Object_Exterminator *); + using ACE_Service_Factory_Ptr = ACE_Service_Object *(*)(ACE_Service_Object_Exterminator *); ACE_TRACE ("ACE_Function_Node::symbol"); if (this->open_dll (yyerrno) == 0) diff --git a/ACE/ace/Priority_Reactor.cpp b/ACE/ace/Priority_Reactor.cpp index dbb29c3cbe2..dab59c20819 100644 --- a/ACE/ace/Priority_Reactor.cpp +++ b/ACE/ace/Priority_Reactor.cpp @@ -5,10 +5,10 @@ ACE_BEGIN_VERSIONED_NAMESPACE_DECL -typedef ACE_Unbounded_Queue_Iterator<ACE_Event_Tuple> QUEUE_ITERATOR; +using QUEUE_ITERATOR = ACE_Unbounded_Queue_Iterator<ACE_Event_Tuple>; // Its iterator. -typedef ACE_Cached_Allocator<ACE_Node<ACE_Event_Tuple>, ACE_SYNCH_NULL_MUTEX> TUPLE_ALLOCATOR; +using TUPLE_ALLOCATOR = ACE_Cached_Allocator<ACE_Node<ACE_Event_Tuple>, ACE_MT_SYNCH::NULL_MUTEX>; // Defines the memory allocator used, no need for locking because it // is only used in one thread of control. diff --git a/ACE/ace/Proactor.cpp b/ACE/ace/Proactor.cpp index 4b5033a3bf3..c375c39d90e 100644 --- a/ACE/ace/Proactor.cpp +++ b/ACE/ace/Proactor.cpp @@ -790,7 +790,7 @@ ACE_Proactor::timer_queue (ACE_Proactor_Timer_Queue *tq) } // Set the proactor in the timer queue's functor - typedef ACE_Timer_Queue_Upcall_Base<ACE_Handler*,ACE_Proactor_Handle_Timeout_Upcall> TQ_Base; + using TQ_Base = ACE_Timer_Queue_Upcall_Base<ACE_Handler *, ACE_Proactor_Handle_Timeout_Upcall>; TQ_Base * tqb = dynamic_cast<TQ_Base*> (this->timer_queue_); diff --git a/ACE/ace/Service_Config.cpp b/ACE/ace/Service_Config.cpp index 193e54ab823..cce7acc6693 100644 --- a/ACE/ace/Service_Config.cpp +++ b/ACE/ace/Service_Config.cpp @@ -98,8 +98,7 @@ ACE_Threading_Helper<ACE_Null_Mutex>::get (void) * know that upon process exit the SC will still be automaticaly and explicitly * closed by @c ACE_Object_Manager::fini(). */ -typedef ACE_Unmanaged_Singleton<ACE_Service_Config, - ACE_SYNCH_RECURSIVE_MUTEX> ACE_SERVICE_CONFIG_SINGLETON; +using ACE_SERVICE_CONFIG_SINGLETON = ACE_Unmanaged_Singleton<ACE_Service_Config, ACE_MT_SYNCH::RECURSIVE_MUTEX>; /// ctor diff --git a/ACE/ace/Service_Types.cpp b/ACE/ace/Service_Types.cpp index b44fb43f116..0843aa04130 100644 --- a/ACE/ace/Service_Types.cpp +++ b/ACE/ace/Service_Types.cpp @@ -11,9 +11,9 @@ ACE_BEGIN_VERSIONED_NAMESPACE_DECL -typedef ACE_Stream<ACE_SYNCH> MT_Stream; -typedef ACE_Module<ACE_SYNCH> MT_Module; -typedef ACE_Task<ACE_SYNCH> MT_Task; +using MT_Stream = ACE_Stream<ACE_MT_SYNCH>; +using MT_Module = ACE_Module<ACE_MT_SYNCH>; +using MT_Task = ACE_Task<ACE_MT_SYNCH>; ACE_ALLOC_HOOK_DEFINE(ACE_Service_Type_Impl) diff --git a/ACE/ace/Sig_Handler.cpp b/ACE/ace/Sig_Handler.cpp index e91de0b4fb4..efbc170474e 100644 --- a/ACE/ace/Sig_Handler.cpp +++ b/ACE/ace/Sig_Handler.cpp @@ -289,8 +289,8 @@ int ACE_Sig_Handlers::sigkey_ = 0; bool ACE_Sig_Handlers::third_party_sig_handler_ = false; // Make life easier by defining typedefs... -typedef ACE_Fixed_Set <ACE_Event_Handler *, ACE_MAX_SIGNAL_HANDLERS> ACE_SIG_HANDLERS_SET; -typedef ACE_Fixed_Set_Iterator <ACE_Event_Handler *, ACE_MAX_SIGNAL_HANDLERS> ACE_SIG_HANDLERS_ITERATOR; +using ACE_SIG_HANDLERS_SET = ACE_Fixed_Set<ACE_Event_Handler *, ((size_t)20)>; +using ACE_SIG_HANDLERS_ITERATOR = ACE_Fixed_Set_Iterator<ACE_Event_Handler *, ((size_t)20)>; class ACE_Sig_Handlers_Set { diff --git a/ACE/ace/Svc_Conf_y.cpp b/ACE/ace/Svc_Conf_y.cpp index 333682808d5..5e1265369d6 100644 --- a/ACE/ace/Svc_Conf_y.cpp +++ b/ACE/ace/Svc_Conf_y.cpp @@ -189,14 +189,14 @@ typedef int YYSTYPE; #ifdef YYTYPE_UINT8 typedef YYTYPE_UINT8 ace_yytype_uint8; #else -typedef unsigned char ace_yytype_uint8; +using ace_yytype_uint8 = unsigned char; #endif #ifdef YYTYPE_INT8 typedef YYTYPE_INT8 ace_yytype_int8; #elif (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) -typedef signed char ace_yytype_int8; +using ace_yytype_int8 = signed char; #else typedef short int ace_yytype_int8; #endif @@ -204,13 +204,13 @@ typedef short int ace_yytype_int8; #ifdef YYTYPE_UINT16 typedef YYTYPE_UINT16 ace_yytype_uint16; #else -typedef unsigned short int ace_yytype_uint16; +using ace_yytype_uint16 = unsigned short; #endif #ifdef YYTYPE_INT16 typedef YYTYPE_INT16 ace_yytype_int16; #else -typedef short int ace_yytype_int16; +using ace_yytype_int16 = short; #endif #ifndef YYSIZE_T diff --git a/ACE/ace/TP_Reactor.cpp b/ACE/ace/TP_Reactor.cpp index f1bb31bf92f..297fea48a18 100644 --- a/ACE/ace/TP_Reactor.cpp +++ b/ACE/ace/TP_Reactor.cpp @@ -305,7 +305,7 @@ int ACE_TP_Reactor::handle_timer_events (int & /*event_count*/, ACE_TP_Token_Guard &guard) { - typedef ACE_Member_Function_Command<ACE_TP_Token_Guard> Guard_Release; + using Guard_Release = ACE_Member_Function_Command<ACE_TP_Token_Guard>; Guard_Release release(guard, &ACE_TP_Token_Guard::release_token); return this->timer_queue_->expire_single(release); diff --git a/ACE/ace/Thread_Manager.cpp b/ACE/ace/Thread_Manager.cpp index e43f5978bcd..43b884d0459 100644 --- a/ACE/ace/Thread_Manager.cpp +++ b/ACE/ace/Thread_Manager.cpp @@ -1503,7 +1503,7 @@ ACE_Thread_Manager::join (ACE_thread_t tid, ACE_THR_FUNC_RETURN *status) } #endif /* !ACE_HAS_VXTHREADS */ - typedef ACE_Double_Linked_List_Iterator<ACE_Thread_Descriptor> iter_t; + using iter_t = ACE_Double_Linked_List_Iterator<ACE_Thread_Descriptor>; for (iter_t iter (this->thr_list_); !iter.done (); iter.advance ()) { // If threads are created as THR_DETACHED or THR_DAEMON, we @@ -1578,7 +1578,7 @@ ACE_Thread_Manager::wait_grp (int grp_id) -1); #endif /* !ACE_HAS_VXTHREADS */ - typedef ACE_Double_Linked_List_Iterator<ACE_Thread_Descriptor> iter_t; + using iter_t = ACE_Double_Linked_List_Iterator<ACE_Thread_Descriptor>; for (iter_t iter (this->thr_list_); !iter.done (); iter.advance ()) { // If threads are created as THR_DETACHED or THR_DAEMON, we @@ -1868,7 +1868,7 @@ ACE_Thread_Manager::wait_task (ACE_Task_Base *task) -1); #endif /* !ACE_HAS_VXTHREADS */ - typedef ACE_Double_Linked_List_Iterator<ACE_Thread_Descriptor> iter_t; + using iter_t = ACE_Double_Linked_List_Iterator<ACE_Thread_Descriptor>; for (iter_t iter (this->thr_list_); !iter.done (); iter.advance ()) { // If threads are created as THR_DETACHED or THR_DAEMON, we diff --git a/ACE/ace/Time_Value.cpp b/ACE/ace/Time_Value.cpp index 3ed61ccc4fc..19dfcff8c72 100644 --- a/ACE/ace/Time_Value.cpp +++ b/ACE/ace/Time_Value.cpp @@ -232,9 +232,7 @@ ACE_Time_Value::operator *= (double d) // Since this is a costly operation, we try to detect as soon as // possible if we are having a saturation in order to abort the rest // of the computation. - typedef ACE::If_Then_Else<(sizeof (double) > sizeof (time_t)), - double, - long double>::result_type float_type; + using float_type = ACE::If_Then_Else<(sizeof(double) > sizeof(time_t)), double, long double>::result_type; float_type sec_total = static_cast<float_type> (this->sec()); sec_total *= d; |