summaryrefslogtreecommitdiff
path: root/TAO/TAO_IDL/be/be_visitor_structure
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/TAO_IDL/be/be_visitor_structure')
-rw-r--r--TAO/TAO_IDL/be/be_visitor_structure/any_op_ch.cpp102
-rw-r--r--TAO/TAO_IDL/be/be_visitor_structure/any_op_cs.cpp171
-rw-r--r--TAO/TAO_IDL/be/be_visitor_structure/cdr_op_ch.cpp77
-rw-r--r--TAO/TAO_IDL/be/be_visitor_structure/cdr_op_cs.cpp150
-rw-r--r--TAO/TAO_IDL/be/be_visitor_structure/structure.cpp107
-rw-r--r--TAO/TAO_IDL/be/be_visitor_structure/structure_ch.cpp117
-rw-r--r--TAO/TAO_IDL/be/be_visitor_structure/structure_ci.cpp74
-rw-r--r--TAO/TAO_IDL/be/be_visitor_structure/structure_cs.cpp77
8 files changed, 0 insertions, 875 deletions
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
deleted file mode 100644
index 34b3f3210d3..00000000000
--- a/TAO/TAO_IDL/be/be_visitor_structure/any_op_ch.cpp
+++ /dev/null
@@ -1,102 +0,0 @@
-//
-// $Id$
-//
-
-// ============================================================================
-//
-// = LIBRARY
-// TAO IDL
-//
-// = FILENAME
-// any_op_ch.cpp
-//
-// = DESCRIPTION
-// Visitor generating code for Any operators for structures
-//
-// = AUTHOR
-// Aniruddha Gokhale
-//
-// ============================================================================
-
-#include "idl.h"
-#include "idl_extern.h"
-#include "be.h"
-
-#include "be_visitor_structure.h"
-
-ACE_RCSID(be_visitor_structure, any_op_ch, "$Id$")
-
-
-// ***************************************************************************
-// Structure visitor for generating Any operator declarations in the client header
-// ***************************************************************************
-
-be_visitor_structure_any_op_ch::be_visitor_structure_any_op_ch
-(be_visitor_context *ctx)
- : be_visitor_structure (ctx)
-{
-}
-
-be_visitor_structure_any_op_ch::~be_visitor_structure_any_op_ch (void)
-{
-}
-
-int
-be_visitor_structure_any_op_ch::visit_structure (be_structure *node)
-{
- if (node->cli_hdr_any_op_gen () || node->imported ())
- return 0;
-
- TAO_OutStream *os = this->ctx_->stream ();
-
- // generate the Any <<= and >>= operator declarations
- os->indent ();
- *os << "void " << idl_global->export_macro ()
- << " operator<<= (CORBA::Any &, const " << node->name ()
- << " &); // copying version" << be_nl;
- *os << "void " << idl_global->export_macro ()
- << " operator<<= (CORBA::Any &, " << node->name ()
- << "*); // noncopying version" << be_nl;
- *os << "CORBA::Boolean " << idl_global->export_macro ()
- << " operator>>= (const CORBA::Any &, "
- << node->name () << " *&);\n";
-
-
- // all we have to do is to visit the scope and generate code
- if (this->visit_scope (node) == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure::visit_structure - "
- "codegen for scope failed\n"), -1);
- }
-
- node->cli_hdr_any_op_gen (1);
- return 0;
-}
-
-int
-be_visitor_structure_any_op_ch::visit_field (be_field *node)
-{
- be_type *bt; // field's type
-
- // first generate the type information
- bt = be_type::narrow_from_decl (node->field_type ());
- if (!bt)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_any_op_ch::"
- "visit_field - "
- "Bad field type\n"
- ), -1);
- }
-
- if (bt->accept (this) == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_any_op_ch::"
- "visit_field - "
- "codegen for field type failed\n"
- ), -1);
- }
- return 0;
-}
diff --git a/TAO/TAO_IDL/be/be_visitor_structure/any_op_cs.cpp b/TAO/TAO_IDL/be/be_visitor_structure/any_op_cs.cpp
deleted file mode 100644
index 8bc890ea686..00000000000
--- a/TAO/TAO_IDL/be/be_visitor_structure/any_op_cs.cpp
+++ /dev/null
@@ -1,171 +0,0 @@
-//
-// $Id$
-//
-
-// ============================================================================
-//
-// = LIBRARY
-// TAO IDL
-//
-// = FILENAME
-// any_op_cs.cpp
-//
-// = DESCRIPTION
-// Visitor generating code for Any operators for structures
-//
-// = AUTHOR
-// Aniruddha Gokhale
-//
-// ============================================================================
-
-#include "idl.h"
-#include "idl_extern.h"
-#include "be.h"
-
-#include "be_visitor_structure.h"
-
-ACE_RCSID(be_visitor_structure, any_op_cs, "$Id$")
-
-
-// ***************************************************************************
-// Structure visitor for generating Any operator declarations in the client
-// stubs file
-// ***************************************************************************
-
-be_visitor_structure_any_op_cs::be_visitor_structure_any_op_cs
-(be_visitor_context *ctx)
- : be_visitor_structure (ctx)
-{
-}
-
-be_visitor_structure_any_op_cs::~be_visitor_structure_any_op_cs (void)
-{
-}
-
-int
-be_visitor_structure_any_op_cs::visit_structure (be_structure *node)
-{
- if (node->cli_stub_any_op_gen () || node->imported ())
- return 0;
-
- TAO_OutStream *os = this->ctx_->stream ();
-
- // generate the Any <<= and >>= operator declarations
- // Any <<= and >>= operators
- os->indent ();
- *os << "void operator<<= (CORBA::Any &_tao_any, const "
- << node->name () << " &_tao_elem) // copying" << be_nl
- << "{" << be_idt_nl
- << node->name () << " *_any_val;" << be_nl
- << "ACE_NEW (_any_val, " << node->name () << " (_tao_elem));" << be_nl
- << "if (!_any_val) return;" << be_nl
- << "ACE_TRY_NEW_ENV" << be_nl
- << "{" << be_idt_nl
- << "_tao_any.replace (" << node->tc_name ()
- << ", _any_val, 1, ACE_TRY_ENV);" << " // copy the value" << be_nl
- << "ACE_TRY_CHECK;" << be_uidt_nl
- << "}" << be_nl
- << "ACE_CATCHANY" << be_nl
- << "{" << be_idt_nl
- << "delete _any_val;" << be_uidt_nl
- << "}" << be_nl
- << "ACE_ENDTRY;" << be_uidt_nl
- << "}\n" << be_nl;
-
- *os << "void operator<<= (CORBA::Any &_tao_any, "
- << node->name () << " *_tao_elem) // non copying" << be_nl
- << "{" << be_idt_nl
- << "ACE_TRY_NEW_ENV" << be_nl
- << "{" << be_idt_nl
- << "_tao_any.replace (" << node->tc_name () << ", "
- << "_tao_elem, 1, ACE_TRY_ENV); // consume it" << be_nl
- << "ACE_TRY_CHECK;" << be_uidt_nl
- << "}" << be_nl
- << "ACE_CATCHANY {}" << be_nl
- << "ACE_ENDTRY;" << be_uidt_nl
- << "}\n" << be_nl;
-
- *os << "CORBA::Boolean operator>>= (const CORBA::Any &_tao_any, "
- << node->name () << " *&_tao_elem)" << be_nl
- << "{" << be_idt_nl
- << "ACE_TRY_NEW_ENV" << be_nl
- << "{" << be_idt_nl
- << "CORBA::TypeCode_var type = _tao_any.type ();" << be_nl
- << "if (!type->equal (" << node->tc_name ()
- << ", ACE_TRY_ENV)) return 0; // not equal" << be_nl
- << "ACE_TRY_CHECK;" << be_nl
- << "if (_tao_any.any_owns_data ())" << be_nl
- << "{" << be_idt_nl
- << "_tao_elem = (" << node->name () << " *)_tao_any.value ();"
- << be_nl
- << "return 1;" << be_nl
- << "}" << be_uidt_nl
- << "else" << be_nl // else any does not own the data
- << "{" << be_idt_nl
- << "ACE_NEW_RETURN (_tao_elem, " << node->name () << ", 0);"
- << be_nl
- << "TAO_InputCDR stream (_tao_any._tao_get_cdr ());"
- << be_nl
- << "if (stream.decode (" << node->tc_name ()
- << ", _tao_elem, 0, ACE_TRY_ENV)" << be_nl
- << " == CORBA::TypeCode::TRAVERSE_CONTINUE)" << be_nl
- << "{" << be_idt_nl
- << "((CORBA::Any *)&_tao_any)->replace ("
- << node->tc_name () << ", _tao_elem, 1, ACE_TRY_ENV);" << be_nl
- << "ACE_TRY_CHECK;" << be_nl
- << "return 1;" << be_uidt_nl
- << "}" << be_nl
- << "else" << be_nl
- << "{" << be_idt_nl
- << "delete _tao_elem;" << be_uidt_nl
- << "}" << be_uidt_nl
- << "}" << be_uidt_nl
- << "}" << be_nl
- << "ACE_CATCHANY" << be_nl
- << "{" << be_idt_nl
- << "delete _tao_elem;" << be_nl
- << "return 0; " << be_uidt_nl
- << "}" << be_nl
- << "ACE_ENDTRY;" << be_nl
- << "return 0;" << be_uidt_nl
- << "}\n\n";
-
-
- // all we have to do is to visit the scope and generate code
- if (this->visit_scope (node) == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure::visit_structure - "
- "codegen for scope failed\n"), -1);
- }
-
- node->cli_stub_any_op_gen (1);
- return 0;
-}
-
-int
-be_visitor_structure_any_op_cs::visit_field (be_field *node)
-{
- be_type *bt; // field's type
-
- // first generate the type information
- bt = be_type::narrow_from_decl (node->field_type ());
- if (!bt)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_any_op_cs::"
- "visit_field - "
- "Bad field type\n"
- ), -1);
- }
-
- if (bt->accept (this) == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_any_op_cs::"
- "visit_field - "
- "codegen for field type failed\n"
- ), -1);
- }
- return 0;
-}
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
deleted file mode 100644
index 337601a11d5..00000000000
--- a/TAO/TAO_IDL/be/be_visitor_structure/cdr_op_ch.cpp
+++ /dev/null
@@ -1,77 +0,0 @@
-//
-// $Id$
-//
-
-// ============================================================================
-//
-// = LIBRARY
-// TAO IDL
-//
-// = FILENAME
-// cdr_op_ch.cpp
-//
-// = DESCRIPTION
-// Visitor generating code for CDR operators for structures. This uses
-// compiled marshaling.
-//
-// = AUTHOR
-// Aniruddha Gokhale
-//
-// ============================================================================
-
-#include "idl.h"
-#include "idl_extern.h"
-#include "be.h"
-
-#include "be_visitor_structure.h"
-
-ACE_RCSID(be_visitor_structure, cdr_op_ch, "$Id$")
-
-// ***************************************************************************
-// Structure visitor for generating CDR operator declarations in the client header
-// ***************************************************************************
-
-be_visitor_structure_cdr_op_ch::be_visitor_structure_cdr_op_ch
-(be_visitor_context *ctx)
- : be_visitor_structure (ctx)
-{
-}
-
-be_visitor_structure_cdr_op_ch::~be_visitor_structure_cdr_op_ch (void)
-{
-}
-
-int
-be_visitor_structure_cdr_op_ch::visit_structure (be_structure *node)
-{
- if (node->cli_hdr_cdr_op_gen () || node->imported ())
- return 0;
-
- TAO_OutStream *os = this->ctx_->stream ();
-
- // generate the CDR << and >> operator declarations
- os->indent ();
- *os << "CORBA::Boolean " << idl_global->export_macro ()
- << " operator<< (TAO_OutputCDR &, const " << node->name ()
- << " &); // " << be_nl;
- *os << "CORBA::Boolean " << idl_global->export_macro ()
- << " operator>> (TAO_InputCDR &, "
- << node->name () << " &);\n";
-
-
- // set the substate as generating code for the types defined in our scope
- this->ctx_->sub_state(TAO_CodeGen::TAO_CDR_SCOPE);
- // all we have to do is to visit the scope and generate code
- if (this->visit_scope (node) == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_cdr_op_ch::"
- "visit_structure - "
- "codegen for scope failed\n"), -1);
- }
-
-
- node->cli_hdr_cdr_op_gen (1);
- return 0;
-}
-
diff --git a/TAO/TAO_IDL/be/be_visitor_structure/cdr_op_cs.cpp b/TAO/TAO_IDL/be/be_visitor_structure/cdr_op_cs.cpp
deleted file mode 100644
index f6a9e2fe1a8..00000000000
--- a/TAO/TAO_IDL/be/be_visitor_structure/cdr_op_cs.cpp
+++ /dev/null
@@ -1,150 +0,0 @@
-//
-// $Id$
-//
-
-// ============================================================================
-//
-// = LIBRARY
-// TAO IDL
-//
-// = FILENAME
-// cdr_op_cs.cpp
-//
-// = DESCRIPTION
-// Visitor generating code for CDR operators for structures
-//
-// = AUTHOR
-// Aniruddha Gokhale
-//
-// ============================================================================
-
-#include "idl.h"
-#include "idl_extern.h"
-#include "be.h"
-
-#include "be_visitor_structure.h"
-#include "be_visitor_field.h"
-
-ACE_RCSID(be_visitor_structure, cdr_op_cs, "$Id$")
-
-// ***************************************************************************
-// Structure visitor for generating CDR operator declarations in the client
-// stubs file
-// ***************************************************************************
-
-be_visitor_structure_cdr_op_cs::be_visitor_structure_cdr_op_cs
-(be_visitor_context *ctx)
- : be_visitor_structure (ctx)
-{
-}
-
-be_visitor_structure_cdr_op_cs::~be_visitor_structure_cdr_op_cs (void)
-{
-}
-
-int
-be_visitor_structure_cdr_op_cs::visit_structure (be_structure *node)
-{
- // already generated and/or we are imported. Don't do anything.
- if (node->cli_stub_cdr_op_gen () || node->imported ())
- return 0;
-
- TAO_OutStream *os = this->ctx_->stream ();
-
- // First generate code for our children. The reason we do this first is
- // because the inlined code for our children must be available before we use
- // it in our parent
-
- // set the substate as generating code for the types defined in our scope
- this->ctx_->sub_state(TAO_CodeGen::TAO_CDR_SCOPE);
- // all we have to do is to visit the scope and generate code
- if (this->visit_scope (node) == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_cdr_op_cs"
- "::visit_structure - "
- "codegen for scope failed\n"), -1);
- }
-
- // set the sub state as generating code for the output operator
- this->ctx_->sub_state(TAO_CodeGen::TAO_CDR_OUTPUT);
- *os << "ACE_INLINE CORBA::Boolean operator<< (TAO_OutputCDR &strm, "
- << "const " << node->name () << " &_tao_aggregate)" << be_nl
- << "{" << be_idt_nl;
-
- {
- be_visitor_context* new_ctx =
- new be_visitor_context (*this->ctx_);
- be_visitor_cdr_op_field_decl field_decl (new_ctx);
- field_decl.visit_scope (node);
- }
- *os << "if (" << be_idt_nl;
-
- // all we have to do is to visit the scope and generate code
- if (this->visit_scope (node) == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_cdr_op_cs::"
- "visit_structure - "
- "codegen for scope failed\n"), -1);
- }
- *os << be_uidt_nl << ")"
- << be_idt_nl
- << "return 1;" << be_uidt_nl
- << "else" << be_idt_nl
- << "return 0;" << be_uidt_nl << be_uidt_nl
- << "}\n\n";
-
- // set the substate as generating code for the input operator
- this->ctx_->sub_state(TAO_CodeGen::TAO_CDR_INPUT);
- *os << "ACE_INLINE CORBA::Boolean operator>> (TAO_InputCDR &strm, "
- << node->name () << " &_tao_aggregate)" << be_nl
- << "{" << be_idt_nl;
-
- {
- be_visitor_context* new_ctx =
- new be_visitor_context (*this->ctx_);
- be_visitor_cdr_op_field_decl field_decl (new_ctx);
- field_decl.visit_scope (node);
- }
- *os << "if (" << be_idt_nl;
-
- // all we have to do is to visit the scope and generate code
- if (this->visit_scope (node) == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_cdr_op_cs"
- "::visit_structure - "
- "codegen for scope failed\n"), -1);
- }
- *os << be_uidt_nl << ")"
- << be_idt_nl
- << "return 1;" << be_uidt_nl
- << "else" << be_idt_nl
- << "return 0;" << be_uidt_nl << be_uidt_nl
- << "}\n\n";
-
- node->cli_stub_cdr_op_gen (1);
- return 0;
-}
-
-int
-be_visitor_structure_cdr_op_cs::post_process (be_decl *bd)
-{
- TAO_OutStream *os = this->ctx_->stream ();
-
- if (!this->last_node (bd))
- {
- switch (this->ctx_->sub_state ())
- {
- case TAO_CodeGen::TAO_CDR_OUTPUT:
- case TAO_CodeGen::TAO_CDR_INPUT:
- *os << " &&" << be_nl;
- break;
- case TAO_CodeGen::TAO_CDR_SCOPE:
- default:
- break;
- };
- }
- return 0;
-}
diff --git a/TAO/TAO_IDL/be/be_visitor_structure/structure.cpp b/TAO/TAO_IDL/be/be_visitor_structure/structure.cpp
deleted file mode 100644
index c4386dafcff..00000000000
--- a/TAO/TAO_IDL/be/be_visitor_structure/structure.cpp
+++ /dev/null
@@ -1,107 +0,0 @@
-//
-// $Id$
-//
-
-// ============================================================================
-//
-// = LIBRARY
-// TAO IDL
-//
-// = FILENAME
-// structure.cpp
-//
-// = DESCRIPTION
-// Visitor generating code for Structures. This is a generic visitor.
-//
-// = AUTHOR
-// Aniruddha Gokhale
-//
-// ============================================================================
-
-#include "idl.h"
-#include "idl_extern.h"
-#include "be.h"
-
-#include "be_visitor_structure.h"
-
-ACE_RCSID(be_visitor_structure, structure, "$Id$")
-
-
-// generic struct visitor
-be_visitor_structure::be_visitor_structure (be_visitor_context *ctx)
- : be_visitor_scope (ctx)
-{
-}
-
-be_visitor_structure::~be_visitor_structure (void)
-{
-}
-
-// visit the Structure node and its scope
-int
-be_visitor_structure::visit_structure (be_structure *)
-{
- return -1; // must be overriden
-}
-
-int
-be_visitor_structure::visit_field (be_field *node)
-{
- // instantiate a visitor context with a copy of our context. This info
- // will be modified based on what type of node we are visiting
- be_visitor_context ctx (*this->ctx_);
- ctx.node (node); // set the node to be the node being visited. The scope is
- // still the same
-
- // this switch is acceptable rather than having derived visitors overriding
- // this method and differing only in what state they set
-
- switch (this->ctx_->state ())
- {
- case TAO_CodeGen::TAO_STRUCT_CH:
- ctx.state (TAO_CodeGen::TAO_FIELD_CH);
- break;
- case TAO_CodeGen::TAO_STRUCT_CI:
- ctx.state (TAO_CodeGen::TAO_FIELD_CI);
- break;
- case TAO_CodeGen::TAO_STRUCT_CS:
- ctx.state (TAO_CodeGen::TAO_FIELD_CS);
- break;
- case TAO_CodeGen::TAO_STRUCT_CDR_OP_CH:
- ctx.state (TAO_CodeGen::TAO_FIELD_CDR_OP_CH);
- break;
- case TAO_CodeGen::TAO_STRUCT_CDR_OP_CS:
- ctx.state (TAO_CodeGen::TAO_FIELD_CDR_OP_CS);
- break;
- default:
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure::"
- "visit_field - "
- "Bad context state\n"
- ), -1);
- }
- }
-
- be_visitor *visitor = tao_cg->make_visitor (&ctx);
- if (!visitor)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure::"
- "visit_field - "
- "NUL visitor\n"
- ), -1);
- }
-
- // let the node accept this visitor
- if (node->accept (visitor) == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure::"
- "visit_field - "
- "failed to accept visitor\n"
- ), -1);
- }
- delete visitor;
- return 0;
-}
diff --git a/TAO/TAO_IDL/be/be_visitor_structure/structure_ch.cpp b/TAO/TAO_IDL/be/be_visitor_structure/structure_ch.cpp
deleted file mode 100644
index f9ce9cb68e2..00000000000
--- a/TAO/TAO_IDL/be/be_visitor_structure/structure_ch.cpp
+++ /dev/null
@@ -1,117 +0,0 @@
-//
-// $Id$
-//
-
-// ============================================================================
-//
-// = LIBRARY
-// TAO IDL
-//
-// = FILENAME
-// structure_ch.cpp
-//
-// = DESCRIPTION
-// Visitor generating code for Structure in the client header.
-//
-// = AUTHOR
-// Aniruddha Gokhale
-//
-// ============================================================================
-
-#include "idl.h"
-#include "idl_extern.h"
-#include "be.h"
-
-#include "be_visitor_structure.h"
-
-ACE_RCSID(be_visitor_structure, structure_ch, "$Id$")
-
-
-// ******************************************************
-// for client header
-// ******************************************************
-
-be_visitor_structure_ch::be_visitor_structure_ch (be_visitor_context *ctx)
- : be_visitor_structure (ctx)
-{
-}
-
-be_visitor_structure_ch::~be_visitor_structure_ch (void)
-{
-}
-
-// visit the Structure node and its scope
-int be_visitor_structure_ch::visit_structure (be_structure *node)
-{
- TAO_OutStream *os; // output stream
-
- if (!node->cli_hdr_gen () && !node->imported ()) // not already generated and
- // not imported
- {
- os = this->ctx_->stream ();
-
- os->indent (); // start from whatever indentation level we were at
- *os << "struct " << idl_global->export_macro () << " "
- << node->local_name () << be_nl
- << "{" << be_idt << "\n";
-
- // generate code for field members
- if (this->visit_scope (node) == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_ch::"
- "visit_structure - "
- "codegen for scope failed\n"), -1);
- }
-
- os->decr_indent ();
- *os << "};\n\n";
-
- // generate var defn
- if (node->gen_var_defn () == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_ch::"
- "visit_structure - "
- "codegen for _var failed\n"), -1);
- }
-
- // a class is generated for an out defn only for a variable length struct
- if (node->size_type () == be_decl::VARIABLE)
- {
- if (node->gen_out_defn () == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_ch::"
- "visit_structure - "
- "codegen for _out failed\n"), -1);
- }
- }
- else
- {
- os->indent ();
- *os << "typedef " << node->local_name () << " &" << node->local_name
- () << "_out;\n\n";
- }
-
- // 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
- be_visitor *visitor;
- be_visitor_context ctx (*this->ctx_);
- ctx.state (TAO_CodeGen::TAO_TYPECODE_DECL);
- visitor = tao_cg->make_visitor (&ctx);
- if (!visitor || (node->accept (visitor) == -1))
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_ch::"
- "visit_structure - "
- "TypeCode declaration failed\n"
- ), -1);
- }
-
-
- node->cli_hdr_gen (I_TRUE);
- }
- return 0;
-}
diff --git a/TAO/TAO_IDL/be/be_visitor_structure/structure_ci.cpp b/TAO/TAO_IDL/be/be_visitor_structure/structure_ci.cpp
deleted file mode 100644
index 8271008eb2b..00000000000
--- a/TAO/TAO_IDL/be/be_visitor_structure/structure_ci.cpp
+++ /dev/null
@@ -1,74 +0,0 @@
-//
-// $Id$
-//
-
-// ============================================================================
-//
-// = LIBRARY
-// TAO IDL
-//
-// = FILENAME
-// structure_ci.cpp
-//
-// = DESCRIPTION
-// Visitor generating code for Structure in the inline file.
-//
-// = AUTHOR
-// Aniruddha Gokhale
-//
-// ============================================================================
-
-#include "idl.h"
-#include "idl_extern.h"
-#include "be.h"
-
-#include "be_visitor_structure.h"
-
-ACE_RCSID(be_visitor_structure, structure_ci, "$Id$")
-
-
-// ******************************************************
-// for client inline
-// ******************************************************
-
-be_visitor_structure_ci::be_visitor_structure_ci (be_visitor_context *ctx)
- : be_visitor_structure (ctx)
-{
-}
-
-be_visitor_structure_ci::~be_visitor_structure_ci (void)
-{
-}
-
-// visit the Structure node and its scope
-int be_visitor_structure_ci::visit_structure (be_structure *node)
-{
- if (!node->cli_inline_gen () && !node->imported ())
- {
- if (node->gen_var_impl () == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_ci::"
- "visit_structure - "
- "codegen for _var failed\n"), -1);
- }
- if (node->size_type () == be_decl::VARIABLE &&
- node->gen_out_impl () == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_ci::"
- "visit_structure - "
- "codegen for _out failed\n"), -1);
- }
- // all we have to do is to visit the scope
- if (this->visit_scope (node) == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_ci::"
- "visit_structure - "
- "codegen for scope failed\n"), -1);
- }
- node->cli_inline_gen (I_TRUE);
- }
- return 0;
-}
diff --git a/TAO/TAO_IDL/be/be_visitor_structure/structure_cs.cpp b/TAO/TAO_IDL/be/be_visitor_structure/structure_cs.cpp
deleted file mode 100644
index 8ab877e8f35..00000000000
--- a/TAO/TAO_IDL/be/be_visitor_structure/structure_cs.cpp
+++ /dev/null
@@ -1,77 +0,0 @@
-//
-// $Id$
-//
-
-// ============================================================================
-//
-// = LIBRARY
-// TAO IDL
-//
-// = FILENAME
-// structure_cs.cpp
-//
-// = DESCRIPTION
-// Visitor generating code for Structures in the client stubs file.
-//
-// = AUTHOR
-// Aniruddha Gokhale
-//
-// ============================================================================
-
-#include "idl.h"
-#include "idl_extern.h"
-#include "be.h"
-
-#include "be_visitor_structure.h"
-
-ACE_RCSID(be_visitor_structure, structure_cs, "$Id$")
-
-
-// ***************************************************************************
-// for client stubs
-// ***************************************************************************
-be_visitor_structure_cs::be_visitor_structure_cs (be_visitor_context *ctx)
- : be_visitor_structure (ctx)
-{
-}
-
-be_visitor_structure_cs::~be_visitor_structure_cs (void)
-{
-}
-
-// visit the Structure_Cs node and its scope
-int be_visitor_structure_cs::visit_structure (be_structure *node)
-{
- if (!node->cli_stub_gen () && !node->imported ())
- {
- // 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
- be_visitor *visitor;
- be_visitor_context ctx (*this->ctx_);
- ctx.state (TAO_CodeGen::TAO_TYPECODE_DEFN);
- visitor = tao_cg->make_visitor (&ctx);
- if (!visitor || (node->accept (visitor) == -1))
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_cs::"
- "visit_structure - "
- "TypeCode definition failed\n"
- ), -1);
- }
-
-
- // do any code generation required for the scope members
- // all we have to do is to visit the scope
- if (this->visit_scope (node) == -1)
- {
- ACE_ERROR_RETURN ((LM_ERROR,
- "(%N:%l) be_visitor_structure_cs::"
- "visit_structure - "
- "codegen for scope failed\n"), -1);
- }
- node->cli_stub_gen (I_TRUE);
- }
-
- return 0;
-}