diff options
author | parsons <parsons@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2003-06-17 15:09:25 +0000 |
---|---|---|
committer | parsons <parsons@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2003-06-17 15:09:25 +0000 |
commit | b6b3d651a79ba2274fd3cf91c2b1bf5ea00cacd0 (patch) | |
tree | 322f3df305d9c8338bb17bd0d4119377a61c7c56 /TAO/TAO_IDL/be | |
parent | 5c6e27500cde3fed1956b431028fbf26a44b884b (diff) | |
download | ATCD-b6b3d651a79ba2274fd3cf91c2b1bf5ea00cacd0.tar.gz |
ChangeLogTag: Tue Jun 17 09:56:38 2003 Jeff Parsons <j.parsons@vanderbilt.edu>
Diffstat (limited to 'TAO/TAO_IDL/be')
44 files changed, 774 insertions, 318 deletions
diff --git a/TAO/TAO_IDL/be/be_argument.cpp b/TAO/TAO_IDL/be/be_argument.cpp index 0a4fc22ffc5..a46c0d4f8d3 100644 --- a/TAO/TAO_IDL/be/be_argument.cpp +++ b/TAO/TAO_IDL/be/be_argument.cpp @@ -27,20 +27,28 @@ ACE_RCSID (be, "$Id$") be_argument::be_argument (void) + : COMMON_Base (), + AST_Decl (), + AST_Field (), + AST_Argument (), + be_decl () { } be_argument::be_argument (AST_Argument::Direction d, AST_Type *ft, UTL_ScopedName *n) - : AST_Argument (d, - ft, - n), + : COMMON_Base (), + AST_Decl (AST_Decl::NT_argument, + n), AST_Field (AST_Decl::NT_argument, ft, n), - AST_Decl (AST_Decl::NT_argument, - n) + AST_Argument (d, + ft, + n), + be_decl (AST_Decl::NT_argument, + n) { } diff --git a/TAO/TAO_IDL/be/be_array.cpp b/TAO/TAO_IDL/be/be_array.cpp index f564a48276a..1032e8011ca 100644 --- a/TAO/TAO_IDL/be/be_array.cpp +++ b/TAO/TAO_IDL/be/be_array.cpp @@ -33,6 +33,13 @@ ACE_RCSID (be, "$Id$") be_array::be_array (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_ConcreteType (), + AST_Array (), + be_decl (), + be_type () { } @@ -41,20 +48,24 @@ be_array::be_array (UTL_ScopedName *n, UTL_ExprList *dims, idl_bool local, idl_bool abstract) - : be_type (AST_Decl::NT_array, - n), - be_decl (AST_Decl::NT_array, - n), + : COMMON_Base (local, + abstract), + AST_Decl (AST_Decl::NT_array, + n, + I_TRUE), + AST_Type (AST_Decl::NT_array, + n), + AST_ConcreteType (AST_Decl::NT_array, + n), AST_Array (n, ndims, dims, local, abstract), - AST_Decl (AST_Decl::NT_array, - n, - I_TRUE), - COMMON_Base (local, - abstract) + be_decl (AST_Decl::NT_array, + n), + be_type (AST_Decl::NT_array, + n) { } diff --git a/TAO/TAO_IDL/be/be_attribute.cpp b/TAO/TAO_IDL/be/be_attribute.cpp index e13b6947ebd..e94a5e951af 100644 --- a/TAO/TAO_IDL/be/be_attribute.cpp +++ b/TAO/TAO_IDL/be/be_attribute.cpp @@ -27,6 +27,11 @@ ACE_RCSID (be, "$Id$") be_attribute::be_attribute (void) + : COMMON_Base (), + AST_Decl (), + AST_Field (), + AST_Attribute (), + be_decl () { be_operation_default_strategy *bods = 0; @@ -44,18 +49,20 @@ be_attribute::be_attribute (idl_bool ro, UTL_ScopedName *n, idl_bool local, idl_bool abstract) - : AST_Attribute (ro, + : COMMON_Base (local, + abstract), + AST_Decl (AST_Decl::NT_attr, + n), + AST_Field (AST_Decl::NT_attr, + ft, + n), + AST_Attribute (ro, ft, n, local, abstract), - AST_Field (AST_Decl::NT_attr, - ft, - n), - AST_Decl (AST_Decl::NT_attr, - n), - COMMON_Base (local, - abstract) + be_decl (AST_Decl::NT_attr, + n) { be_operation_default_strategy *bods = 0; diff --git a/TAO/TAO_IDL/be/be_component.cpp b/TAO/TAO_IDL/be/be_component.cpp index 8afe77aca4b..ae6433b9f2d 100644 --- a/TAO/TAO_IDL/be/be_component.cpp +++ b/TAO/TAO_IDL/be/be_component.cpp @@ -25,6 +25,15 @@ ACE_RCSID (be, "$Id$") be_component::be_component (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + UTL_Scope (), + AST_Interface (), + AST_Component (), + be_scope (), + be_type (), + be_interface () { this->size_type (AST_Type::VARIABLE); this->has_constructor (I_TRUE); @@ -36,19 +45,13 @@ be_component::be_component (UTL_ScopedName *n, long n_supports, AST_Interface **supports_flat, long n_supports_flat) - : be_interface (n, - supports, - n_supports, - supports_flat, - n_supports_flat, - I_FALSE, - I_FALSE), - AST_Component (n, - base_component, - supports, - n_supports, - supports_flat, - n_supports_flat), + : COMMON_Base (I_FALSE, + I_FALSE), + AST_Decl (AST_Decl::NT_component, + n), + AST_Type (AST_Decl::NT_component, + n), + UTL_Scope (AST_Decl::NT_component), AST_Interface (n, supports, n_supports, @@ -56,13 +59,22 @@ be_component::be_component (UTL_ScopedName *n, n_supports_flat, I_FALSE, I_FALSE), - AST_Type (AST_Decl::NT_component, - n), - AST_Decl (AST_Decl::NT_component, - n), - UTL_Scope (AST_Decl::NT_component), - COMMON_Base (I_FALSE, - I_FALSE) + AST_Component (n, + base_component, + supports, + n_supports, + supports_flat, + n_supports_flat), + be_scope (AST_Decl::NT_component), + be_type (AST_Decl::NT_component, + n), + be_interface (n, + supports, + n_supports, + supports_flat, + n_supports_flat, + I_FALSE, + I_FALSE) { this->size_type (AST_Type::VARIABLE); this->has_constructor (I_TRUE); diff --git a/TAO/TAO_IDL/be/be_component_fwd.cpp b/TAO/TAO_IDL/be/be_component_fwd.cpp index 4b0f4b289b0..199e2571119 100644 --- a/TAO/TAO_IDL/be/be_component_fwd.cpp +++ b/TAO/TAO_IDL/be/be_component_fwd.cpp @@ -25,20 +25,32 @@ ACE_RCSID (be, "$Id$") be_component_fwd::be_component_fwd (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_InterfaceFwd (), + AST_ComponentFwd (), + be_type (), + be_interface_fwd () { this->size_type (AST_Type::VARIABLE); } be_component_fwd::be_component_fwd (AST_Interface *dummy, UTL_ScopedName *n) - : be_interface_fwd (dummy, + : COMMON_Base (), + AST_Decl (AST_Decl::NT_component_fwd, + n), + AST_Type (AST_Decl::NT_component_fwd, + n), + AST_InterfaceFwd (dummy, n), AST_ComponentFwd (dummy, - n), - AST_InterfaceFwd (dummy, n), - AST_Decl (AST_Decl::NT_component_fwd, - n) + be_type (AST_Decl::NT_component_fwd, + n), + be_interface_fwd (dummy, + n) { this->size_type (AST_Type::VARIABLE); } diff --git a/TAO/TAO_IDL/be/be_constant.cpp b/TAO/TAO_IDL/be/be_constant.cpp index ef6b810c35e..8661b192a82 100644 --- a/TAO/TAO_IDL/be/be_constant.cpp +++ b/TAO/TAO_IDL/be/be_constant.cpp @@ -29,17 +29,24 @@ ACE_RCSID (be, "$Id$") be_constant::be_constant (void) + : COMMON_Base (), + AST_Decl (), + AST_Constant (), + be_decl () { } be_constant::be_constant (AST_Expression::ExprType et, AST_Expression *v, UTL_ScopedName *n) - : AST_Constant (et, + : COMMON_Base (), + AST_Decl (AST_Decl::NT_const, + n), + AST_Constant (et, v, n), - AST_Decl (AST_Decl::NT_const, - n) + be_decl (AST_Decl::NT_const, + n) { } diff --git a/TAO/TAO_IDL/be/be_decl.cpp b/TAO/TAO_IDL/be/be_decl.cpp index 702456a3547..8cb81746844 100644 --- a/TAO/TAO_IDL/be/be_decl.cpp +++ b/TAO/TAO_IDL/be/be_decl.cpp @@ -47,7 +47,9 @@ ACE_RCSID (be, // Default Constructor be_decl::be_decl (void) - : cli_hdr_gen_ (I_FALSE), + : COMMON_Base (), + AST_Decl (), + cli_hdr_gen_ (I_FALSE), cli_stub_gen_ (I_FALSE), cli_inline_gen_ (I_FALSE), srv_hdr_gen_ (I_FALSE), @@ -67,7 +69,8 @@ be_decl::be_decl (void) // Constructor be_decl::be_decl (AST_Decl::NodeType type, UTL_ScopedName *n) - : AST_Decl (type, + : COMMON_Base (), + AST_Decl (type, n), cli_hdr_gen_ (I_FALSE), cli_stub_gen_ (I_FALSE), diff --git a/TAO/TAO_IDL/be/be_enum.cpp b/TAO/TAO_IDL/be/be_enum.cpp index f4c4a1a17f1..955a7280657 100644 --- a/TAO/TAO_IDL/be/be_enum.cpp +++ b/TAO/TAO_IDL/be/be_enum.cpp @@ -27,20 +27,38 @@ ACE_RCSID (be, "$Id$") be_enum::be_enum (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_ConcreteType (), + UTL_Scope (), + AST_Enum (), + be_decl (), + be_scope (), + be_type () { } be_enum::be_enum (UTL_ScopedName *n, idl_bool local, idl_bool abstract) - : AST_Enum (n, - local, - abstract), + : COMMON_Base (local, + abstract), AST_Decl (AST_Decl::NT_enum, n), + AST_Type (AST_Decl::NT_enum, + n), + AST_ConcreteType (AST_Decl::NT_enum, + n), UTL_Scope (AST_Decl::NT_enum), - COMMON_Base (local, - abstract) + AST_Enum (n, + local, + abstract), + be_decl (AST_Decl::NT_enum, + n), + be_scope (AST_Decl::NT_enum), + be_type (AST_Decl::NT_enum, + n) { } diff --git a/TAO/TAO_IDL/be/be_enum_val.cpp b/TAO/TAO_IDL/be/be_enum_val.cpp index a0fe6574b54..32623c25452 100644 --- a/TAO/TAO_IDL/be/be_enum_val.cpp +++ b/TAO/TAO_IDL/be/be_enum_val.cpp @@ -27,17 +27,27 @@ ACE_RCSID (be, "$Id$") be_enum_val::be_enum_val (void) + : COMMON_Base (), + AST_Decl (), + AST_Constant (), + AST_EnumVal (), + be_decl () { } be_enum_val::be_enum_val (unsigned long v, UTL_ScopedName *n) - : AST_Constant (AST_Expression::EV_ulong, + : COMMON_Base (), + AST_Decl (AST_Decl::NT_enum_val, + n), + AST_Constant (AST_Expression::EV_ulong, AST_Decl::NT_enum_val, new AST_Expression (v), n), - AST_Decl (AST_Decl::NT_enum_val, - n) + AST_EnumVal (v, + n), + be_decl (AST_Decl::NT_enum_val, + n) { } diff --git a/TAO/TAO_IDL/be/be_eventtype.cpp b/TAO/TAO_IDL/be/be_eventtype.cpp index efca917cd6b..05d5ce15f08 100644 --- a/TAO/TAO_IDL/be/be_eventtype.cpp +++ b/TAO/TAO_IDL/be/be_eventtype.cpp @@ -26,6 +26,18 @@ ACE_RCSID (be, // Default constructor. be_eventtype::be_eventtype (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + UTL_Scope (), + be_scope (), + be_decl (), + be_type (), + be_interface (), + be_valuetype (), + AST_Interface (), + AST_ValueType (), + AST_EventType () { } @@ -40,8 +52,28 @@ be_eventtype::be_eventtype (UTL_ScopedName *n, long n_supports, AST_Interface *supports_concrete, idl_bool abstract, - idl_bool truncatable) - : be_valuetype (n, + idl_bool truncatable, + idl_bool custom) + : COMMON_Base (0, + abstract), + AST_Decl (AST_Decl::NT_eventtype, + n), + AST_Type (AST_Decl::NT_eventtype, + n), + UTL_Scope (AST_Decl::NT_eventtype), + be_scope (AST_Decl::NT_eventtype), + be_decl (AST_Decl::NT_eventtype, + n), + be_type (AST_Decl::NT_eventtype, + n), + be_interface (n, + inherits, + n_inherits, + inherits_flat, + n_inherits_flat, + 0, + abstract), + be_valuetype (n, inherits, n_inherits, inherits_concrete, @@ -51,14 +83,15 @@ be_eventtype::be_eventtype (UTL_ScopedName *n, n_supports, supports_concrete, abstract, - truncatable), - be_interface (n, - inherits, - n_inherits, - inherits_flat, - n_inherits_flat, - 0, - abstract), + truncatable, + custom), + AST_Interface (n, + inherits, + n_inherits, + inherits_flat, + n_inherits_flat, + 0, + abstract), AST_ValueType (n, inherits, n_inherits, @@ -69,19 +102,20 @@ be_eventtype::be_eventtype (UTL_ScopedName *n, n_supports, supports_concrete, abstract, - truncatable), - AST_Interface (n, + truncatable, + custom), + AST_EventType (n, inherits, n_inherits, + inherits_concrete, inherits_flat, n_inherits_flat, - 0, - abstract), - AST_Decl (AST_Decl::NT_eventtype, - n), - UTL_Scope (AST_Decl::NT_eventtype), - COMMON_Base (0, - abstract) + supports, + n_supports, + supports_concrete, + abstract, + truncatable, + custom) { } diff --git a/TAO/TAO_IDL/be/be_eventtype_fwd.cpp b/TAO/TAO_IDL/be/be_eventtype_fwd.cpp index a2fef99f504..9651098a7af 100644 --- a/TAO/TAO_IDL/be/be_eventtype_fwd.cpp +++ b/TAO/TAO_IDL/be/be_eventtype_fwd.cpp @@ -27,25 +27,35 @@ ACE_RCSID (be, "$Id$") be_eventtype_fwd::be_eventtype_fwd (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_InterfaceFwd (), + AST_ValueTypeFwd (), + be_interface_fwd (), + be_valuetype_fwd (), + AST_EventTypeFwd () { } be_eventtype_fwd::be_eventtype_fwd (AST_Interface *dummy, UTL_ScopedName *n) - : be_valuetype_fwd (dummy, - n), - be_interface_fwd (dummy, - n), - AST_EventTypeFwd (dummy, + : COMMON_Base (dummy->is_local (), + dummy->is_abstract ()), + AST_Decl (AST_Decl::NT_valuetype_fwd, + n), + AST_Type (AST_Decl::NT_valuetype_fwd, + n), + AST_InterfaceFwd (dummy, n), AST_ValueTypeFwd (dummy, n), - AST_InterfaceFwd (dummy, + be_interface_fwd (dummy, n), - AST_Decl (AST_Decl::NT_valuetype_fwd, - n), - COMMON_Base (dummy->is_local (), - dummy->is_abstract ()) + be_valuetype_fwd (dummy, + n), + AST_EventTypeFwd (dummy, + n) { } diff --git a/TAO/TAO_IDL/be/be_exception.cpp b/TAO/TAO_IDL/be/be_exception.cpp index ebd3592ea33..5febe51f74a 100644 --- a/TAO/TAO_IDL/be/be_exception.cpp +++ b/TAO/TAO_IDL/be/be_exception.cpp @@ -28,22 +28,41 @@ ACE_RCSID (be, "$Id$") be_exception::be_exception (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_ConcreteType (), + UTL_Scope (), + AST_Structure (), + be_scope (), + be_decl (), + be_type () { - this->size_type (AST_Type::VARIABLE); // always the case + // Always the case. + this->size_type (AST_Type::VARIABLE); } be_exception::be_exception (UTL_ScopedName *n, idl_bool local, idl_bool abstract) - : AST_Decl (AST_Decl::NT_except, + : COMMON_Base (local, + abstract), + AST_Decl (AST_Decl::NT_except, + n), + AST_Type (AST_Decl::NT_except, n), + AST_ConcreteType (AST_Decl::NT_except, + n), + UTL_Scope (AST_Decl::NT_except), AST_Structure (AST_Decl::NT_except, n, local, abstract), - UTL_Scope (AST_Decl::NT_except), - COMMON_Base (local, - abstract) + be_scope (AST_Decl::NT_except), + be_decl (AST_Decl::NT_except, + n), + be_type (AST_Decl::NT_except, + n) { // Always the case. this->size_type (AST_Type::VARIABLE); diff --git a/TAO/TAO_IDL/be/be_factory.cpp b/TAO/TAO_IDL/be/be_factory.cpp index d09510860f6..ff0ffc44a78 100644 --- a/TAO/TAO_IDL/be/be_factory.cpp +++ b/TAO/TAO_IDL/be/be_factory.cpp @@ -27,22 +27,28 @@ ACE_RCSID (be, "$Id$") be_factory::be_factory (void) + : COMMON_Base (), + AST_Decl (), + UTL_Scope (), + AST_Factory (), + be_scope (), + be_decl () { } be_factory::be_factory (UTL_ScopedName *n) - : - AST_Factory (n), - + : COMMON_Base (1, + 0), //@@ Always local, never abstract AST_Decl (AST_Decl::NT_factory, n), UTL_Scope (AST_Decl::NT_factory), - COMMON_Base (1, - 0) //@@ Always local, never abstract + AST_Factory (n), + be_scope (AST_Decl::NT_factory), + be_decl (AST_Decl::NT_factory, + n) { } - be_factory::~be_factory (void) { } diff --git a/TAO/TAO_IDL/be/be_field.cpp b/TAO/TAO_IDL/be/be_field.cpp index 76b8aece9f0..8e638ba6acc 100644 --- a/TAO/TAO_IDL/be/be_field.cpp +++ b/TAO/TAO_IDL/be/be_field.cpp @@ -29,19 +29,25 @@ ACE_RCSID (be, "$Id$") be_field::be_field (void) + : COMMON_Base (), + AST_Decl (), + AST_Field (), + be_decl () { } be_field::be_field (AST_Type *ft, UTL_ScopedName *n, Visibility vis) - : AST_Field (ft, - n, - vis), + : COMMON_Base (ft->is_local (), + ft->is_abstract ()), AST_Decl (AST_Decl::NT_field, n), - COMMON_Base (ft->is_local (), - ft->is_abstract ()) + AST_Field (ft, + n, + vis), + be_decl (AST_Decl::NT_field, + n) { } diff --git a/TAO/TAO_IDL/be/be_generator.cpp b/TAO/TAO_IDL/be/be_generator.cpp index bb673eb5f77..bfb830f6e57 100644 --- a/TAO/TAO_IDL/be/be_generator.cpp +++ b/TAO/TAO_IDL/be/be_generator.cpp @@ -262,7 +262,8 @@ be_generator::create_valuetype (UTL_ScopedName *n, long n_supports, AST_Interface *supports_concrete, idl_bool abstract, - idl_bool truncatable) + idl_bool truncatable, + idl_bool custom) { be_valuetype *retval = 0; ACE_NEW_RETURN (retval, @@ -276,7 +277,8 @@ be_generator::create_valuetype (UTL_ScopedName *n, n_supports, supports_concrete, abstract, - truncatable), + truncatable, + custom), 0); return retval; @@ -296,6 +298,7 @@ be_generator::create_valuetype_fwd (UTL_ScopedName *n, 0, 0, abstract, + 0, 0); be_valuetype_fwd *retval = 0; @@ -318,7 +321,8 @@ be_generator::create_eventtype (UTL_ScopedName *n, long n_supports, AST_Interface *supports_concrete, idl_bool abstract, - idl_bool truncatable) + idl_bool truncatable, + idl_bool custom) { be_eventtype *retval = 0; ACE_NEW_RETURN (retval, @@ -332,7 +336,8 @@ be_generator::create_eventtype (UTL_ScopedName *n, n_supports, supports_concrete, abstract, - truncatable), + truncatable, + custom), 0); return retval; @@ -352,6 +357,7 @@ be_generator::create_eventtype_fwd (UTL_ScopedName *n, 0, 0, abstract, + 0, 0); be_eventtype_fwd *retval = 0; diff --git a/TAO/TAO_IDL/be/be_home.cpp b/TAO/TAO_IDL/be/be_home.cpp index 977d0bab686..4a574d66c4c 100644 --- a/TAO/TAO_IDL/be/be_home.cpp +++ b/TAO/TAO_IDL/be/be_home.cpp @@ -25,6 +25,15 @@ ACE_RCSID (be, "$Id$") be_home::be_home (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + UTL_Scope (), + AST_Interface (), + AST_Home (), + be_scope (), + be_type (), + be_interface () { this->size_type (AST_Type::VARIABLE); } @@ -37,15 +46,20 @@ be_home::be_home (UTL_ScopedName *n, long n_supports, AST_Interface **supports_flat, long n_supports_flat) - : be_interface (n, - supports, - n_supports, - supports_flat, - n_supports_flat, - I_FALSE, - I_FALSE), - be_type (AST_Decl::NT_home, - n), + : COMMON_Base (I_FALSE, + I_FALSE), + AST_Decl (AST_Decl::NT_home, + n), + AST_Type (AST_Decl::NT_home, + n), + UTL_Scope (AST_Decl::NT_home), + AST_Interface (n, + supports, + n_supports, + supports_flat, + n_supports_flat, + I_FALSE, + I_FALSE), AST_Home (n, base_home, managed_component, @@ -54,20 +68,16 @@ be_home::be_home (UTL_ScopedName *n, n_supports, supports_flat, n_supports_flat), - AST_Interface (n, - supports, - n_supports, - supports_flat, - n_supports_flat, - I_FALSE, - I_FALSE), - AST_Type (AST_Decl::NT_home, - n), - AST_Decl (AST_Decl::NT_home, - n), - UTL_Scope (AST_Decl::NT_home), - COMMON_Base (I_FALSE, - I_FALSE) + be_scope (AST_Decl::NT_home), + be_type (AST_Decl::NT_home, + n), + be_interface (n, + supports, + n_supports, + supports_flat, + n_supports_flat, + I_FALSE, + I_FALSE) { this->size_type (AST_Type::VARIABLE); } diff --git a/TAO/TAO_IDL/be/be_interface.cpp b/TAO/TAO_IDL/be/be_interface.cpp index a6ac59e7bc4..af9208536aa 100644 --- a/TAO/TAO_IDL/be/be_interface.cpp +++ b/TAO/TAO_IDL/be/be_interface.cpp @@ -42,12 +42,19 @@ ACE_RCSID (be, // Default constructor. be_interface::be_interface (void) - : var_out_seq_decls_gen_ (0) - , skel_count_ (0) - , in_mult_inheritance_ (-1) - , strategy_ (0) - , original_interface_ (0) - , has_mixed_parentage_ (-1) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + UTL_Scope (), + AST_Interface (), + be_scope (), + be_type (), + var_out_seq_decls_gen_ (0), + skel_count_ (0), + in_mult_inheritance_ (-1), + strategy_ (0), + original_interface_ (0), + has_mixed_parentage_ (-1) { ACE_NEW (this->strategy_, @@ -62,9 +69,13 @@ be_interface::be_interface (UTL_ScopedName *n, long nih_flat, idl_bool local, idl_bool abstract) - : be_scope (AST_Decl::NT_interface), - be_type (AST_Decl::NT_interface, - n), + : COMMON_Base (local, + abstract), + AST_Decl (AST_Decl::NT_interface, + n), + AST_Type (AST_Decl::NT_interface, + n), + UTL_Scope (AST_Decl::NT_interface), AST_Interface (n, ih, nih, @@ -72,13 +83,9 @@ be_interface::be_interface (UTL_ScopedName *n, nih_flat, local, abstract), - AST_Type (AST_Decl::NT_interface, - n), - AST_Decl (AST_Decl::NT_interface, - n), - UTL_Scope (AST_Decl::NT_interface), - COMMON_Base (local, - abstract), + be_scope (AST_Decl::NT_interface), + be_type (AST_Decl::NT_interface, + n), var_out_seq_decls_gen_ (0), skel_count_ (0), in_mult_inheritance_ (-1), diff --git a/TAO/TAO_IDL/be/be_interface_fwd.cpp b/TAO/TAO_IDL/be/be_interface_fwd.cpp index 47e871fc249..d115a0fba5b 100644 --- a/TAO/TAO_IDL/be/be_interface_fwd.cpp +++ b/TAO/TAO_IDL/be/be_interface_fwd.cpp @@ -28,6 +28,12 @@ ACE_RCSID (be, "$Id$") be_interface_fwd::be_interface_fwd (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_InterfaceFwd (), + be_decl (), + be_type () { // Always the case. this->size_type (AST_Type::VARIABLE); @@ -35,12 +41,18 @@ be_interface_fwd::be_interface_fwd (void) be_interface_fwd::be_interface_fwd (AST_Interface *dummy, UTL_ScopedName *n) - : AST_InterfaceFwd (dummy, - n), + : COMMON_Base (dummy->is_local (), + dummy->is_abstract ()), AST_Decl (AST_Decl::NT_interface_fwd, n), - COMMON_Base (dummy->is_local (), - dummy->is_abstract ()) + AST_Type (AST_Decl::NT_interface_fwd, + n), + AST_InterfaceFwd (dummy, + n), + be_decl (AST_Decl::NT_interface_fwd, + n), + be_type (AST_Decl::NT_interface_fwd, + n) { // Always the case. this->size_type (AST_Type::VARIABLE); diff --git a/TAO/TAO_IDL/be/be_module.cpp b/TAO/TAO_IDL/be/be_module.cpp index a7980972eaf..e3a23c01475 100644 --- a/TAO/TAO_IDL/be/be_module.cpp +++ b/TAO/TAO_IDL/be/be_module.cpp @@ -27,14 +27,23 @@ ACE_RCSID (be, "$Id$") be_module::be_module (void) + : COMMON_Base (), + AST_Decl (), + UTL_Scope (), + be_scope (), + be_decl () { } be_module::be_module (UTL_ScopedName *n) - : AST_Module (n), + : COMMON_Base (), AST_Decl (AST_Decl::NT_module, n), - UTL_Scope (AST_Decl::NT_module) + UTL_Scope (AST_Decl::NT_module), + AST_Module (n), + be_scope (AST_Decl::NT_module), + be_decl (AST_Decl::NT_module, + n) { } diff --git a/TAO/TAO_IDL/be/be_native.cpp b/TAO/TAO_IDL/be/be_native.cpp index 8aa14ed2d39..f2e65a75e56 100644 --- a/TAO/TAO_IDL/be/be_native.cpp +++ b/TAO/TAO_IDL/be/be_native.cpp @@ -25,13 +25,26 @@ ACE_RCSID (be, be_native::be_native (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_Native (), + be_decl (), + be_type () { } be_native::be_native (UTL_ScopedName *n) - : AST_Native (n), + : COMMON_Base (), AST_Decl (AST_Decl::NT_native, - n) + n), + AST_Type (AST_Decl::NT_native, + n), + AST_Native (n), + be_decl (AST_Decl::NT_native, + n), + be_type (AST_Decl::NT_native, + n) { } diff --git a/TAO/TAO_IDL/be/be_operation.cpp b/TAO/TAO_IDL/be/be_operation.cpp index 100027e3577..1b1a2bfefb0 100644 --- a/TAO/TAO_IDL/be/be_operation.cpp +++ b/TAO/TAO_IDL/be/be_operation.cpp @@ -30,6 +30,12 @@ ACE_RCSID (be, "$Id$") be_operation::be_operation (void) + : COMMON_Base (), + AST_Decl (), + UTL_Scope (), + AST_Operation (), + be_scope (), + be_decl () { ACE_NEW (this->strategy_, be_operation_default_strategy (this)); @@ -40,16 +46,19 @@ be_operation::be_operation (AST_Type *rt, UTL_ScopedName *n, idl_bool local, idl_bool abstract) - : AST_Operation (rt, + : COMMON_Base (local, + abstract), + AST_Decl (AST_Decl::NT_op, + n), + UTL_Scope (AST_Decl::NT_op), + AST_Operation (rt, fl, n, local, abstract), - AST_Decl (AST_Decl::NT_op, - n), - UTL_Scope (AST_Decl::NT_op), - COMMON_Base (local, - abstract) + be_scope (AST_Decl::NT_op), + be_decl (AST_Decl::NT_op, + n) { ACE_NEW (this->strategy_, be_operation_default_strategy (this)); diff --git a/TAO/TAO_IDL/be/be_predefined_type.cpp b/TAO/TAO_IDL/be/be_predefined_type.cpp index 0e157a1b415..5da4db17078 100644 --- a/TAO/TAO_IDL/be/be_predefined_type.cpp +++ b/TAO/TAO_IDL/be/be_predefined_type.cpp @@ -30,16 +30,32 @@ ACE_RCSID (be, "$Id$") be_predefined_type::be_predefined_type (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_ConcreteType (), + AST_PredefinedType (), + be_decl (), + be_type () { } be_predefined_type::be_predefined_type (AST_PredefinedType::PredefinedType t, UTL_ScopedName *n) - : AST_PredefinedType (t, - n), + : COMMON_Base (), AST_Decl (AST_Decl::NT_pre_defined, n, - I_TRUE) + I_TRUE), + AST_Type (AST_Decl::NT_pre_defined, + n), + AST_ConcreteType (AST_Decl::NT_pre_defined, + n), + AST_PredefinedType (t, + n), + be_decl (AST_Decl::NT_pre_defined, + n), + be_type (AST_Decl::NT_pre_defined, + n) { // Computes the repoID. this->compute_repoID (); diff --git a/TAO/TAO_IDL/be/be_root.cpp b/TAO/TAO_IDL/be/be_root.cpp index 0e8b89b68fb..27ec7b82782 100644 --- a/TAO/TAO_IDL/be/be_root.cpp +++ b/TAO/TAO_IDL/be/be_root.cpp @@ -31,16 +31,26 @@ ACE_RCSID (be, // Default Constructor. be_root::be_root (void) + : COMMON_Base (), + AST_Decl (), + UTL_Scope (), + AST_Root (), + be_scope (), + be_decl () { } // Constructor used to build the root of the abstract syntax tree (AST). be_root::be_root (UTL_ScopedName *n) - : AST_Root (n), + : COMMON_Base (), AST_Decl (AST_Decl::NT_root, n), - UTL_Scope (AST_Decl::NT_root) - + UTL_Scope (AST_Decl::NT_root), + AST_Module (n), + AST_Root (n), + be_scope (AST_Decl::NT_root), + be_decl (AST_Decl::NT_root, + n) { } diff --git a/TAO/TAO_IDL/be/be_scope.cpp b/TAO/TAO_IDL/be/be_scope.cpp index 02b827c3d8c..dd202eeab25 100644 --- a/TAO/TAO_IDL/be/be_scope.cpp +++ b/TAO/TAO_IDL/be/be_scope.cpp @@ -22,7 +22,8 @@ ACE_RCSID (be, // Default Constructor. be_scope::be_scope (void) - : comma_ (0) + : UTL_Scope (), + comma_ (0) { } diff --git a/TAO/TAO_IDL/be/be_sequence.cpp b/TAO/TAO_IDL/be/be_sequence.cpp index 767df3bfc8a..565a2396fff 100644 --- a/TAO/TAO_IDL/be/be_sequence.cpp +++ b/TAO/TAO_IDL/be/be_sequence.cpp @@ -38,7 +38,16 @@ ACE_RCSID (be, be_sequence::be_sequence (void) - : mt_ (be_sequence::MNG_UNKNOWN), + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_ConcreteType (), + AST_Sequence (), + UTL_Scope (), + be_scope (), + be_decl (), + be_type (), + mt_ (be_sequence::MNG_UNKNOWN), field_node_ (0) { // Always the case. @@ -50,26 +59,26 @@ be_sequence::be_sequence (AST_Expression *v, UTL_ScopedName *n, idl_bool local, idl_bool abstract) - : be_scope (AST_Decl::NT_sequence), - be_type (AST_Decl::NT_sequence, - n), - be_decl (AST_Decl::NT_sequence, - n), - UTL_Scope (AST_Decl::NT_sequence), + : COMMON_Base (t->is_local () || local, + abstract), + AST_Decl (AST_Decl::NT_sequence, + n, + I_TRUE), + AST_Type (AST_Decl::NT_sequence, + n), + AST_ConcreteType (AST_Decl::NT_sequence, + n), AST_Sequence (v, t, n, t->is_local () || local, abstract), - AST_ConcreteType (AST_Decl::NT_sequence, - n), - AST_Type (AST_Decl::NT_sequence, - n), - AST_Decl (AST_Decl::NT_sequence, - n, - I_TRUE), - COMMON_Base (t->is_local () || local, - abstract), + UTL_Scope (AST_Decl::NT_sequence), + be_scope (AST_Decl::NT_sequence), + be_decl (AST_Decl::NT_sequence, + n), + be_type (AST_Decl::NT_sequence, + n), mt_ (be_sequence::MNG_UNKNOWN), field_node_ (0) { @@ -308,7 +317,7 @@ be_sequence::fe_add_sequence (AST_Sequence *t) return 0; } - this->add_to_local_types(t); + this->add_to_local_types (t); return t; } @@ -476,7 +485,7 @@ be_sequence::instance_name () int be_sequence::gen_base_class_name (TAO_OutStream *os, - AST_Decl *elem_scope) + AST_Decl *ctx_scope) { be_type *elem = be_type::narrow_from_decl (this->base_type ()); @@ -487,22 +496,22 @@ be_sequence::gen_base_class_name (TAO_OutStream *os, if (this->unbounded ()) { *os << "TAO_Unbounded_Object_Sequence<" << be_idt << be_idt_nl - << elem->nested_type_name (elem_scope) << "," << be_nl; - *os << elem->nested_type_name (elem_scope, "_var") << "," << be_nl - << this->smart_fwd_helper_name (elem_scope, elem) - << "_life," << be_nl - << this->smart_fwd_helper_name (elem_scope, elem) + << elem->nested_type_name (ctx_scope) << "," << be_nl; + *os << elem->nested_type_name (ctx_scope, "_var") << "," << be_nl + << this->smart_fwd_helper_name (ctx_scope, elem) + << "_life," << be_nl; + *os << this->smart_fwd_helper_name (ctx_scope, elem) << "_cast" << be_uidt_nl << ">" << be_uidt; } else { *os << "TAO_Bounded_Object_Sequence<" << be_idt << be_idt_nl - << elem->nested_type_name (elem_scope) << "," << be_nl; - *os << elem->nested_type_name (elem_scope, "_var") << "," << be_nl - << this->smart_fwd_helper_name (elem_scope, elem) + << elem->nested_type_name (ctx_scope) << "," << be_nl; + *os << elem->nested_type_name (ctx_scope, "_var") << "," << be_nl + << this->smart_fwd_helper_name (ctx_scope, elem) << "_life," << be_nl - << this->smart_fwd_helper_name (elem_scope, elem) + << this->smart_fwd_helper_name (ctx_scope, elem) << "_cast," << be_nl << this->max_size ()->ev ()->u.ulval << be_uidt_nl << ">" << be_uidt; @@ -513,18 +522,18 @@ be_sequence::gen_base_class_name (TAO_OutStream *os, if (this->unbounded ()) { *os << "TAO_Unbounded_Abstract_Sequence<" << be_idt << be_idt_nl - << elem->nested_type_name (elem_scope) << "," << be_nl; - *os << elem->nested_type_name (elem_scope, "_var") << "," << be_nl - << this->smart_fwd_helper_name (elem_scope, elem) + << elem->nested_type_name (ctx_scope) << "," << be_nl; + *os << elem->nested_type_name (ctx_scope, "_var") << "," << be_nl + << this->smart_fwd_helper_name (ctx_scope, elem) << "_life" << be_uidt_nl << ">" << be_uidt; } else { *os << "TAO_Bounded_Abstract_Sequence<" << be_idt << be_idt_nl - << elem->nested_type_name (elem_scope) << "," << be_nl; - *os << elem->nested_type_name (elem_scope, "_var") << "," << be_nl - << this->smart_fwd_helper_name (elem_scope, elem) + << elem->nested_type_name (ctx_scope) << "," << be_nl; + *os << elem->nested_type_name (ctx_scope, "_var") << "," << be_nl + << this->smart_fwd_helper_name (ctx_scope, elem) << "_life," << be_nl << this->max_size ()->ev ()->u.ulval << be_uidt_nl << ">" << be_uidt; @@ -535,14 +544,14 @@ be_sequence::gen_base_class_name (TAO_OutStream *os, if (this->unbounded ()) { *os << "TAO_Unbounded_Pseudo_Sequence<" << be_idt << be_idt_nl - << elem->nested_type_name (elem_scope) << "," << be_nl + << elem->nested_type_name (ctx_scope) << "," << be_nl << elem->name () << "_var" << be_uidt_nl << ">" << be_uidt; } else { *os << "TAO_Bounded_Pseudo_Sequence<" << be_idt << be_idt_nl - << elem->nested_type_name (elem_scope) << "," << be_nl + << elem->nested_type_name (ctx_scope) << "," << be_nl << elem->name () << "_var," << be_nl << this->max_size ()->ev ()->u.ulval << be_uidt_nl << ">" << be_uidt; @@ -553,18 +562,18 @@ be_sequence::gen_base_class_name (TAO_OutStream *os, if (this->unbounded ()) { *os << "TAO_Unbounded_Valuetype_Sequence<" << be_idt << be_idt_nl - << elem->nested_type_name (elem_scope) << "," << be_nl; - *os << elem->nested_type_name (elem_scope, "_var") << "," << be_nl - << this->smart_fwd_helper_name (elem_scope, elem) + << elem->nested_type_name (ctx_scope) << "," << be_nl; + *os << elem->nested_type_name (ctx_scope, "_var") << "," << be_nl + << this->smart_fwd_helper_name (ctx_scope, elem) << "_life" << be_uidt_nl << ">" << be_uidt; } else { *os << "TAO_Bounded_Valuetype_Sequence<" << be_idt << be_idt_nl - << elem->nested_type_name (elem_scope) << "," << be_nl; - *os << elem->nested_type_name (elem_scope, "_var") << "," << be_nl - << this->smart_fwd_helper_name (elem_scope, elem) + << elem->nested_type_name (ctx_scope) << "," << be_nl; + *os << elem->nested_type_name (ctx_scope, "_var") << "," << be_nl + << this->smart_fwd_helper_name (ctx_scope, elem) << "_life," << be_nl << this->max_size ()->ev ()->u.ulval << be_uidt_nl << ">" << be_uidt; @@ -603,8 +612,8 @@ be_sequence::gen_base_class_name (TAO_OutStream *os, { *os << "TAO_Unbounded_Array_Sequence<" << be_idt << be_idt_nl - << elem->nested_type_name (elem_scope) << "," << be_nl - << this->smart_fwd_helper_name (elem_scope, elem) + << elem->nested_type_name (ctx_scope) << "," << be_nl + << this->smart_fwd_helper_name (ctx_scope, elem) << "_life" << be_uidt_nl << ">" << be_uidt; } @@ -612,8 +621,8 @@ be_sequence::gen_base_class_name (TAO_OutStream *os, { *os << "TAO_Bounded_Array_Sequence<" << be_idt << be_idt_nl - << elem->nested_type_name (elem_scope) << "," << be_nl - << this->smart_fwd_helper_name (elem_scope, elem) + << elem->nested_type_name (ctx_scope) << "," << be_nl + << this->smart_fwd_helper_name (ctx_scope, elem) << "_life," << be_nl << this->max_size ()->ev ()->u.ulval << be_uidt_nl << ">" << be_uidt; @@ -624,13 +633,13 @@ be_sequence::gen_base_class_name (TAO_OutStream *os, if (this->unbounded ()) { *os << "TAO_Unbounded_Sequence<" << be_idt << be_idt_nl - << elem->nested_type_name (elem_scope) << be_uidt_nl + << elem->nested_type_name (ctx_scope) << be_uidt_nl << ">" << be_uidt; } else { *os << "TAO_Bounded_Sequence<" << be_idt << be_idt_nl - << elem->nested_type_name (elem_scope) << "," << be_nl + << elem->nested_type_name (ctx_scope) << "," << be_nl << this->max_size ()->ev ()->u.ulval << be_uidt_nl << ">" << be_uidt; } @@ -657,10 +666,10 @@ be_sequence::field_node (be_field *node) } const char * -be_sequence::smart_fwd_helper_name (AST_Decl *elem_scope, +be_sequence::smart_fwd_helper_name (AST_Decl *ctx_scope, be_type *elem) { - if (ScopeAsDecl (this->defined_in ()) == elem_scope) + if (ScopeAsDecl (elem->defined_in ()) == ctx_scope) { ACE_CString retval = "tao_"; retval += elem->local_name ()->get_string (); diff --git a/TAO/TAO_IDL/be/be_string.cpp b/TAO/TAO_IDL/be/be_string.cpp index 400fd1c7224..c8c4a5da40b 100644 --- a/TAO/TAO_IDL/be/be_string.cpp +++ b/TAO/TAO_IDL/be/be_string.cpp @@ -28,6 +28,12 @@ ACE_RCSID (be, "$Id$") be_string::be_string (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_String (), + be_decl (), + be_type () { // Always the case. this->size_type (AST_Type::VARIABLE); @@ -37,13 +43,20 @@ be_string::be_string (AST_Decl::NodeType nt, UTL_ScopedName *n, AST_Expression *v, long width) - : AST_String (nt, + : COMMON_Base (), + AST_Decl (nt, + n, + I_TRUE), + AST_Type (nt, + n), + AST_String (nt, n, v, width), - AST_Decl (nt, - n, - I_TRUE) + be_decl (nt, + n), + be_type (nt, + n) { } diff --git a/TAO/TAO_IDL/be/be_structure.cpp b/TAO/TAO_IDL/be/be_structure.cpp index 2704496dfc9..1c9bca77f0f 100644 --- a/TAO/TAO_IDL/be/be_structure.cpp +++ b/TAO/TAO_IDL/be/be_structure.cpp @@ -33,17 +33,38 @@ ACE_RCSID (be, "$Id$") be_structure::be_structure (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_ConcreteType (), + UTL_Scope (), + AST_Structure (), + be_scope (), + be_decl (), + be_type () { } be_structure::be_structure (UTL_ScopedName *n, idl_bool local, idl_bool abstract) - : AST_Decl (AST_Decl::NT_struct, + : COMMON_Base (local, + abstract), + AST_Decl (AST_Decl::NT_struct, n), + AST_Type (AST_Decl::NT_struct, + n), + AST_ConcreteType (AST_Decl::NT_struct, + n), UTL_Scope (AST_Decl::NT_struct), - COMMON_Base (local, - abstract) + AST_Structure (n, + local, + abstract), + be_scope (AST_Decl::NT_struct), + be_decl (AST_Decl::NT_struct, + n), + be_type (AST_Decl::NT_struct, + n) { } diff --git a/TAO/TAO_IDL/be/be_structure_fwd.cpp b/TAO/TAO_IDL/be/be_structure_fwd.cpp index 94e8a173343..63d59761ba2 100644 --- a/TAO/TAO_IDL/be/be_structure_fwd.cpp +++ b/TAO/TAO_IDL/be/be_structure_fwd.cpp @@ -25,19 +25,28 @@ ACE_RCSID (be, "$Id$") be_structure_fwd::be_structure_fwd (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_StructureFwd (), + be_decl (), + be_type () { } be_structure_fwd::be_structure_fwd (AST_Structure *dummy, UTL_ScopedName *n) - : be_type (AST_Decl::NT_struct_fwd, - n), - AST_StructureFwd (dummy, - n), + : COMMON_Base (), + AST_Decl (AST_Decl::NT_struct_fwd, + n), AST_Type (AST_Decl::NT_struct_fwd, n), - AST_Decl (AST_Decl::NT_struct_fwd, - n) + AST_StructureFwd (dummy, + n), + be_decl (AST_Decl::NT_struct_fwd, + n), + be_type (AST_Decl::NT_struct_fwd, + n) { } diff --git a/TAO/TAO_IDL/be/be_type.cpp b/TAO/TAO_IDL/be/be_type.cpp index 46bf479040b..a5fe06ec7f0 100644 --- a/TAO/TAO_IDL/be/be_type.cpp +++ b/TAO/TAO_IDL/be/be_type.cpp @@ -33,7 +33,11 @@ ACE_RCSID (be, "$Id$") be_type::be_type (void) - : tc_name_ (0), + : COMMON_Base (), + AST_Decl (), + AST_Type (), + be_decl (), + tc_name_ (0), common_varout_gen_ (I_FALSE), seen_in_sequence_ (I_FALSE) { @@ -41,12 +45,13 @@ be_type::be_type (void) be_type::be_type (AST_Decl::NodeType nt, UTL_ScopedName *n) - : be_decl (nt, - n), - AST_Type (nt, - n), + : COMMON_Base (), AST_Decl (nt, n), + AST_Type (nt, + n), + be_decl (nt, + n), tc_name_ (0), common_varout_gen_ (I_FALSE), seen_in_sequence_ (I_FALSE) diff --git a/TAO/TAO_IDL/be/be_typedef.cpp b/TAO/TAO_IDL/be/be_typedef.cpp index 3a9a71562bf..36377d19e15 100644 --- a/TAO/TAO_IDL/be/be_typedef.cpp +++ b/TAO/TAO_IDL/be/be_typedef.cpp @@ -28,6 +28,12 @@ ACE_RCSID (be, "$Id$") be_typedef::be_typedef (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_Typedef (), + be_decl (), + be_type () { } @@ -35,20 +41,20 @@ be_typedef::be_typedef (AST_Type *bt, UTL_ScopedName *n, idl_bool local, idl_bool abstract) - : be_type (AST_Decl::NT_typedef, - n), - be_decl (AST_Decl::NT_typedef, - n), + : COMMON_Base (bt->is_local () || local, + abstract), + AST_Decl (AST_Decl::NT_typedef, + n), + AST_Type (AST_Decl::NT_typedef, + n), AST_Typedef (bt, n, bt->is_local () || local, abstract), - AST_Type (AST_Decl::NT_typedef, - n), - AST_Decl (AST_Decl::NT_typedef, - n), - COMMON_Base (bt->is_local () || local, - abstract) + be_decl (AST_Decl::NT_typedef, + n), + be_type (AST_Decl::NT_typedef, + n) { } diff --git a/TAO/TAO_IDL/be/be_union.cpp b/TAO/TAO_IDL/be/be_union.cpp index 13ec5d12652..64dd0864f90 100644 --- a/TAO/TAO_IDL/be/be_union.cpp +++ b/TAO/TAO_IDL/be/be_union.cpp @@ -34,6 +34,16 @@ ACE_RCSID (be, be_union::be_union (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_ConcreteType (), + UTL_Scope (), + AST_Structure (), + AST_Union (), + be_scope (), + be_decl (), + be_type () { // Always the case. this->has_constructor (I_TRUE); @@ -43,19 +53,28 @@ be_union::be_union (AST_ConcreteType *dt, UTL_ScopedName *n, idl_bool local, idl_bool abstract) - : AST_Union (dt, - n, - local, - abstract), + : COMMON_Base (local, + abstract), + AST_Decl (AST_Decl::NT_union, + n), + AST_Type (AST_Decl::NT_union, + n), + AST_ConcreteType (AST_Decl::NT_union, + n), + UTL_Scope (AST_Decl::NT_union), AST_Structure (AST_Decl::NT_union, n, local, abstract), - AST_Decl (AST_Decl::NT_union, - n), - UTL_Scope (AST_Decl::NT_union), - COMMON_Base (local, - abstract) + AST_Union (dt, + n, + local, + abstract), + be_scope (AST_Decl::NT_union), + be_decl (AST_Decl::NT_union, + n), + be_type (AST_Decl::NT_union, + n) { // Always the case. this->has_constructor (I_TRUE); diff --git a/TAO/TAO_IDL/be/be_union_branch.cpp b/TAO/TAO_IDL/be/be_union_branch.cpp index 9f14a203006..006ce84d787 100644 --- a/TAO/TAO_IDL/be/be_union_branch.cpp +++ b/TAO/TAO_IDL/be/be_union_branch.cpp @@ -33,22 +33,29 @@ ACE_RCSID (be, "$Id$") be_union_branch::be_union_branch (void) + : COMMON_Base (), + AST_Decl (), + AST_Field (), + AST_UnionBranch (), + be_decl () { } be_union_branch::be_union_branch (UTL_LabelList *ll, AST_Type *ft, UTL_ScopedName *n) - : AST_UnionBranch (ll, - ft, - n), + : COMMON_Base (ft->is_local (), + ft->is_abstract ()), + AST_Decl (AST_Decl::NT_union_branch, + n), AST_Field (AST_Decl::NT_union_branch, ft, n), - AST_Decl (AST_Decl::NT_union_branch, - n), - COMMON_Base (ft->is_local (), - ft->is_abstract ()) + AST_UnionBranch (ll, + ft, + n), + be_decl (AST_Decl::NT_union_branch, + n) { } diff --git a/TAO/TAO_IDL/be/be_union_fwd.cpp b/TAO/TAO_IDL/be/be_union_fwd.cpp index 5ec01dd1592..8fdcf87b020 100644 --- a/TAO/TAO_IDL/be/be_union_fwd.cpp +++ b/TAO/TAO_IDL/be/be_union_fwd.cpp @@ -26,21 +26,34 @@ ACE_RCSID (be, "$Id$") be_union_fwd::be_union_fwd (void) + : COMMON_Base (), + AST_Decl (), + AST_StructureFwd (), + AST_Type (), + AST_UnionFwd (), + be_decl (), + be_type (), + be_structure_fwd () { } be_union_fwd::be_union_fwd (AST_Union *dummy, UTL_ScopedName *n) - : be_structure_fwd (dummy, - n), - AST_UnionFwd (dummy, - n), + : COMMON_Base (), + AST_Decl (AST_Decl::NT_union_fwd, + n), AST_StructureFwd (dummy, n), AST_Type (AST_Decl::NT_union_fwd, n), - AST_Decl (AST_Decl::NT_union_fwd, - n) + AST_UnionFwd (dummy, + n), + be_decl (AST_Decl::NT_union_fwd, + n), + be_type (AST_Decl::NT_union_fwd, + n), + be_structure_fwd (dummy, + n) { } diff --git a/TAO/TAO_IDL/be/be_union_label.cpp b/TAO/TAO_IDL/be/be_union_label.cpp index a6889166db1..7c476be7745 100644 --- a/TAO/TAO_IDL/be/be_union_label.cpp +++ b/TAO/TAO_IDL/be/be_union_label.cpp @@ -10,6 +10,7 @@ ACE_RCSID (be, "$Id$") be_union_label::be_union_label (void) + : AST_UnionLabel () { } diff --git a/TAO/TAO_IDL/be/be_valuetype.cpp b/TAO/TAO_IDL/be/be_valuetype.cpp index 21d78798182..384239e2b98 100644 --- a/TAO/TAO_IDL/be/be_valuetype.cpp +++ b/TAO/TAO_IDL/be/be_valuetype.cpp @@ -35,7 +35,17 @@ ACE_RCSID (be, // Default constructor. be_valuetype::be_valuetype (void) - : full_obv_skel_name_ (0) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + UTL_Scope (), + AST_Interface (), + be_scope (), + be_decl (), + be_type (), + be_interface (), + AST_ValueType (), + full_obv_skel_name_ (0) { // Always the case. this->size_type (AST_Type::VARIABLE); @@ -62,16 +72,34 @@ be_valuetype::be_valuetype (UTL_ScopedName *n, long n_supports, AST_Interface *supports_concrete, idl_bool abstract, - idl_bool truncatable) - : be_interface (n, + idl_bool truncatable, + idl_bool custom) + : COMMON_Base (0, + abstract), + AST_Decl (AST_Decl::NT_valuetype, + n), + AST_Type (AST_Decl::NT_valuetype, + n), + UTL_Scope (AST_Decl::NT_valuetype), + AST_Interface (n, + inherits, + n_inherits, + inherits_flat, + n_inherits_flat, + 0, + abstract), + be_scope (AST_Decl::NT_valuetype), + be_decl (AST_Decl::NT_valuetype, + n), + be_type (AST_Decl::NT_valuetype, + n), + be_interface (n, inherits, n_inherits, inherits_flat, n_inherits_flat, 0, abstract), - be_type (AST_Decl::NT_valuetype, - n), AST_ValueType (n, inherits, n_inherits, @@ -82,19 +110,8 @@ be_valuetype::be_valuetype (UTL_ScopedName *n, n_supports, supports_concrete, abstract, - truncatable), - AST_Interface (n, - inherits, - n_inherits, - inherits_flat, - n_inherits_flat, - 0, - abstract), - AST_Decl (AST_Decl::NT_valuetype, - n), - UTL_Scope (AST_Decl::NT_valuetype), - COMMON_Base (0, - abstract), + truncatable, + custom), full_obv_skel_name_ (0), supports_abstract_ (0), var_out_seq_decls_gen_ (0) diff --git a/TAO/TAO_IDL/be/be_valuetype_fwd.cpp b/TAO/TAO_IDL/be/be_valuetype_fwd.cpp index e936894c802..2146482f54c 100644 --- a/TAO/TAO_IDL/be/be_valuetype_fwd.cpp +++ b/TAO/TAO_IDL/be/be_valuetype_fwd.cpp @@ -30,21 +30,35 @@ ACE_RCSID (be, "$Id$") be_valuetype_fwd::be_valuetype_fwd (void) + : COMMON_Base (), + AST_Decl (), + AST_Type (), + AST_InterfaceFwd (), + be_decl (), + be_type (), + be_interface_fwd (), + AST_ValueTypeFwd () { } be_valuetype_fwd::be_valuetype_fwd (AST_Interface *dummy, UTL_ScopedName *n) - : be_interface_fwd (dummy, - n), - AST_ValueTypeFwd (dummy, - n), - AST_InterfaceFwd (dummy, - n), + : COMMON_Base (dummy->is_local (), + dummy->is_abstract ()), AST_Decl (AST_Decl::NT_valuetype_fwd, n), - COMMON_Base (dummy->is_local (), - dummy->is_abstract ()) + AST_Type (AST_Decl::NT_valuetype_fwd, + n), + AST_InterfaceFwd (dummy, + n), + be_decl (AST_Decl::NT_valuetype_fwd, + n), + be_type (AST_Decl::NT_valuetype_fwd, + n), + be_interface_fwd (dummy, + n), + AST_ValueTypeFwd (dummy, + n) { } diff --git a/TAO/TAO_IDL/be/be_visitor_amh_pre_proc.cpp b/TAO/TAO_IDL/be/be_visitor_amh_pre_proc.cpp index 24ab9029bd8..af105baf5e9 100644 --- a/TAO/TAO_IDL/be/be_visitor_amh_pre_proc.cpp +++ b/TAO/TAO_IDL/be/be_visitor_amh_pre_proc.cpp @@ -635,6 +635,7 @@ be_visitor_amh_pre_proc::create_exception_holder (be_interface *node) 0, 0, 0, + 0, 0), 0); diff --git a/TAO/TAO_IDL/be/be_visitor_ami_pre_proc.cpp b/TAO/TAO_IDL/be/be_visitor_ami_pre_proc.cpp index 3f68429afd7..6d5e500ced9 100644 --- a/TAO/TAO_IDL/be/be_visitor_ami_pre_proc.cpp +++ b/TAO/TAO_IDL/be/be_visitor_ami_pre_proc.cpp @@ -348,6 +348,7 @@ be_visitor_ami_pre_proc::create_exception_holder (be_interface *node) 0, 0, 0, + 0, 0), 0); @@ -403,6 +404,7 @@ be_visitor_ami_pre_proc::create_exception_holder (be_interface *node) 0, 0, 0, + 0, 0), 0); diff --git a/TAO/TAO_IDL/be/be_visitor_constant.cpp b/TAO/TAO_IDL/be/be_visitor_constant.cpp index 9144be5d367..31fe34ea8fc 100644 --- a/TAO/TAO_IDL/be/be_visitor_constant.cpp +++ b/TAO/TAO_IDL/be/be_visitor_constant.cpp @@ -22,6 +22,7 @@ #include "be_module.h" #include "be_helper.h" #include "be_extern.h" +#include "be_typedef.h" #include "utl_identifier.h" #include "be_visitor_constant.h" diff --git a/TAO/TAO_IDL/be/be_visitor_constant/constant_ch.cpp b/TAO/TAO_IDL/be/be_visitor_constant/constant_ch.cpp index a987353d696..8f3ceb1614b 100644 --- a/TAO/TAO_IDL/be/be_visitor_constant/constant_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_constant/constant_ch.cpp @@ -55,11 +55,14 @@ be_visitor_constant_ch::visit_constant (be_constant *node) // to us here itself, else it will be in the *.cpp file. AST_Decl::NodeType nt = AST_Decl::NT_pre_defined; - AST_Decl *td = node->constant_value ()->get_tdef (); + AST_Decl *tdef = node->constant_value ()->get_tdef (); + AST_Decl::NodeType bnt = AST_Decl::NT_pre_defined; - if (td != 0) + if (tdef != 0) { - nt = td->node_type (); + nt = tdef->node_type (); + be_typedef *td = be_typedef:: narrow_from_decl (tdef); + bnt = td->base_node_type (); } *os << be_nl << be_nl; @@ -75,7 +78,7 @@ be_visitor_constant_ch::visit_constant (be_constant *node) } else if (nt == AST_Decl::NT_typedef) { - *os << td->name (); + *os << tdef->name (); } else { @@ -96,7 +99,14 @@ be_visitor_constant_ch::visit_constant (be_constant *node) } else if (nt == AST_Decl::NT_typedef) { - *os << td->name (); + if (bnt == AST_Decl::NT_string || bnt == AST_Decl::NT_wstring) + { + *os << node->exprtype_to_string (); + } + else + { + *os << tdef->name (); + } } else { diff --git a/TAO/TAO_IDL/be/be_visitor_valuetype.cpp b/TAO/TAO_IDL/be/be_visitor_valuetype.cpp index d2050d95194..9a2e0192ee6 100644 --- a/TAO/TAO_IDL/be/be_visitor_valuetype.cpp +++ b/TAO/TAO_IDL/be/be_visitor_valuetype.cpp @@ -43,6 +43,7 @@ #include "be_helper.h" #include "be_extern.h" #include "utl_identifier.h" +#include "utl_exceptlist.h" #include "be_visitor_valuetype.h" #include "be_visitor_argument.h" diff --git a/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_init_arglist_ch.cpp b/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_init_arglist_ch.cpp index 3489d7d2b59..ae3cc1ca00a 100644 --- a/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_init_arglist_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_init_arglist_ch.cpp @@ -55,7 +55,20 @@ be_visitor_valuetype_init_arglist_ch::visit_factory (be_factory *node) } os << be_uidt_nl - << ")" << be_uidt; + << ")"; + + // Now generate the throw specs. + if (this->gen_throw_spec (node) == -1) + { + ACE_ERROR_RETURN (( + LM_ERROR, + ACE_TEXT ("(%N:%l) be_visitor_valuetype_init_arglist_ch") + ACE_TEXT ("::visit_factory - ") + ACE_TEXT ("Failed to generate throw spec\n") + ), + -1 + ); + } return 0; } @@ -94,3 +107,53 @@ be_visitor_valuetype_init_arglist_ch::post_process (be_decl *bd) return 0; } + +int +be_visitor_valuetype_init_arglist_ch::gen_throw_spec (be_factory *node) +{ + TAO_OutStream *os = this->ctx_->stream (); + + const char *throw_spec_open = "throw ("; + const char *throw_spec_close = ")"; + + if (!be_global->use_raw_throw ()) + { + throw_spec_open = "ACE_THROW_SPEC (("; + throw_spec_close = "))"; + } + + *os << be_nl << throw_spec_open; + *os << be_idt_nl << "CORBA::SystemException"; + + if (node->exceptions ()) + { + // Initialize an iterator to iterate thru the exception list. + for (UTL_ExceptlistActiveIterator ei (node->exceptions ()); + !ei.is_done (); + ei.next ()) + { + be_exception *excp = + be_exception::narrow_from_decl (ei.item ()); + + if (excp == 0) + { + ACE_ERROR_RETURN ((LM_ERROR, + "(%N:%l) be_visitor_operation" + "gen_throw_spec - " + "bad exception node\n"), + -1); + + } + + *os << "," << be_nl; + *os << excp->name (); + AST_Decl *d = ScopeAsDecl (excp->defined_in ()); + *os << d->repoID (); + } + } + + *os << be_uidt_nl << throw_spec_close << be_uidt; + + return 0; +} + diff --git a/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_init_ch.cpp b/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_init_ch.cpp index 629c064b3ef..66ae0b639a7 100644 --- a/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_init_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_init_ch.cpp @@ -86,8 +86,7 @@ be_visitor_valuetype_init_ch::visit_valuetype (be_valuetype *node) } // Virtual destructor. - os << "virtual ~" << node->local_name () << "_init (void);" - << be_nl << be_nl; + os << "virtual ~" << node->local_name () << "_init (void);"; if (this->visit_valuetype_scope (node) == -1) @@ -102,7 +101,7 @@ be_visitor_valuetype_init_ch::visit_valuetype (be_valuetype *node) // Generate _downcast method. os << be_nl << be_nl << "static " << node->local_name () << "_init* " - << "_downcast (CORBA::ValueFactoryBase* );"; + << "_downcast (CORBA::ValueFactoryBase *);"; if (factory_style == FS_CONCRETE_FACTORY) { @@ -155,7 +154,8 @@ be_visitor_valuetype_init_ch::visit_factory (be_factory *node) // STEP I: Generate preambule. - os << "virtual " << vt->local_name () << "* "; + os << be_nl << be_nl + << "virtual " << vt->local_name () << "* "; // STEP 2: Generate the operation name. os << node->local_name (); @@ -175,7 +175,7 @@ be_visitor_valuetype_init_ch::visit_factory (be_factory *node) } // Make pure virtual. - os << " = 0;" << be_nl; + os << " = 0;"; return 0; } diff --git a/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_ss.cpp b/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_ss.cpp index 3393c008f86..77916cf0727 100644 --- a/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_ss.cpp +++ b/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_ss.cpp @@ -161,19 +161,7 @@ be_visitor_valuetype_ss::visit_valuetype (be_valuetype *node) << "(void) safe_stub.release ();" << be_nl << "return "; - if (concrete->is_nested ()) - { - UTL_Scope *parent_scope = concrete->defined_in (); - AST_Decl *parent_decl = ScopeAsDecl (parent_scope); - - *os << "ACE_NESTED_CLASS (" - << parent_decl->name () << ", " - << concrete->local_name (); - } - else - { - *os << concrete->name (); - } + *os << concrete->name (); *os << "::_unchecked_narrow (obj.in ());" << be_uidt_nl |