diff options
author | nanbor <nanbor@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1999-07-18 19:36:49 +0000 |
---|---|---|
committer | nanbor <nanbor@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1999-07-18 19:36:49 +0000 |
commit | 688bfa26f28ece4682eef7225ae2bc80384087d5 (patch) | |
tree | 84cc2788de5a0204a9fea6b63cc6c68b9d0b8a21 | |
parent | 1d88764ba419bf1c554aab8a95f034c4b6981770 (diff) | |
download | ATCD-688bfa26f28ece4682eef7225ae2bc80384087d5.tar.gz |
ChangeLogTag:Sun Jul 18 14:21:52 1999 Nanbor Wang <nanbor@cs.wustl.edu>
48 files changed, 360 insertions, 241 deletions
diff --git a/TAO/TAO_IDL/be/be_args.cpp b/TAO/TAO_IDL/be/be_args.cpp index 67bcd83d2b9..fd4091222af 100644 --- a/TAO/TAO_IDL/be/be_args.cpp +++ b/TAO/TAO_IDL/be/be_args.cpp @@ -82,6 +82,10 @@ BE_prep_arg(char *s, idl_bool) { const char arg_macro[]="export_macro="; const char arg_include[]="export_include="; + const char skel_arg_macro[]="skel_export_macro="; + const char skel_arg_include[]="skel_export_include="; + const char stub_arg_macro[]="stub_export_macro="; + const char stub_arg_include[]="stub_export_include="; const char arg_pch_include[]="pch_include="; #ifdef IDL_HAS_VALUETYPE const char obv_opt_accessor[]="obv_opt_accessor"; @@ -95,12 +99,33 @@ BE_prep_arg(char *s, idl_bool) if (ACE_OS::strstr (arg, arg_macro) == arg) { char* val = arg + sizeof (arg_macro) - 1; - idl_global->export_macro (val); + idl_global->skel_export_macro (val); + idl_global->stub_export_macro (val); } else if (ACE_OS::strstr (arg, arg_include) == arg) { char* val = arg + sizeof (arg_include) - 1; - idl_global->export_include (val); + idl_global->stub_export_include (val); + } + else if (ACE_OS::strstr (arg, skel_arg_macro) == arg) + { + char* val = arg + sizeof (skel_arg_macro) - 1; + idl_global->skel_export_macro (val); + } + else if (ACE_OS::strstr (arg, skel_arg_include) == arg) + { + char* val = arg + sizeof (skel_arg_include) - 1; + idl_global->skel_export_include (val); + } + else if (ACE_OS::strstr (arg, stub_arg_macro) == arg) + { + char* val = arg + sizeof (stub_arg_macro) - 1; + idl_global->stub_export_macro (val); + } + else if (ACE_OS::strstr (arg, stub_arg_include) == arg) + { + char* val = arg + sizeof (stub_arg_include) - 1; + idl_global->stub_export_include (val); } else if (ACE_OS::strstr (arg, arg_pch_include) == arg) { diff --git a/TAO/TAO_IDL/be/be_codegen.cpp b/TAO/TAO_IDL/be/be_codegen.cpp index 0d943c59d16..8b3c5b01397 100644 --- a/TAO/TAO_IDL/be/be_codegen.cpp +++ b/TAO/TAO_IDL/be/be_codegen.cpp @@ -186,26 +186,26 @@ TAO_CodeGen::start_client_header (const char *fname) // Other include files. - if (idl_global->export_include () != 0) + if (idl_global->stub_export_include () != 0) { *this->client_header_ << "#include \"" - << idl_global->export_include () + << idl_global->stub_export_include () << "\"\n"; } - // Include the Messaging files if AMI is enabled. + // Include the Messaging files if AMI is enabled. if (idl_global->ami_call_back () == I_TRUE) { // Include Messaging skeleton file. *this->client_header_ << "#include "; - + if (idl_global->changing_standard_include_files () == 1) *this->client_header_ << "\""; else *this->client_header_ << "<"; - + *this->client_header_ << "tao/MessagingS.h"; - + if (idl_global->changing_standard_include_files () == 1) *this->client_header_ << "\"\n"; else @@ -213,14 +213,14 @@ TAO_CodeGen::start_client_header (const char *fname) // Including Asynch Invocation file. *this->client_header_ << "#include "; - + if (idl_global->changing_standard_include_files () == 1) *this->client_header_ << "\""; else *this->client_header_ << "<"; - + *this->client_header_ << "tao/Asynch_Invocation.h"; - + if (idl_global->changing_standard_include_files () == 1) *this->client_header_ << "\"\n"; else @@ -270,7 +270,7 @@ TAO_CodeGen::start_client_header (const char *fname) *this->client_header_ << "#undef TAO_EXPORT_MACRO\n"; *this->client_header_ << "#endif\n"; *this->client_header_ << "#define TAO_EXPORT_MACRO " - << idl_global->export_macro () + << idl_global->stub_export_macro () << be_nl; // Generate export macro for nested classes @@ -280,7 +280,7 @@ TAO_CodeGen::start_client_header (const char *fname) << "# undef TAO_EXPORT_NESTED_MACRO\n" << "# endif /* defined (TAO_EXPORT_NESTED_MACRO) */\n" << "# define TAO_EXPORT_NESTED_MACRO " - << idl_global->export_macro () + << idl_global->stub_export_macro () << be_nl << "#endif /* TAO_EXPORT_NESTED_CLASSES */\n"; @@ -462,6 +462,13 @@ TAO_CodeGen::start_server_header (const char *fname) << "#pragma warning(disable:4250)\n" << "#endif /* _MSC_VER */\n\n"; + if (idl_global->skel_export_include () != 0) + { + *this->server_header_ << "#include \"" + << idl_global->skel_export_include () + << "\"\n"; + } + return 0; } } diff --git a/TAO/TAO_IDL/be/be_interface.cpp b/TAO/TAO_IDL/be/be_interface.cpp index 3636414d0cd..a3f8a4806ad 100644 --- a/TAO/TAO_IDL/be/be_interface.cpp +++ b/TAO/TAO_IDL/be/be_interface.cpp @@ -548,7 +548,7 @@ be_interface::gen_var_defn (char* interface_name) // for over here. ch->indent (); // start with whatever was our current indent level - *ch << "class " << idl_global->export_macro () + *ch << "class " << idl_global->stub_export_macro () << " " << namebuf << nl; *ch << "{" << nl; *ch << "public:\n"; @@ -830,7 +830,7 @@ be_interface::gen_out_defn (char *interface_name) // generate the out definition (always in the client header) ch->indent (); // start with whatever was our current indent level - *ch << "class " << idl_global->export_macro () + *ch << "class " << idl_global->stub_export_macro () << " " << namebuf << nl; *ch << "{" << nl; *ch << "public:\n"; diff --git a/TAO/TAO_IDL/be/be_interface_fwd.cpp b/TAO/TAO_IDL/be/be_interface_fwd.cpp index 3d407fc41bd..94d1d430f60 100644 --- a/TAO/TAO_IDL/be/be_interface_fwd.cpp +++ b/TAO/TAO_IDL/be/be_interface_fwd.cpp @@ -67,7 +67,7 @@ be_interface_fwd::gen_var_defn (char *) // for over here. ch->indent (); // start with whatever was our current indent level - *ch << "class " << idl_global->export_macro () + *ch << "class " << idl_global->stub_export_macro () << " " << namebuf << nl; *ch << "{" << nl; *ch << "public:\n"; @@ -328,7 +328,7 @@ be_interface_fwd::gen_out_defn (char *) // generate the out definition (always in the client header) ch->indent (); // start with whatever was our current indent level - *ch << "class " << idl_global->export_macro () + *ch << "class " << idl_global->stub_export_macro () << " " << namebuf << nl; *ch << "{" << nl; *ch << "public:\n"; diff --git a/TAO/TAO_IDL/be/be_structure.cpp b/TAO/TAO_IDL/be/be_structure.cpp index a926adf8fcd..769ad911759 100644 --- a/TAO/TAO_IDL/be/be_structure.cpp +++ b/TAO/TAO_IDL/be/be_structure.cpp @@ -95,7 +95,7 @@ be_structure::gen_var_defn (char *) // for over here. ch->indent (); // start with whatever was our current indent level - *ch << "class " << idl_global->export_macro () + *ch << "class " << idl_global->stub_export_macro () << " " << namebuf << nl; *ch << "{" << nl; *ch << "public:\n"; @@ -403,7 +403,7 @@ be_structure::gen_out_defn (char *) // generate the out definition (always in the client header) ch->indent (); // start with whatever was our current indent level - *ch << "class " << idl_global->export_macro () + *ch << "class " << idl_global->stub_export_macro () << " " << namebuf << nl; *ch << "{" << nl; *ch << "public:\n"; diff --git a/TAO/TAO_IDL/be/be_union.cpp b/TAO/TAO_IDL/be/be_union.cpp index d4464dfbe4f..551105f3164 100644 --- a/TAO/TAO_IDL/be/be_union.cpp +++ b/TAO/TAO_IDL/be/be_union.cpp @@ -100,7 +100,7 @@ be_union::compute_default_index (void) ++j) { // check if we are printing the default case - if (bub->label (j)->label_kind () + if (bub->label (j)->label_kind () == AST_UnionLabel::UL_default) this->default_index_ = i; // zero based indexing i++; @@ -154,7 +154,7 @@ be_union::gen_var_defn (char *) // for over here. ch->indent (); // start with whatever was our current indent level - *ch << "class " << idl_global->export_macro () + *ch << "class " << idl_global->stub_export_macro () << " " << namebuf << nl; *ch << "{" << nl; *ch << "public:\n"; @@ -462,7 +462,7 @@ be_union::gen_out_defn (char *) // generate the out definition (always in the client header) ch->indent (); // start with whatever was our current indent level - *ch << "class " << idl_global->export_macro () + *ch << "class " << idl_global->stub_export_macro () << " " << namebuf << nl; *ch << "{" << nl; *ch << "public:\n"; @@ -786,7 +786,7 @@ be_union::compute_default_value (void) // default case is provided, it must be flagged off as an error. Our // front-end is not able to handle such a case since it is a semantic error // and not a syntax error. Such an error is caught here. - + switch (this->udisc_type ()) { case AST_Expression::EV_short: @@ -857,7 +857,7 @@ be_union::compute_default_value (void) -1); ACE_NOTREACHED (break;) } // end of switch - + // if we have determined that we don't need a default case and even then a // default case was provided, flag this off as error if ((this->default_value_.computed_ == 0) && @@ -870,13 +870,13 @@ be_union::compute_default_value (void) ASYS_TEXT ("- default clause is invalid here\n")), -1); } - + // proceed only if necessary switch (this->default_value_.computed_) { case -1: // error. We should never be here because errors have already been caught - // above + // above return -1; case 0: // nothing more to do @@ -926,9 +926,9 @@ be_union::compute_default_value (void) { si = new UTL_ScopeActiveIterator (this, UTL_Scope::IK_decls); // instantiate a scope iterator. - + int break_loop = 0; - + while (!(si->is_done ()) && !break_loop) { // get the next AST decl node @@ -947,14 +947,14 @@ be_union::compute_default_value (void) { // error this->default_value_.computed_ = -1; - ACE_ERROR_RETURN + ACE_ERROR_RETURN ((LM_ERROR, ASYS_TEXT ("(%N:%l) be_union::") ASYS_TEXT ("compute_default_value - ") ASYS_TEXT ("Bad case label value\n")), -1); } - + switch (expr->ev ()->et) { // check if they match in which case this @@ -962,7 +962,7 @@ be_union::compute_default_value (void) // start with a new value and try the whole loop // again because our case labels may not be sorted case AST_Expression::EV_short: - if (this->default_value_.u.short_val + if (this->default_value_.u.short_val == expr->ev ()->u.sval) { this->default_value_.u.short_val++; @@ -970,7 +970,7 @@ be_union::compute_default_value (void) } break; case AST_Expression::EV_ushort: - if (this->default_value_.u.ushort_val + if (this->default_value_.u.ushort_val == expr->ev ()->u.usval) { this->default_value_.u.ushort_val++; @@ -978,7 +978,7 @@ be_union::compute_default_value (void) } break; case AST_Expression::EV_long: - if (this->default_value_.u.long_val + if (this->default_value_.u.long_val == expr->ev ()->u.lval) { this->default_value_.u.long_val++; @@ -986,7 +986,7 @@ be_union::compute_default_value (void) } break; case AST_Expression::EV_ulong: - if (this->default_value_.u.ulong_val + if (this->default_value_.u.ulong_val == expr->ev ()->u.ulval) { this->default_value_.u.ulong_val++; @@ -994,7 +994,7 @@ be_union::compute_default_value (void) } break; case AST_Expression::EV_char: - if (this->default_value_.u.char_val + if (this->default_value_.u.char_val == expr->ev ()->u.cval) { this->default_value_.u.char_val++; @@ -1002,7 +1002,7 @@ be_union::compute_default_value (void) } break; case AST_Expression::EV_bool: - if (this->default_value_.u.bool_val + if (this->default_value_.u.bool_val == expr->ev ()->u.bval) { this->default_value_.u.bool_val++; @@ -1012,7 +1012,7 @@ be_union::compute_default_value (void) case AST_Expression::EV_any: // this is the case of enums. We maintain // evaluated values which always start with 0 - if (this->default_value_.u.enum_val + if (this->default_value_.u.enum_val == expr->ev ()->u.eval) { this->default_value_.u.enum_val++; @@ -1032,14 +1032,14 @@ be_union::compute_default_value (void) si->next (); } // end of while scope iterator loop delete si; // free the iterator object - + // we have not aborted the inner loops which means we have found the // default value if (!break_loop) this->default_value_.computed_ = 1; - + } // end of outer while - + return 0; } diff --git a/TAO/TAO_IDL/be/be_valuetype.cpp b/TAO/TAO_IDL/be/be_valuetype.cpp index 0b6c04a7472..0f769edaf33 100644 --- a/TAO/TAO_IDL/be/be_valuetype.cpp +++ b/TAO/TAO_IDL/be/be_valuetype.cpp @@ -136,7 +136,7 @@ be_valuetype::gen_var_defn (char *) // for over here. ch->indent (); // start with whatever was our current indent level - *ch << "class " << idl_global->export_macro () + *ch << "class " << idl_global->stub_export_macro () << " " << namebuf << nl; *ch << "{" << nl; *ch << "public:\n"; @@ -415,7 +415,7 @@ be_valuetype::gen_out_defn (char *) // generate the out definition (always in the client header) ch->indent (); // start with whatever was our current indent level - *ch << "class " << idl_global->export_macro () + *ch << "class " << idl_global->stub_export_macro () << " " << namebuf << nl; *ch << "{" << nl; *ch << "public:\n"; diff --git a/TAO/TAO_IDL/be/be_valuetype_fwd.cpp b/TAO/TAO_IDL/be/be_valuetype_fwd.cpp index a7a1d35ea38..a6edfb1f3f5 100644 --- a/TAO/TAO_IDL/be/be_valuetype_fwd.cpp +++ b/TAO/TAO_IDL/be/be_valuetype_fwd.cpp @@ -79,7 +79,7 @@ be_valuetype_fwd::gen_var_defn (char *) // for over here. ch->indent (); // start with whatever was our current indent level - *ch << "class " << idl_global->export_macro () + *ch << "class " << idl_global->stub_export_macro () << " " << namebuf << nl; *ch << "{" << nl; *ch << "public:\n"; @@ -342,7 +342,7 @@ be_valuetype_fwd::gen_out_defn (char *) // generate the out definition (always in the client header) ch->indent (); // start with whatever was our current indent level - *ch << "class " << idl_global->export_macro () + *ch << "class " << idl_global->stub_export_macro () << " " << namebuf << nl; *ch << "{" << nl; *ch << "public:\n"; diff --git a/TAO/TAO_IDL/be/be_visitor_array/any_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_array/any_op_ch.cpp index 15237b1baf9..5751c090d2e 100644 --- a/TAO/TAO_IDL/be/be_visitor_array/any_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_array/any_op_ch.cpp @@ -52,10 +52,10 @@ be_visitor_array_any_op_ch::visit_array (be_array *node) // generate the Any <<= and >>= operator declarations os->indent (); - *os << "void " << idl_global->export_macro () + *os << "void " << idl_global->stub_export_macro () << " operator<<= (CORBA::Any &, const " << node->name () << "_forany &);" << be_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>>= (const CORBA::Any &, " << node->name () << "_forany &);\n"; diff --git a/TAO/TAO_IDL/be/be_visitor_array/array_ch.cpp b/TAO/TAO_IDL/be/be_visitor_array/array_ch.cpp index c38780bdfdb..da56bc26e3a 100644 --- a/TAO/TAO_IDL/be/be_visitor_array/array_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_array/array_ch.cpp @@ -66,12 +66,12 @@ int be_visitor_array_ch::visit_array (be_array *node) // generate the ifdefined macro os->gen_ifdef_macro (node->flatname ()); - // If we contain an anonymous sequence, + // If we contain an anonymous sequence, // generate code for the sequence here. if (bt->node_type () == AST_Decl::NT_sequence) { - if (this->gen_anonymous_base_type (bt, - TAO_CodeGen::TAO_SEQUENCE_CH) + if (this->gen_anonymous_base_type (bt, + TAO_CodeGen::TAO_SEQUENCE_CH) == -1) { ACE_ERROR_RETURN ((LM_ERROR, @@ -79,7 +79,7 @@ int be_visitor_array_ch::visit_array (be_array *node) "visit_array - " "gen_anonymous_base_type failed\n"), -1); - } + } } os->indent (); @@ -312,7 +312,7 @@ be_visitor_array_ch::gen_var_defn (be_array *node) // for over here. os->indent (); // start with whatever was our current indent level - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->stub_export_macro () << " " << varnamebuf << be_nl; *os << "{" << be_nl; *os << "public:" << be_idt_nl; @@ -391,7 +391,7 @@ be_visitor_array_ch::gen_out_defn (be_array *node) // generate the out definition (always in the client header) os->indent (); // start with whatever was our current indent level - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->stub_export_macro () << " " << outnamebuf << be_nl; *os << "{" << be_nl; *os << "public:" << be_idt_nl; @@ -455,7 +455,7 @@ be_visitor_array_ch::gen_forany_defn (be_array *node) // for over here. os->indent (); // start with whatever was our current indent level - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->stub_export_macro () << " " << foranyname << be_nl; *os << "{" << be_nl; *os << "public:" << be_idt_nl; diff --git a/TAO/TAO_IDL/be/be_visitor_array/cdr_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_array/cdr_op_ch.cpp index 776217da5d5..29fdc73c3a7 100644 --- a/TAO/TAO_IDL/be/be_visitor_array/cdr_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_array/cdr_op_ch.cpp @@ -51,8 +51,8 @@ be_visitor_array_cdr_op_ch::visit_array (be_array *node) TAO_OutStream *os = this->ctx_->stream (); // generate the CDR << and >> operator declarations - *os << "CORBA::Boolean " << idl_global->export_macro () - << " operator<< (TAO_OutputCDR &, const "; + *os << "CORBA::Boolean " << idl_global->stub_export_macro () + << " operator<< (TAO_OutputCDR &, const "; // @@ TODO: this should be done in the node, it is absurd to repeat // this code all over the visitors!!!! if (!this->ctx_->tdef ()) @@ -67,7 +67,7 @@ be_visitor_array_cdr_op_ch::visit_array (be_array *node) { *os << node->name () << "_forany &);" << be_nl; } - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>> (TAO_InputCDR &, "; if (!this->ctx_->tdef ()) { diff --git a/TAO/TAO_IDL/be/be_visitor_enum/any_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_enum/any_op_ch.cpp index 46b3c3013ed..a206fcf721b 100644 --- a/TAO/TAO_IDL/be/be_visitor_enum/any_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_enum/any_op_ch.cpp @@ -51,10 +51,10 @@ be_visitor_enum_any_op_ch::visit_enum (be_enum *node) // generate the Any <<= and >>= operators os->indent (); - *os << "void " << idl_global->export_macro () + *os << "void " << idl_global->stub_export_macro () << " operator<<= (CORBA::Any &, " << node->name () << ");" << be_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>>= (const CORBA::Any &, " << node->name () << " &);\n"; diff --git a/TAO/TAO_IDL/be/be_visitor_enum/cdr_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_enum/cdr_op_ch.cpp index 7c35d00c706..b9f1ff8cb99 100644 --- a/TAO/TAO_IDL/be/be_visitor_enum/cdr_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_enum/cdr_op_ch.cpp @@ -52,10 +52,10 @@ be_visitor_enum_cdr_op_ch::visit_enum (be_enum *node) // generate the CDR << and >> operators os->indent (); - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator<< (TAO_OutputCDR &, const " << node->name () << " &); // " << be_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>> (TAO_InputCDR &, " << node->name () << " &);\n"; diff --git a/TAO/TAO_IDL/be/be_visitor_exception/any_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_exception/any_op_ch.cpp index d0c16445b30..af7554472a6 100644 --- a/TAO/TAO_IDL/be/be_visitor_exception/any_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_exception/any_op_ch.cpp @@ -51,13 +51,13 @@ be_visitor_exception_any_op_ch::visit_exception (be_exception *node) // generate the Any <<= and >>= operator declarations os->indent (); - *os << "void " << idl_global->export_macro () + *os << "void " << idl_global->stub_export_macro () << " operator<<= (CORBA::Any &, const " << node->name () << " &); // copying version" << be_nl; - *os << "void " << idl_global->export_macro () + *os << "void " << idl_global->stub_export_macro () << " operator<<= (CORBA::Any &, " << node->name () << "*); // noncopying version" << be_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>>= (const CORBA::Any &, " << node->name () << " *&);\n"; diff --git a/TAO/TAO_IDL/be/be_visitor_exception/cdr_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_exception/cdr_op_ch.cpp index 1910de4e68e..ca4afa88e48 100644 --- a/TAO/TAO_IDL/be/be_visitor_exception/cdr_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_exception/cdr_op_ch.cpp @@ -51,10 +51,10 @@ be_visitor_exception_cdr_op_ch::visit_exception (be_exception *node) // generate the Cdr <<= and >>= operator declarations os->indent (); - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator<< (TAO_OutputCDR &, const " << node->name () << " &); // " << be_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>> (TAO_InputCDR &, " << node->name () << " &);\n"; @@ -74,4 +74,3 @@ be_visitor_exception_cdr_op_ch::visit_exception (be_exception *node) node->cli_hdr_cdr_op_gen (1); return 0; } - diff --git a/TAO/TAO_IDL/be/be_visitor_exception/exception_ch.cpp b/TAO/TAO_IDL/be/be_visitor_exception/exception_ch.cpp index b724b9d6e7b..34bc5134cc1 100644 --- a/TAO/TAO_IDL/be/be_visitor_exception/exception_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_exception/exception_ch.cpp @@ -62,7 +62,7 @@ int be_visitor_exception_ch::visit_exception (be_exception *node) os->gen_ifdef_macro (node->flatname ()); os->indent (); - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->stub_export_macro () << " " << node->local_name () << " : public CORBA::UserException" << be_nl; *os << "{" << be_nl diff --git a/TAO/TAO_IDL/be/be_visitor_interface/ami_handler_ch.cpp b/TAO/TAO_IDL/be/be_visitor_interface/ami_handler_ch.cpp index 678314b2855..8a47537176f 100644 --- a/TAO/TAO_IDL/be/be_visitor_interface/ami_handler_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_interface/ami_handler_ch.cpp @@ -12,11 +12,11 @@ // // = DESCRIPTION // Visitor generating AMI Reply Handler code for Interfaces in the -// client header. +// client header. // // = AUTHOR // Aniruddha Gokhale and Alexander Babu Arulanthu -// <alex@cs.wustl.edu> +// <alex@cs.wustl.edu> // // ============================================================================ @@ -54,13 +54,13 @@ be_visitor_interface_ami_handler_ch::visit_interface (be_interface *node) ACE_OS::memset (namebuf, '\0', NAMEBUFSIZE); os = this->ctx_->stream (); - + // Generate the skeleton class name. // Start with whatever indentation level we are at. os->indent (); - // We shall have a POA_ prefix only if we are at the topmost level. + // We shall have a POA_ prefix only if we are at the topmost level. if (!node->is_nested ()) { // we are outermost @@ -82,8 +82,8 @@ be_visitor_interface_ami_handler_ch::visit_interface (be_interface *node) << "_ptr;" << be_nl; // Now generate the class definition. - // This class will inherit from the Messaging::ReplyHandler class. - *os << "class " << idl_global->export_macro () + // This class will inherit from the Messaging::ReplyHandler class. + *os << "class " << idl_global->stub_export_macro () << " " << namebuf << " : public POA_Messaging::ReplyHandler" << be_nl; @@ -95,20 +95,20 @@ be_visitor_interface_ami_handler_ch::visit_interface (be_interface *node) // Default constructor. *os << "protected:" << be_idt_nl << namebuf << " (void);\n" << be_uidt_nl; - - // Public portion starts. + + // Public portion starts. *os << "public:" << be_idt_nl - + // Copy constructor. << namebuf << " (const " << namebuf << "& rhs);" << be_nl - + // Destructor. << "virtual ~" << namebuf << " (void);\n\n" - + << be_nl; - + // Methods. - + // _is_a. *os << "virtual CORBA::Boolean _is_a (" << be_idt << be_idt_nl << "const char* logical_type_id," << be_nl @@ -116,12 +116,12 @@ be_visitor_interface_ami_handler_ch::visit_interface (be_interface *node) << "TAO_default_environment ()" << be_uidt << be_uidt_nl << ");\n" << be_uidt_nl; - + // _down_cast. *os << "virtual void* _downcast (" << be_idt << be_idt_nl << "const char* logical_type_id" << be_uidt_nl << ");\n" << be_uidt_nl; - + // add a skeleton for our _is_a method *os << "static void _is_a_skel (" << be_idt << be_idt_nl << "CORBA::ServerRequest &req," << be_nl @@ -193,7 +193,7 @@ be_visitor_interface_ami_handler_ch::visit_interface (be_interface *node) #if 0 // // @@ Alex: Do this: - // + // // Generate the collocated class be_visitor_context ctx (*this->ctx_); ctx.state (TAO_CodeGen::TAO_INTERFACE_COLLOCATED_SH); diff --git a/TAO/TAO_IDL/be/be_visitor_interface/ami_handler_servant_ch.cpp b/TAO/TAO_IDL/be/be_visitor_interface/ami_handler_servant_ch.cpp index 899412c61fb..4b378825cff 100644 --- a/TAO/TAO_IDL/be/be_visitor_interface/ami_handler_servant_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_interface/ami_handler_servant_ch.cpp @@ -12,11 +12,11 @@ // // = DESCRIPTION // Visitor generating AMI Reply Handler code for Interfaces in the -// client header. +// client header. // // = AUTHOR // Aniruddha Gokhale and Alexander Babu Arulanthu -// <alex@cs.wustl.edu> +// <alex@cs.wustl.edu> // // ============================================================================ @@ -52,7 +52,7 @@ be_visitor_interface_ami_handler_servant_ch::visit_interface (be_interface *node static char namebuf [NAMEBUFSIZE]; // AMI_<Interface_Name>_Handler string. - static char ami_handler [NAMEBUFSIZE]; + static char ami_handler [NAMEBUFSIZE]; if (node->srv_hdr_gen () || node->imported ()) return 0; @@ -61,13 +61,13 @@ be_visitor_interface_ami_handler_servant_ch::visit_interface (be_interface *node ACE_OS::memset (ami_handler, '\0', NAMEBUFSIZE); os = this->ctx_->stream (); - + // Generate the skeleton class name. // Start with whatever indentation level we are at. os->indent (); - // We shall have a POA_ prefix only if we are at the topmost level. + // We shall have a POA_ prefix only if we are at the topmost level. if (!node->is_nested ()) { // we are outermost @@ -86,7 +86,7 @@ be_visitor_interface_ami_handler_servant_ch::visit_interface (be_interface *node ACE_OS::sprintf (ami_handler, "AMI_%s_Handler", node->local_name ()->get_string ()); - + *os << "class " << namebuf << ";" << be_nl; // generate the _ptr declaration @@ -94,8 +94,8 @@ be_visitor_interface_ami_handler_servant_ch::visit_interface (be_interface *node << "_ptr;" << be_nl; // Now generate the class definition. - // This class will inherit from the Messaging::ReplyHandler class. - *os << "class " << idl_global->export_macro () + // This class will inherit from the Messaging::ReplyHandler class. + *os << "class " << idl_global->stub_export_macro () << " " << namebuf << " : public virtual POA_Messaging::ReplyHandler" << be_nl; @@ -107,20 +107,20 @@ be_visitor_interface_ami_handler_servant_ch::visit_interface (be_interface *node // Default constructor. *os << "protected:" << be_idt_nl << namebuf << " (void);\n" << be_uidt_nl; - - // Public portion starts. + + // Public portion starts. *os << "public:" << be_idt_nl - + // Copy constructor. << namebuf << " (const " << namebuf << "& rhs);" << be_nl - + // Destructor. << "virtual ~" << namebuf << " (void);\n\n" - + << be_nl; - + // Methods. - + // _is_a. *os << "virtual CORBA::Boolean _is_a (" << be_idt << be_idt_nl << "const char* logical_type_id," << be_nl @@ -128,12 +128,12 @@ be_visitor_interface_ami_handler_servant_ch::visit_interface (be_interface *node << "TAO_default_environment ()" << be_uidt << be_uidt_nl << ");\n" << be_uidt_nl; - + // _down_cast. *os << "virtual void* _downcast (" << be_idt << be_idt_nl << "const char* logical_type_id" << be_uidt_nl << ");\n" << be_uidt_nl; - + // add a skeleton for our _is_a method *os << "static void _is_a_skel (" << be_idt << be_idt_nl << "CORBA::ServerRequest &req," << be_nl diff --git a/TAO/TAO_IDL/be/be_visitor_interface/ami_handler_stub_ch.cpp b/TAO/TAO_IDL/be/be_visitor_interface/ami_handler_stub_ch.cpp index c4ee9d201d3..88e41aa859c 100644 --- a/TAO/TAO_IDL/be/be_visitor_interface/ami_handler_stub_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_interface/ami_handler_stub_ch.cpp @@ -16,7 +16,7 @@ // // = AUTHOR // Aniruddha Gokhale and Alexander Babu Arulanthu -// <alex@cs.wustl.edu> +// <alex@cs.wustl.edu> // // ============================================================================ @@ -50,22 +50,22 @@ be_visitor_interface_ami_handler_stub_ch::visit_interface (be_interface *node) { // Grab the stream. os = this->ctx_->stream (); - + // Ifdef guard. - + // Generate AMI_...name..._Handler string. char *ifdef_string = 0; ACE_NEW_RETURN (ifdef_string, char [ACE_OS::strlen ("AMI_") + - ACE_OS::strlen (node->flatname ()) + + ACE_OS::strlen (node->flatname ()) + ACE_OS::strlen ("_Handler") + // end of string 1], 0); - ACE_OS::sprintf (ifdef_string, + ACE_OS::sprintf (ifdef_string, "AMI_%s_Handler", node->flatname ()); - + os->gen_ifdef_macro (ifdef_string); // Prepare the local name for the class. @@ -77,26 +77,26 @@ be_visitor_interface_ami_handler_stub_ch::visit_interface (be_interface *node) // end of string 1], 0); - ACE_OS::sprintf (local_name, + ACE_OS::sprintf (local_name, "AMI_%s_Handler", node->local_name ()->get_string ()); // Now generate the class definition. - + os->indent (); - *os << "class " << idl_global->export_macro () << " " + *os << "class " << idl_global->stub_export_macro () << " " << local_name; - + // Node interface inherits from the Messaging::ReplyHandler - // interface. - *os << " : public virtual Messaging::ReplyHandler" << be_nl; - + // interface. + *os << " : public virtual Messaging::ReplyHandler" << be_nl; + // Generate the body. - + *os << "{" << be_nl << "public:" << be_nl - + // generate the _ptr_type and _var_type typedefs // but we must protect against certain versions of g++ << "#if !defined(__GNUC__) || __GNUC__ > 2 || __GNUC_MINOR__ >= 8" @@ -104,7 +104,7 @@ be_visitor_interface_ami_handler_stub_ch::visit_interface (be_interface *node) << "typedef " << local_name << "_ptr _ptr_type;" << be_nl << "typedef " << local_name << "_var _var_type;" << be_uidt_nl << "#endif /* __GNUC__ */\n" << be_idt_nl - + // generate the static _duplicate, _narrow, and _nil operations << "// the static operations" << be_nl << "static " << local_name << "_ptr " << "_duplicate (" @@ -126,7 +126,7 @@ be_visitor_interface_ami_handler_stub_ch::visit_interface (be_interface *node) << "static " << local_name << "_ptr " << "_nil (void);\n\n"; // Visit the scope to generate the stubs for the call back - // methods. + // methods. if (this->visit_scope (node) == -1) { ACE_ERROR_RETURN ((LM_ERROR, @@ -136,7 +136,7 @@ be_visitor_interface_ami_handler_stub_ch::visit_interface (be_interface *node) -1); } - + // the _is_a method os->indent (); *os << "virtual CORBA::Boolean _is_a (" << be_idt << be_idt_nl @@ -147,7 +147,7 @@ be_visitor_interface_ami_handler_stub_ch::visit_interface (be_interface *node) << ");" << be_uidt_nl << "virtual const char* " << "_interface_repository_id (void) const;\n" << be_uidt_nl; - + // generate the "protected" constructor so that users cannot instantiate // us *os << "protected:" << be_idt_nl @@ -158,7 +158,7 @@ be_visitor_interface_ami_handler_stub_ch::visit_interface (be_interface *node) << "CORBA::Boolean _tao_collocated = 0" << be_uidt_nl << ");" << be_uidt_nl << "virtual ~" << local_name << " (void);" << be_uidt_nl; - + // private copy constructor and assignment operator. These are not // allowed, hence they are private. *os << "private:\n"; @@ -166,11 +166,11 @@ be_visitor_interface_ami_handler_stub_ch::visit_interface (be_interface *node) *os << local_name << " (const " << local_name << " &);" << be_nl << "void operator= (const " << local_name << " &);\n"; - + os->decr_indent (); *os << "};\n\n"; os->gen_endif (); - + // by using a visitor to declare and define the TypeCode, we have the // added advantage to conditionally not generate any code. This will be // based on the command line options. This is still TO-DO @@ -187,7 +187,7 @@ be_visitor_interface_ami_handler_stub_ch::visit_interface (be_interface *node) -1); } - + // Delete the heap allocated vars. delete ifdef_string; ifdef_string = 0; diff --git a/TAO/TAO_IDL/be/be_visitor_interface/any_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_interface/any_op_ch.cpp index 4b5a6781d61..637cea63343 100644 --- a/TAO/TAO_IDL/be/be_visitor_interface/any_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_interface/any_op_ch.cpp @@ -53,19 +53,19 @@ be_visitor_interface_any_op_ch::visit_interface (be_interface *node) os->indent (); // Generate the stub factory function pointer declaration - *os << "extern " << node->name () << "_ptr (*_TAO_collocation_" - << node->flatname () << "_Stub_Factory_function_pointer) (" - << be_idt << be_idt_nl + *os << "extern " << idl_global->stub_export_macro () << " " << node->name () + << "_ptr (*_TAO_collocation_" << node->flatname () + << "_Stub_Factory_function_pointer) (" << be_idt << be_idt_nl << "CORBA::Object_ptr obj" << be_uidt_nl << ");" << be_uidt_nl; // generate the Any <<= and >>= operator declarations os->indent (); *os << "// Any operators for interface " << node->name () << be_nl; - *os << "void " << idl_global->export_macro () + *os << "void " << idl_global->stub_export_macro () << " operator<<= (CORBA::Any &, " << node->name () << "_ptr);" << be_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>>= (const CORBA::Any &, " << node->name () << " *&);\n"; diff --git a/TAO/TAO_IDL/be/be_visitor_interface/cdr_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_interface/cdr_op_ch.cpp index 0874e4517d1..b4b4d6817b9 100644 --- a/TAO/TAO_IDL/be/be_visitor_interface/cdr_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_interface/cdr_op_ch.cpp @@ -51,10 +51,10 @@ be_visitor_interface_cdr_op_ch::visit_interface (be_interface *node) // generate the CDR << and >> operator declarations os->indent (); - *os << "CORBA::Boolean " << idl_global->export_macro () << be_nl + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << be_nl << "operator<< (TAO_OutputCDR &, const " << node->name () << "_ptr );" << be_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () << be_nl + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << be_nl << "operator>> (TAO_InputCDR &, " << node->name () << "_ptr &);\n"; @@ -74,4 +74,3 @@ be_visitor_interface_cdr_op_ch::visit_interface (be_interface *node) node->cli_hdr_cdr_op_gen (1); return 0; } - diff --git a/TAO/TAO_IDL/be/be_visitor_interface/collocated_ami_handler_ch.cpp b/TAO/TAO_IDL/be/be_visitor_interface/collocated_ami_handler_ch.cpp index 9f30a1799c1..301472a8a1c 100644 --- a/TAO/TAO_IDL/be/be_visitor_interface/collocated_ami_handler_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_interface/collocated_ami_handler_ch.cpp @@ -25,7 +25,7 @@ #include "be_visitor_interface.h" -ACE_RCSID(be_visitor_interface, collocated_ami_handler_ch, "$Id$") +ACE_RCSID(be_visitor_interface, collocated_ami_handler_ch, "$Id$") // ************************************************************ @@ -51,17 +51,17 @@ be_visitor_interface_collocated_ami_handler_ch::visit_interface (be_interface *n char *ifdef_string = 0; ACE_NEW_RETURN (ifdef_string, char [ACE_OS::strlen ("AMI_") + - ACE_OS::strlen (node->flatname ()) + + ACE_OS::strlen (node->flatname ()) + ACE_OS::strlen ("_Handler") + // end of string 1], 0); - ACE_OS::sprintf (ifdef_string, + ACE_OS::sprintf (ifdef_string, "AMI_%s_Handler", node->flatname ()); - + os->gen_ifdef_macro (ifdef_string, "_collocated"); - + // Prepare the local name for the class. char *local_name = 0; ACE_NEW_RETURN (local_name, @@ -71,17 +71,17 @@ be_visitor_interface_collocated_ami_handler_ch::visit_interface (be_interface *n // end of string 1], 0); - ACE_OS::sprintf (local_name, + ACE_OS::sprintf (local_name, "AMI_%s_Handler", node->local_name ()->get_string ()); // Get the coll names. char *coll_local_name, *coll_full_name; - node->compute_coll_names (local_name, coll_local_name, coll_full_name); - + node->compute_coll_names (local_name, coll_local_name, coll_full_name); + // Output the class defn. os->indent (); - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->stub_export_macro () << " " << coll_local_name; os->incr_indent (); *os << " : public virtual " << local_name; @@ -107,7 +107,7 @@ be_visitor_interface_collocated_ami_handler_ch::visit_interface (be_interface *n *os << local_name << "_ptr " << " servant," << be_nl; - + *os << "TAO_Stub *stub\n"; os->decr_indent (); *os << ");\n"; @@ -121,7 +121,7 @@ be_visitor_interface_collocated_ami_handler_ch::visit_interface (be_interface *n << "const CORBA::Char *logical_type_id," << be_nl << "CORBA_Environment &TAO_IN_ENV = TAO_default_environment ()" << be_uidt_nl << ");" << be_uidt_nl << be_nl; - + // _get_servant method. if (!node->is_nested ()) @@ -151,7 +151,7 @@ be_visitor_interface_collocated_ami_handler_ch::visit_interface (be_interface *n } os->decr_indent (); - + *os << be_nl << "private:\n"; os->incr_indent (); if (!node->is_nested ()) diff --git a/TAO/TAO_IDL/be/be_visitor_interface/direct_collocated_sh.cpp b/TAO/TAO_IDL/be/be_visitor_interface/direct_collocated_sh.cpp index 277da8eece2..6f23f294d9b 100644 --- a/TAO/TAO_IDL/be/be_visitor_interface/direct_collocated_sh.cpp +++ b/TAO/TAO_IDL/be/be_visitor_interface/direct_collocated_sh.cpp @@ -50,7 +50,7 @@ int be_visitor_interface_direct_collocated_sh::visit_interface (be_interface *no // output the class defn os->indent (); - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->skel_export_macro () << " " << node->local_coll_name (be_interface::DIRECT); os->incr_indent (); *os << " : public virtual " << node->name (); diff --git a/TAO/TAO_IDL/be/be_visitor_interface/interface_ch.cpp b/TAO/TAO_IDL/be/be_visitor_interface/interface_ch.cpp index 805b95c7bd8..67823da0377 100644 --- a/TAO/TAO_IDL/be/be_visitor_interface/interface_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_interface/interface_ch.cpp @@ -136,7 +136,7 @@ be_visitor_interface_ch::visit_interface (be_interface *node) os->gen_ifdef_macro (node->flatname ()); // now generate the class definition - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->stub_export_macro () << " " << node->local_name (); if (node->n_inherits () > 0) // node interface inherits from other @@ -272,10 +272,10 @@ be_visitor_interface_ch::visit_interface (be_interface *node) "TypeCode declaration failed\n" ), -1); } - + // AMI - // Generate code for the AMI Reply Handler. + // Generate code for the AMI Reply Handler. if (idl_global->ami_call_back () == I_TRUE) { @@ -297,7 +297,7 @@ be_visitor_interface_ch::visit_interface (be_interface *node) "Bad visitor\n"), -1); } - + // Call the visitor on this interface. if (node->accept (visitor) == -1) { @@ -309,15 +309,15 @@ be_visitor_interface_ch::visit_interface (be_interface *node) -1); } delete visitor; - + // = Generate the Servant Skeleton code. // Set the context. ctx = *this->ctx_; - + // Set the state. ctx.state (TAO_CodeGen::TAO_AMI_HANDLER_SERVANT_CH); - + // Create the visitor. visitor = tao_cg->make_visitor (&ctx); if (!visitor) @@ -328,7 +328,7 @@ be_visitor_interface_ch::visit_interface (be_interface *node) "Bad visitor\n"), -1); } - + // call the visitor on this interface. if (node->accept (visitor) == -1) { diff --git a/TAO/TAO_IDL/be/be_visitor_interface/interface_ih.cpp b/TAO/TAO_IDL/be/be_visitor_interface/interface_ih.cpp index bbed2526a80..91d48ef2a02 100644 --- a/TAO/TAO_IDL/be/be_visitor_interface/interface_ih.cpp +++ b/TAO/TAO_IDL/be/be_visitor_interface/interface_ih.cpp @@ -56,12 +56,12 @@ be_visitor_interface_ih::visit_interface (be_interface *node) os->indent (); // start with whatever indentation level we are at - + ACE_OS::sprintf (namebuf, "%s", node->flatname ()); - + *os << "//Class " << idl_global->impl_class_prefix ()<<namebuf << idl_global->impl_class_suffix ()<< be_nl; // now generate the class definition - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->stub_export_macro () << " " <<idl_global->impl_class_prefix () << namebuf << idl_global->impl_class_suffix () << " : "; /* if (node->n_inherits () > 0) @@ -71,7 +71,7 @@ be_visitor_interface_ih::visit_interface (be_interface *node) *os << "public virtual "; - + intf = be_interface::narrow_from_decl (node->inherits ()[0]); *os << idl_global->impl_class_prefix () << intf->flatname () << idl_global->impl_class_suffix ();//intf->relative_skel_name (node->full_skel_name ()); for (i = 1; i < node->n_inherits (); i++) @@ -84,15 +84,15 @@ be_visitor_interface_ih::visit_interface (be_interface *node) //inherit from the base skeleton file *os<<", public virtual "<<node->full_skel_name (); } - + else { */ //inherit from the base skeleton file *os<<"public virtual "<<node->full_skel_name (); // } - - + + *os << be_nl << "{" << be_nl << "public:" << be_idt_nl @@ -102,22 +102,22 @@ be_visitor_interface_ih::visit_interface (be_interface *node) if (idl_global->gen_copy_ctor ()) { *os << "//Copy Constructor"<<be_nl - << idl_global->impl_class_prefix () << namebuf << idl_global->impl_class_suffix () << " (const " + << idl_global->impl_class_prefix () << namebuf << idl_global->impl_class_suffix () << " (const " << idl_global->impl_class_prefix () << namebuf << idl_global->impl_class_suffix () << "&);" <<be_nl <<be_nl; } - if (idl_global->gen_assign_op ()) + if (idl_global->gen_assign_op ()) { *os << "//Copy Assignment" << be_nl << idl_global->impl_class_prefix () << namebuf << idl_global->impl_class_suffix () << "& " << "operator=(const " << idl_global->impl_class_prefix () << namebuf << idl_global->impl_class_suffix () << "&);"<<be_nl << be_nl; } - + *os << "//Destructor " << be_nl << "virtual " << "~" << idl_global->impl_class_prefix () << namebuf << idl_global->impl_class_suffix () << " (void);" << be_nl << be_uidt_nl; - + // generate code for elements in the scope (e.g., operations) if (this->visit_scope (node) == -1) { @@ -127,7 +127,7 @@ be_visitor_interface_ih::visit_interface (be_interface *node) "codegen for scope failed\n"), -1); } - + if (node->n_inherits () > 0) { // this interface inherits from other interfaces @@ -146,12 +146,9 @@ be_visitor_interface_ih::visit_interface (be_interface *node) -1); } } - + } - + *os << "};" << be_nl <<be_nl; return 0; } - - - diff --git a/TAO/TAO_IDL/be/be_visitor_interface/interface_sh.cpp b/TAO/TAO_IDL/be/be_visitor_interface/interface_sh.cpp index a12411dae6d..437ca6e9dac 100644 --- a/TAO/TAO_IDL/be/be_visitor_interface/interface_sh.cpp +++ b/TAO/TAO_IDL/be/be_visitor_interface/interface_sh.cpp @@ -76,7 +76,7 @@ be_visitor_interface_sh::visit_interface (be_interface *node) << "_ptr;" << be_nl; // now generate the class definition - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->skel_export_macro () << " " << namebuf << " : "; if (node->n_inherits () > 0) { diff --git a/TAO/TAO_IDL/be/be_visitor_interface/thru_poa_collocated_sh.cpp b/TAO/TAO_IDL/be/be_visitor_interface/thru_poa_collocated_sh.cpp index 33fb7be9f5e..fd104d55a66 100644 --- a/TAO/TAO_IDL/be/be_visitor_interface/thru_poa_collocated_sh.cpp +++ b/TAO/TAO_IDL/be/be_visitor_interface/thru_poa_collocated_sh.cpp @@ -50,7 +50,7 @@ int be_visitor_interface_thru_poa_collocated_sh::visit_interface (be_interface * // output the class defn os->indent (); - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->skel_export_macro () << " " << node->local_coll_name (be_interface::THRU_POA); os->incr_indent (); *os << " : public virtual " << node->name (); diff --git a/TAO/TAO_IDL/be/be_visitor_interface/tie_sh.cpp b/TAO/TAO_IDL/be/be_visitor_interface/tie_sh.cpp index 4892051d8b9..0c568e4bfe5 100644 --- a/TAO/TAO_IDL/be/be_visitor_interface/tie_sh.cpp +++ b/TAO/TAO_IDL/be/be_visitor_interface/tie_sh.cpp @@ -87,7 +87,7 @@ be_visitor_interface_tie_sh::visit_interface (be_interface *node) *os << "// TIE class: Refer to CORBA v2.2, Section 20.34.4" << be_nl; *os << "template <class T>" << be_nl; - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->skel_export_macro () << " " << tiename << " : public " << namebuf << be_nl; *os << "{" << be_nl << "public:" << be_idt_nl diff --git a/TAO/TAO_IDL/be/be_visitor_module/module_ch.cpp b/TAO/TAO_IDL/be/be_visitor_module/module_ch.cpp index f109e3cd647..bdecfc4e071 100644 --- a/TAO/TAO_IDL/be/be_visitor_module/module_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_module/module_ch.cpp @@ -56,7 +56,7 @@ be_visitor_module_ch::visit_module (be_module *node) os->indent (); // start from whatever indentation level we were at // now generate the class definition - *os << "TAO_NAMESPACE " // << idl_global->export_macro () + *os << "TAO_NAMESPACE " // << idl_global->stub_export_macro () << " " << node->local_name () << be_nl << "{\n"; os->incr_indent (0); diff --git a/TAO/TAO_IDL/be/be_visitor_module/module_sh.cpp b/TAO/TAO_IDL/be/be_visitor_module/module_sh.cpp index f3080384f59..c2eabbdf962 100644 --- a/TAO/TAO_IDL/be/be_visitor_module/module_sh.cpp +++ b/TAO/TAO_IDL/be/be_visitor_module/module_sh.cpp @@ -55,7 +55,7 @@ be_visitor_module_sh::visit_module (be_module *node) // now generate the class definition. The prefix POA_ is prepended to our // name only if we are the outermost module - *os << "TAO_NAMESPACE "; // << idl_global->export_macro () + *os << "TAO_NAMESPACE "; // << idl_global->skel_export_macro () if (!node->is_nested ()) // we are outermost module diff --git a/TAO/TAO_IDL/be/be_visitor_sequence/any_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_sequence/any_op_ch.cpp index f1223cd7642..531cf49e1c2 100644 --- a/TAO/TAO_IDL/be/be_visitor_sequence/any_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_sequence/any_op_ch.cpp @@ -51,13 +51,13 @@ be_visitor_sequence_any_op_ch::visit_sequence (be_sequence *node) // generate the Any <<= and >>= operators os->indent (); - *os << "void " << idl_global->export_macro () + *os << "void " << idl_global->stub_export_macro () << " operator<<= (CORBA::Any &, const " << node->name () << " &); // copying version" << be_nl; - *os << "void " << idl_global->export_macro () + *os << "void " << idl_global->stub_export_macro () << " operator<<= (CORBA::Any &, " << node->name () << "*); // noncopying version" << be_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>>= (const CORBA::Any &, " << node->name () << " *&);\n"; diff --git a/TAO/TAO_IDL/be/be_visitor_sequence/cdr_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_sequence/cdr_op_ch.cpp index 773a7f26d73..b78d64c9d7f 100644 --- a/TAO/TAO_IDL/be/be_visitor_sequence/cdr_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_sequence/cdr_op_ch.cpp @@ -51,12 +51,12 @@ be_visitor_sequence_cdr_op_ch::visit_sequence (be_sequence *node) // generate the CDR << and >> operator declarations os->indent (); - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator<< (" << be_idt << be_idt_nl << "TAO_OutputCDR &," << be_nl << "const " << node->name () << " &" << be_uidt_nl << ");" << be_uidt_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>> (" << be_idt << be_idt_nl << "TAO_InputCDR &," << be_nl << node->name () << " &" << be_uidt_nl diff --git a/TAO/TAO_IDL/be/be_visitor_sequence/cdr_op_ci.cpp b/TAO/TAO_IDL/be/be_visitor_sequence/cdr_op_ci.cpp index c2da5f9d78d..dec49f1517a 100644 --- a/TAO/TAO_IDL/be/be_visitor_sequence/cdr_op_ci.cpp +++ b/TAO/TAO_IDL/be/be_visitor_sequence/cdr_op_ci.cpp @@ -56,12 +56,12 @@ be_visitor_sequence_cdr_op_ci::visit_sequence (be_sequence *node) // the dependencies for recursive types. os->indent (); - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator<< (" << be_idt << be_idt_nl << "TAO_OutputCDR &," << be_nl << "const " << node->name () << " &" << be_uidt_nl << ");" << be_uidt_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>> (" << be_idt << be_idt_nl << "TAO_InputCDR &," << be_nl << node->name () << " &" << be_uidt_nl diff --git a/TAO/TAO_IDL/be/be_visitor_sequence/sequence_ch.cpp b/TAO/TAO_IDL/be/be_visitor_sequence/sequence_ch.cpp index 26a8f5c15ba..4afb9114834 100644 --- a/TAO/TAO_IDL/be/be_visitor_sequence/sequence_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_sequence/sequence_ch.cpp @@ -130,7 +130,7 @@ be_visitor_sequence_ch::gen_base_sequence_class (be_sequence *node) *os << ", " << node->max_size () << ">"; } } - + os->gen_endif_AHETI(); return 0; @@ -164,7 +164,7 @@ be_visitor_sequence_ch::instantiate_sequence (be_sequence *node) case be_sequence::MNG_STRING: // sequence of strings if (!node->unbounded ()) this->gen_bounded_str_sequence (node); - // else + // else // inheriting from the right class is enough break; default: // not a managed type @@ -176,9 +176,9 @@ be_visitor_sequence_ch::instantiate_sequence (be_sequence *node) be_predefined_type *predef = 0; if (bt->base_node_type () == AST_Type::NT_pre_defined) { - be_typedef* alias = + be_typedef* alias = be_typedef::narrow_from_decl (bt); - + if (alias == 0) { predef = @@ -199,7 +199,7 @@ be_visitor_sequence_ch::instantiate_sequence (be_sequence *node) this->gen_unbounded_sequence (node); #else // @@ This needs to be fixed. (Michael) - be_predefined_type * bpt = + be_predefined_type * bpt = be_predefined_type::narrow_from_decl (node->base_type()); if (bpt) { @@ -271,7 +271,7 @@ int be_visitor_sequence_ch::visit_sequence (be_sequence *node) << be_nl << be_nl; // generate a typedef to a parametrized sequence - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->stub_export_macro () << " " << node->local_name () << " : public "; if (this->gen_base_sequence_class (node) == -1) @@ -332,7 +332,7 @@ int be_visitor_sequence_ch::visit_sequence (be_sequence *node) be_predefined_type *predef = 0; if (bt->base_node_type () == AST_Type::NT_pre_defined) { - be_typedef* alias = + be_typedef* alias = be_typedef::narrow_from_decl (bt); if (alias == 0) @@ -454,7 +454,7 @@ be_visitor_sequence_ch::gen_var_defn (be_sequence *node) // for over here. os->indent (); // start with whatever was our current indent level - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->stub_export_macro () << " " << namebuf << be_nl; *os << "{" << be_nl; *os << "public:\n"; @@ -563,7 +563,7 @@ be_visitor_sequence_ch::gen_out_defn (be_sequence *node) // generate the out definition (always in the client header) os->indent (); // start with whatever was our current indent level - *os << "class " << idl_global->export_macro () << " " + *os << "class " << idl_global->stub_export_macro () << " " << namebuf << be_nl; *os << "{" << be_nl; *os << "public:\n"; diff --git a/TAO/TAO_IDL/be/be_visitor_structure/any_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_structure/any_op_ch.cpp index 34b3f3210d3..7ece072b5f7 100644 --- a/TAO/TAO_IDL/be/be_visitor_structure/any_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_structure/any_op_ch.cpp @@ -51,13 +51,13 @@ be_visitor_structure_any_op_ch::visit_structure (be_structure *node) // generate the Any <<= and >>= operator declarations os->indent (); - *os << "void " << idl_global->export_macro () + *os << "void " << idl_global->stub_export_macro () << " operator<<= (CORBA::Any &, const " << node->name () << " &); // copying version" << be_nl; - *os << "void " << idl_global->export_macro () + *os << "void " << idl_global->stub_export_macro () << " operator<<= (CORBA::Any &, " << node->name () << "*); // noncopying version" << be_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>>= (const CORBA::Any &, " << node->name () << " *&);\n"; diff --git a/TAO/TAO_IDL/be/be_visitor_structure/cdr_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_structure/cdr_op_ch.cpp index a5313415f80..5f77c18f62c 100644 --- a/TAO/TAO_IDL/be/be_visitor_structure/cdr_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_structure/cdr_op_ch.cpp @@ -51,10 +51,10 @@ be_visitor_structure_cdr_op_ch::visit_structure (be_structure *node) // generate the CDR << and >> operator declarations os->indent (); - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator<< (TAO_OutputCDR &, const " << node->name () << " &);" << be_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>> (TAO_InputCDR &, " << node->name () << " &);\n"; diff --git a/TAO/TAO_IDL/be/be_visitor_structure/structure_ch.cpp b/TAO/TAO_IDL/be/be_visitor_structure/structure_ch.cpp index f9ce9cb68e2..f61809509c0 100644 --- a/TAO/TAO_IDL/be/be_visitor_structure/structure_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_structure/structure_ch.cpp @@ -51,7 +51,7 @@ int be_visitor_structure_ch::visit_structure (be_structure *node) os = this->ctx_->stream (); os->indent (); // start from whatever indentation level we were at - *os << "struct " << idl_global->export_macro () << " " + *os << "struct " << idl_global->stub_export_macro () << " " << node->local_name () << be_nl << "{" << be_idt << "\n"; diff --git a/TAO/TAO_IDL/be/be_visitor_typecode/typecode_decl.cpp b/TAO/TAO_IDL/be/be_visitor_typecode/typecode_decl.cpp index 90db4fab104..489ea7f3285 100644 --- a/TAO/TAO_IDL/be/be_visitor_typecode/typecode_decl.cpp +++ b/TAO/TAO_IDL/be/be_visitor_typecode/typecode_decl.cpp @@ -73,7 +73,7 @@ be_visitor_typecode_decl::visit_type (be_type *node) { // we are in the ROOT scope os->indent (); - *os << "extern " << idl_global->export_macro () << " CORBA::TypeCode_ptr " + *os << "extern " << idl_global->stub_export_macro () << " CORBA::TypeCode_ptr " << " " << node->tc_name (prefix, postfix)->last_component () << ";\n\n"; } return 0; diff --git a/TAO/TAO_IDL/be/be_visitor_union/any_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_union/any_op_ch.cpp index f743a905db8..392af049873 100644 --- a/TAO/TAO_IDL/be/be_visitor_union/any_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_union/any_op_ch.cpp @@ -51,13 +51,13 @@ be_visitor_union_any_op_ch::visit_union (be_union *node) // generate the Any <<= and >>= operator declarations os->indent (); - *os << "void " << idl_global->export_macro () + *os << "void " << idl_global->stub_export_macro () << " operator<<= (CORBA::Any &, const " << node->name () << " &); // copying version" << be_nl; - *os << "void " << idl_global->export_macro () + *os << "void " << idl_global->stub_export_macro () << " operator<<= (CORBA::Any &, " << node->name () << "*); // noncopying version" << be_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>>= (const CORBA::Any &, " << node->name () << " *&);\n"; diff --git a/TAO/TAO_IDL/be/be_visitor_union/cdr_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_union/cdr_op_ch.cpp index 01173b46b6d..ed9b70a4b94 100644 --- a/TAO/TAO_IDL/be/be_visitor_union/cdr_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_union/cdr_op_ch.cpp @@ -51,10 +51,10 @@ be_visitor_union_cdr_op_ch::visit_union (be_union *node) // generate the CDR << and >> operator declarations os->indent (); - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator<< (TAO_OutputCDR &, const " << node->name () << " &); // " << be_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>> (TAO_InputCDR &, " << node->name () << " &);\n"; diff --git a/TAO/TAO_IDL/be/be_visitor_union/union_ch.cpp b/TAO/TAO_IDL/be/be_visitor_union/union_ch.cpp index b3d8de89394..e2a13a2553f 100644 --- a/TAO/TAO_IDL/be/be_visitor_union/union_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_union/union_ch.cpp @@ -60,7 +60,7 @@ int be_visitor_union_ch::visit_union (be_union *node) // generate the ifdefined macro for the union type os->gen_ifdef_macro (node->flatname ()); os->indent (); // start with the current indentation level - *os << "class " << idl_global->export_macro () << " " + *os << "class " << idl_global->stub_export_macro () << " " << node->local_name () << ": public TAO_Base_Union " << be_nl << "{" << be_nl << "public:" << be_idt_nl diff --git a/TAO/TAO_IDL/be/be_visitor_valuetype/cdr_op_ch.cpp b/TAO/TAO_IDL/be/be_visitor_valuetype/cdr_op_ch.cpp index eb01d5ff6c4..7a467491264 100644 --- a/TAO/TAO_IDL/be/be_visitor_valuetype/cdr_op_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_valuetype/cdr_op_ch.cpp @@ -50,10 +50,10 @@ be_visitor_valuetype_cdr_op_ch::visit_valuetype (be_valuetype *node) // generate the CDR << and >> operator declarations (prototypes) os->indent (); - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator<< (TAO_OutputCDR &, const " << node->name () << " *); // " << be_nl; - *os << "CORBA::Boolean " << idl_global->export_macro () + *os << "CORBA::Boolean " << idl_global->stub_export_macro () << " operator>> (TAO_InputCDR &, " << node->name () << " *&);\n"; diff --git a/TAO/TAO_IDL/be/be_visitor_valuetype/obv_module.cpp b/TAO/TAO_IDL/be/be_visitor_valuetype/obv_module.cpp index 70806d09556..1429a4d15cd 100644 --- a/TAO/TAO_IDL/be/be_visitor_valuetype/obv_module.cpp +++ b/TAO/TAO_IDL/be/be_visitor_valuetype/obv_module.cpp @@ -60,7 +60,7 @@ be_visitor_obv_module::visit_module (be_module *node) { os->indent (); - *os << "TAO_NAMESPACE "; // << idl_global->export_macro () + *os << "TAO_NAMESPACE "; // << idl_global->skel_export_macro () if (!node->is_nested ()) // we are outermost module, so prepend diff --git a/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype.cpp b/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype.cpp index 41451082e2d..c86280c98f6 100644 --- a/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype.cpp +++ b/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype.cpp @@ -783,7 +783,7 @@ be_visitor_valuetype::gen_init_defn (be_valuetype *node) os = this->ctx_->stream (); os->indent (); // start with whatever indentation level we are at - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->skel_export_macro () << " " << node->local_name () << "_init : public ACE_CORBA_1 (ValueFactoryBase)" << be_nl; diff --git a/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_ch.cpp b/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_ch.cpp index e15b3aedea9..e7b73bd505d 100644 --- a/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_ch.cpp +++ b/TAO/TAO_IDL/be/be_visitor_valuetype/valuetype_ch.cpp @@ -107,7 +107,7 @@ be_visitor_valuetype_ch::visit_valuetype (be_valuetype *node) // now generate the class definition os->indent (); - *os << "class " << idl_global->export_macro () + *os << "class " << idl_global->stub_export_macro () << " " << node->local_name (); // node valuetype inherits from other valuetypes (OMG 20.17.9) diff --git a/TAO/TAO_IDL/include/idl_global.h b/TAO/TAO_IDL/include/idl_global.h index d852679038f..be05997ff50 100644 --- a/TAO/TAO_IDL/include/idl_global.h +++ b/TAO/TAO_IDL/include/idl_global.h @@ -370,19 +370,35 @@ public: static const char *be_get_server_template_inline (UTL_String *idl_file_name, int base_name_only = 0); - virtual const char* export_macro (void) const; - // returns the macro name for exporting classes in Win32 DLL. + virtual const char* skel_export_macro (void) const; + // returns the macro name for exporting server side classes in Win32 + // DLL. - virtual void export_macro (const char* s); - // set the macro name for export classes in Win32 DLL. + virtual void skel_export_macro (const char* s); + // set the macro name for export server side classes in Win32 DLL. - virtual const char* export_include (void) const; - // returns the name of the include file that contains the export - // macro definition. + virtual const char* skel_export_include (void) const; + // returns the name of the include file that contains the server + // side export macro definition. - virtual void export_include (const char* s); - // set the name of the include file that contains the export - // macro definition. + virtual void skel_export_include (const char* s); + // set the name of the include file that contains the server side + // export macro definition. + + virtual const char* stub_export_macro (void) const; + // returns the macro name for exporting client side classes in Win32 + // DLL. + + virtual void stub_export_macro (const char* s); + // set the macro name for export client side classes in Win32 DLL. + + virtual const char* stub_export_include (void) const; + // returns the name of the include file that contains the client + // side export macro definition. + + virtual void stub_export_include (const char* s); + // set the name of the include file that contains the client side + // export macro definition. virtual const char* pch_include (void) const; // returns the name of the include file to be used for precompiled @@ -633,8 +649,10 @@ private: // files (e.g. tao/corba.h) so that #include statements can be // generated with ""s or <>s respectively. - char* export_macro_; - char* export_include_; + char* skel_export_macro_; + char* skel_export_include_; + char* stub_export_macro_; + char* stub_export_include_; char* pch_include_; // Client's header file name ending. Default is "C.h". diff --git a/TAO/TAO_IDL/util/utl_global.cpp b/TAO/TAO_IDL/util/utl_global.cpp index b8783829f18..289c045e94b 100644 --- a/TAO/TAO_IDL/util/utl_global.cpp +++ b/TAO/TAO_IDL/util/utl_global.cpp @@ -108,8 +108,10 @@ IDL_GlobalData::IDL_GlobalData (void) pd_parse_state (PS_NoState), pd_idl_src_file (0), changing_standard_include_files_ (1), - export_macro_ (0), - export_include_ (0), + skel_export_macro_ (0), + skel_export_include_ (0), + stub_export_macro_ (0), + stub_export_include_ (0), pch_include_ (0), client_hdr_ending_ (ACE::strnew ("C.h")), client_stub_ending_ (ACE::strnew ("C.cpp")), @@ -1010,41 +1012,67 @@ IDL_GlobalData::be_get_server_template_inline_fname (int base_name_only) } const char* -IDL_GlobalData::export_macro (void) const +IDL_GlobalData::skel_export_macro (void) const { - if (this->export_macro_ == 0) + if (this->skel_export_macro_ == 0) return ""; - return this->export_macro_; + return this->skel_export_macro_; } void -IDL_GlobalData::export_macro (const char *s) +IDL_GlobalData::skel_export_macro (const char *s) { - this->export_macro_ = ACE_OS::strdup (s); + this->skel_export_macro_ = ACE_OS::strdup (s); } const char* -IDL_GlobalData::export_include (void) const +IDL_GlobalData::skel_export_include (void) const { - return this->export_include_; + return this->skel_export_include_; +} + +void +IDL_GlobalData::skel_export_include (const char *s) +{ + this->skel_export_include_ = ACE_OS::strdup (s); } const char* -IDL_GlobalData::pch_include (void) const +IDL_GlobalData::stub_export_macro (void) const { - return this->pch_include_; -} + if (this->stub_export_macro_ == 0) + return ""; + return this->stub_export_macro_; +} void -IDL_GlobalData::pch_include (const char *s) +IDL_GlobalData::stub_export_macro (const char *s) { - this->pch_include_ = ACE_OS::strdup (s); + this->stub_export_macro_ = ACE_OS::strdup (s); +} + +const char* +IDL_GlobalData::stub_export_include (void) const +{ + return this->stub_export_include_; } void -IDL_GlobalData::export_include (const char *s) +IDL_GlobalData::stub_export_include (const char *s) { - this->export_include_ = ACE_OS::strdup (s); + this->stub_export_include_ = ACE_OS::strdup (s); +} + +const char* +IDL_GlobalData::pch_include (void) const +{ + return this->pch_include_; +} + +void +IDL_GlobalData::pch_include (const char *s) +{ + this->pch_include_ = ACE_OS::strdup (s); } // Set the client_hdr_ending. diff --git a/TAO/docs/compiler.html b/TAO/docs/compiler.html index 8b9b7fdf1fb..becd6b65a26 100644 --- a/TAO/docs/compiler.html +++ b/TAO/docs/compiler.html @@ -169,27 +169,73 @@ also receives other options that are specific to it. <P> <td> </td> </tr> - <tr><a name="export_macro"> + <tr><a name="skel_export_macro"> <td></td> - <td><tt>export_macro=</tt><i>macro_name</i></td> + <td><tt>skel_export_macro=</tt><i>macro_name</i></td> <td>The compiler will emit <i>macro_name</i> right after each <tt>class</tt> - or <tt>extern</tt> keyword, this is needed for Windows/NT that requires + or <tt>extern</tt> keyword in the generated skeleton code (S + files,) this is needed for Windows/NT that requires special directives to export symbols from DLLs, usually the definition is just a space on unix platforms. </td> </tr> - <tr><a name="export_include"> + <tr><a name="skel_export_include"> <td></td> - <td><tt>export_include=</tt><i>include_path</i></td> + <td><tt>skel_export_include=</tt><i>include_path</i></td> + + <td>The compiler will generate code to include <i>include_path</i> at the + top of the generated server header, this is usually a good + place to define the server side export macro.</td> + </tr> + + <tr><a name="stub_export_macro"> + <td></td> + + <td><tt>stub_export_macro=</tt><i>macro_name</i></td> + + <td>The compiler will emit <i>macro_name</i> right after each <tt>class</tt> + or <tt>extern</tt> keyword in the generated stub code, this is + needed for Windows/NT that requires special directives to + export symbols from DLLs, usually the definition is just a + space on unix platforms. </td> + </tr> + + <tr><a name="stub_export_include"> + <td></td> + + <td><tt>stub_export_include=</tt><i>include_path</i></td> <td>The compiler will generate code to include <i>include_path</i> at the top of the client header, this is usually a good place to define the export macro.</td> </tr> + <tr><a name="export_macro"> + <td></td> + + <td><tt>export_macro=</tt><i>macro_name</i></td> + + <td>This option has the same effect as issuing + <tt>-Wb,skel_export_macro=</tt><i>macro_name</i> + <tt>-Wb,stub_export_macro=</tt><i>macro_name</i>. This option + is useful when building a DLL containing both stubs and + skeletons.</td> + </tr> + + <tr><a name="export_include"> + <td></td> + + <td><tt>export_include=</tt><i>include_path</i></td> + + <td>This option has the same effect as specifying + <tt>-Wb,stub_export_include=</tt><i>include_path</t>. This + option goes with the previous option to build DLL containing + both stubs and skeletons.</td> + </tr> + <tr><a name="pch_include"> <td></td> |