summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgokhale <asgokhale@users.noreply.github.com>1998-06-26 17:59:21 +0000
committergokhale <asgokhale@users.noreply.github.com>1998-06-26 17:59:21 +0000
commit3f66e17352ae90d2ce899ee695131c14d8252e34 (patch)
treebaaf69b325835a833814e58b87bc15b6ae341c7e
parentf84d2a804b3f44ff1beef35bd32f7010ec914c82 (diff)
downloadATCD-3f66e17352ae90d2ce899ee695131c14d8252e34.tar.gz
*** empty log message ***
-rw-r--r--TAO/ChangeLog-98c9
-rw-r--r--TAO/TAO_IDL/be/be_visitor_operation/rettype_post_docall_cs.cpp16
-rw-r--r--TAO/TAO_IDL/be/be_visitor_operation/rettype_pre_docall_cs.cpp32
3 files changed, 51 insertions, 6 deletions
diff --git a/TAO/ChangeLog-98c b/TAO/ChangeLog-98c
index adf203140cd..9098884dc53 100644
--- a/TAO/ChangeLog-98c
+++ b/TAO/ChangeLog-98c
@@ -1,3 +1,12 @@
+Fri Jun 26 12:54:25 1998 Aniruddha Gokhale <gokhale@mambo.cs.wustl.edu>
+
+ * TAO_IDL/be/be_visitor_operation/{rettype_post_docall_cs,
+ rettype_pre_docall_cs}.cpp: We were using the underlying node
+ names in the generated code even when those nodes were Typedefed
+ to other names. So in such cases, we should use the typedef name.
+ Thanks to John Geiss <jtgb@eci-esyst.com> for reporting the
+ problem.
+
Fri Jun 26 11:46:46 1998 David L. Levine <levine@cs.wustl.edu>
* TAO_IDL/be/be_visitor_sequence/gen_{,un}bounded_sequence_ch.cpp:
diff --git a/TAO/TAO_IDL/be/be_visitor_operation/rettype_post_docall_cs.cpp b/TAO/TAO_IDL/be/be_visitor_operation/rettype_post_docall_cs.cpp
index a906fcfbd65..4d5235cd2e8 100644
--- a/TAO/TAO_IDL/be/be_visitor_operation/rettype_post_docall_cs.cpp
+++ b/TAO/TAO_IDL/be/be_visitor_operation/rettype_post_docall_cs.cpp
@@ -48,9 +48,15 @@ int
be_visitor_operation_rettype_post_docall_cs::visit_interface (be_interface *node)
{
TAO_OutStream *os = this->ctx_->stream (); // grab the out stream
+ be_type *bt; // return type
+
+ if (this->ctx_->alias ()) // a typedefed return type
+ bt = this->ctx_->alias ();
+ else
+ bt = node;
os->indent ();
- *os << "_tao_retval = " << node->name ()
+ *os << "_tao_retval = " << bt->name ()
<< "::_narrow (_tao_base_retval, _tao_environment);" << be_nl;
*os << "CORBA::release (_tao_base_retval);\n";
return 0;
@@ -61,9 +67,15 @@ be_visitor_operation_rettype_post_docall_cs::
visit_interface_fwd (be_interface_fwd *node)
{
TAO_OutStream *os = this->ctx_->stream (); // grab the out stream
+ be_type *bt; // return type
+
+ if (this->ctx_->alias ()) // a typedefed return type
+ bt = this->ctx_->alias ();
+ else
+ bt = node;
os->indent ();
- *os << "_tao_retval = " << node->name ()
+ *os << "_tao_retval = " << bt->name ()
<< "::_narrow (_tao_base_retval, _tao_environment);" << be_nl;
*os << "CORBA::release (_tao_base_retval);\n";
return 0;
diff --git a/TAO/TAO_IDL/be/be_visitor_operation/rettype_pre_docall_cs.cpp b/TAO/TAO_IDL/be/be_visitor_operation/rettype_pre_docall_cs.cpp
index 73ac0632b3e..c6e82de1e74 100644
--- a/TAO/TAO_IDL/be/be_visitor_operation/rettype_pre_docall_cs.cpp
+++ b/TAO/TAO_IDL/be/be_visitor_operation/rettype_pre_docall_cs.cpp
@@ -48,9 +48,15 @@ int
be_visitor_operation_rettype_pre_docall_cs::visit_array (be_array *node)
{
TAO_OutStream *os = this->ctx_->stream (); // grab the out stream
+ be_type *bt; // return type
+
+ if (this->ctx_->alias ()) // a typedefed return type
+ bt = this->ctx_->alias ();
+ else
+ bt = node;
os->indent ();
- *os << "ACE_ALLOCATOR_RETURN (_tao_retval, " << node->name ()
+ *os << "ACE_ALLOCATOR_RETURN (_tao_retval, " << bt->name ()
<< "_alloc (), _tao_retval);\n";
return 0;
}
@@ -97,9 +103,15 @@ int
be_visitor_operation_rettype_pre_docall_cs::visit_sequence (be_sequence *node)
{
TAO_OutStream *os = this->ctx_->stream (); // grab the out stream
+ be_type *bt; // return type
+
+ if (this->ctx_->alias ()) // a typedefed return type
+ bt = this->ctx_->alias ();
+ else
+ bt = node;
os->indent ();
- *os << "ACE_NEW_RETURN (_tao_retval, " << node->name () << ", _tao_retval);\n";
+ *os << "ACE_NEW_RETURN (_tao_retval, " << bt->name () << ", _tao_retval);\n";
return 0;
}
@@ -107,12 +119,18 @@ int
be_visitor_operation_rettype_pre_docall_cs::visit_structure (be_structure *node)
{
TAO_OutStream *os = this->ctx_->stream (); // grab the out stream
+ be_type *bt; // return type
+
+ if (this->ctx_->alias ()) // a typedefed return type
+ bt = this->ctx_->alias ();
+ else
+ bt = node;
// check if the union is variable
if (node->size_type () == be_type::VARIABLE)
{
os->indent ();
- *os << "ACE_NEW_RETURN (_tao_retval, " << node->name () << ", _tao_retval);\n";
+ *os << "ACE_NEW_RETURN (_tao_retval, " << bt->name () << ", _tao_retval);\n";
}
return 0;
}
@@ -137,12 +155,18 @@ int
be_visitor_operation_rettype_pre_docall_cs::visit_union (be_union *node)
{
TAO_OutStream *os = this->ctx_->stream (); // grab the out stream
+ be_type *bt; // return type
+
+ if (this->ctx_->alias ()) // a typedefed return type
+ bt = this->ctx_->alias ();
+ else
+ bt = node;
// check if the union is variable
if (node->size_type () == be_type::VARIABLE)
{
os->indent ();
- *os << "ACE_NEW_RETURN (_tao_retval, " << node->name () << ", _tao_retval);\n";
+ *os << "ACE_NEW_RETURN (_tao_retval, " << bt->name () << ", _tao_retval);\n";
}
return 0;
}