summaryrefslogtreecommitdiff
path: root/TAO/TAO_IDL/be/be_typedef.cpp
diff options
context:
space:
mode:
authorgokhale <gokhale@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1997-12-10 19:44:50 +0000
committergokhale <gokhale@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1997-12-10 19:44:50 +0000
commit224ae3282f9aac759dbfa07c59fcb6a86363b72d (patch)
treeb8fe05c28ebf90babb27c47e96eb180f5012383a /TAO/TAO_IDL/be/be_typedef.cpp
parent8a7cf38481931c39d7598b8988a4c58a283d76e7 (diff)
downloadATCD-224ae3282f9aac759dbfa07c59fcb6a86363b72d.tar.gz
*** empty log message ***
Diffstat (limited to 'TAO/TAO_IDL/be/be_typedef.cpp')
-rw-r--r--TAO/TAO_IDL/be/be_typedef.cpp27
1 files changed, 17 insertions, 10 deletions
diff --git a/TAO/TAO_IDL/be/be_typedef.cpp b/TAO/TAO_IDL/be/be_typedef.cpp
index e02ecaf0bbc..43640de7ce3 100644
--- a/TAO/TAO_IDL/be/be_typedef.cpp
+++ b/TAO/TAO_IDL/be/be_typedef.cpp
@@ -62,10 +62,6 @@ be_typedef::gen_client_header (void)
TAO_CodeGen *cg = TAO_CODEGEN::instance ();
ch = cg->client_header ();
cg->push (TAO_CodeGen::TAO_TYPEDEF_CH);
- cg->node (this); // pass ourselves. For typedefs, this is very important,
- // because other nodes's code generation may depend on
- // whether they were typedefed or not.
- cg->outstream (cg->client_header ());
s = cg->make_state ();
bt = be_type::narrow_from_decl (this->base_type ());
@@ -115,10 +111,6 @@ be_typedef::gen_client_stubs (void)
cs = cg->client_stubs ();
- cg->node (this); // pass ourselves. For typedefs, this is very important,
- // because other nodes's code generation may depend on
- // whether they were typedefed or not.
-
s = cg->make_state ();
bt = be_type::narrow_from_decl (this->base_type ());
@@ -171,8 +163,6 @@ be_typedef::gen_client_inline (void)
// retrieve a singleton instance of the code generator
TAO_CodeGen *cg = TAO_CODEGEN::instance ();
cg->push (TAO_CodeGen::TAO_TYPEDEF_CI);
- cg->node (this); // pass ourselves
- cg->outstream (cg->client_inline ());
s = cg->make_state ();
bt = be_type::narrow_from_decl (this->base_type ());
@@ -311,6 +301,23 @@ be_typedef::tc_encap_len (void)
return this->encap_len_;
}
+// compute the size type of the node in question
+int
+be_typedef::compute_size_type (void)
+{
+ be_type *type = be_type::narrow_from_decl (this->base_type ());
+ if (!type)
+ {
+ ACE_ERROR_RETURN ((LM_ERROR,
+ "(%N:%l) be_typedef::compute_size_type - "
+ "bad base type\n"), -1);
+ }
+
+ // our size type is the same as our type
+ this->size_type (type->size_type ());
+ return 0;
+}
+
// Narrowing
IMPL_NARROW_METHODS2 (be_typedef, AST_Typedef, be_type)
IMPL_NARROW_FROM_DECL (be_typedef)