summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorparsons <parsons@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2010-04-09 12:51:15 +0000
committerparsons <parsons@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2010-04-09 12:51:15 +0000
commitc6402405812f590d27523491fcae35503c4033b9 (patch)
tree4fcfa53a91868037d42f086652b5435973f88196
parentfab1cd1fae21597b05bedd61f742b2c6c105ed90 (diff)
downloadATCD-c6402405812f590d27523491fcae35503c4033b9.tar.gz
ChangeLogTag: Fri Apr 9 12:45:17 UTC 2010 Jeff Parsons <j.parsons@vanderbilt.edu>
-rw-r--r--TAO/ChangeLog23
-rw-r--r--TAO/TAO_IDL/be/be_component.cpp23
-rw-r--r--TAO/TAO_IDL/be/be_visitor_attribute/component_init.cpp3
-rw-r--r--TAO/TAO_IDL/be/be_visitor_component/servant_svh.cpp2
-rw-r--r--TAO/TAO_IDL/be/be_visitor_component/servant_svs.cpp2
-rw-r--r--TAO/TAO_IDL/be_include/be_component.h4
6 files changed, 45 insertions, 12 deletions
diff --git a/TAO/ChangeLog b/TAO/ChangeLog
index d12a8371683..d89435b212c 100644
--- a/TAO/ChangeLog
+++ b/TAO/ChangeLog
@@ -1,3 +1,26 @@
+Fri Apr 9 12:45:17 UTC 2010 Jeff Parsons <j.parsons@vanderbilt.edu>
+
+ * TAO_IDL/be_include/be_component.h:
+ * TAO_IDL/be/be_component_cpp:
+
+ Changed 'has_attribute_' member to 'has_rw_attribute_'
+ to indicate presence of read-write attribute only, since
+ these attributes are the only ones of interest. Also
+ changed accessor method names accordingly.
+
+ * TAO_IDL/be/be_visitor_component/servant_svh.cpp:
+ * TAO_IDL/be/be_visitor_component/servant_svs.cpp:
+
+ Modified to use the new accessor names above.
+
+ * TAO_IDL/be/be_visitor_attribute/component_init.cpp:
+
+ Added 'ACE_UNUSED_ARG' macro in the generated code block
+ that outputs an error if an attribute type is not
+ supported. In this case, the attribute description name
+ variable is used, but the corresponding value variable
+ is not.
+
Fri Apr 9 08:47:25 UTC 2010 Johnny Willemsen <jwillemsen@remedy.nl>
* TAO_IDL/be/be_visitor_attribute/component_init.cpp:
diff --git a/TAO/TAO_IDL/be/be_component.cpp b/TAO/TAO_IDL/be/be_component.cpp
index fc6f454d1ba..f5308de0f95 100644
--- a/TAO/TAO_IDL/be/be_component.cpp
+++ b/TAO/TAO_IDL/be/be_component.cpp
@@ -18,6 +18,7 @@
#include "ast_mirror_port.h"
#include "ast_uses.h"
+#include "ast_attribute.h"
#include "global_extern.h"
#include "utl_err.h"
@@ -66,7 +67,7 @@ be_component::be_component (UTL_ScopedName *n,
has_publishes_ (false),
has_consumes_ (false),
has_emits_ (false),
- has_attributes_ (false)
+ has_rw_attributes_ (false)
{
this->size_type (AST_Type::VARIABLE);
this->has_constructor (true);
@@ -156,9 +157,9 @@ be_component::has_emits (void)
}
bool
-be_component::has_attributes (void)
+be_component::has_rw_attributes (void)
{
- return this->has_attributes_;
+ return this->has_rw_attributes_;
}
IMPL_NARROW_FROM_DECL (be_component)
@@ -172,14 +173,16 @@ be_component::scan (UTL_Scope *s)
return;
}
+ AST_Extended_Port *ep = 0;
+ AST_Mirror_Port *mp = 0;
+ AST_Uses *u = 0;
+ AST_Attribute *a = 0;
+
for (UTL_ScopeActiveIterator i (s, UTL_Scope::IK_both);
!i.is_done ();
i.next ())
{
AST_Decl *d = i.item ();
- AST_Extended_Port *ep = 0;
- AST_Mirror_Port *mp = 0;
- AST_Uses *u = 0;
switch (d->node_type ())
{
@@ -214,7 +217,13 @@ be_component::scan (UTL_Scope *s)
this->mirror_scan (mp->port_type ());
continue;
case AST_Decl::NT_attr:
- this->has_attributes_ = true;
+ a = AST_Attribute::narrow_from_decl (d);;
+
+ if (!a->readonly ())
+ {
+ this->has_rw_attributes_ = true;
+ }
+
continue;
default:
continue;
diff --git a/TAO/TAO_IDL/be/be_visitor_attribute/component_init.cpp b/TAO/TAO_IDL/be/be_visitor_attribute/component_init.cpp
index bad4a3281f0..2f938b079b7 100644
--- a/TAO/TAO_IDL/be/be_visitor_attribute/component_init.cpp
+++ b/TAO/TAO_IDL/be/be_visitor_attribute/component_init.cpp
@@ -202,7 +202,8 @@ be_visitor_attribute_component_init::emit_error (
<< corba_kind << "\"" << be_nl
<< " \"IDL type are not yet "
<< "supported by CIAO\\n\"));"
- << be_nl;
+ << be_nl << be_nl
+ << "ACE_UNUSED_ARG (descr_value);" << be_nl;
this->close_if_block ();
}
diff --git a/TAO/TAO_IDL/be/be_visitor_component/servant_svh.cpp b/TAO/TAO_IDL/be/be_visitor_component/servant_svh.cpp
index 08f4df65629..751f8047b9a 100644
--- a/TAO/TAO_IDL/be/be_visitor_component/servant_svh.cpp
+++ b/TAO/TAO_IDL/be/be_visitor_component/servant_svh.cpp
@@ -69,7 +69,7 @@ be_visitor_servant_svh::visit_component (be_component *node)
<< "virtual ~" << lname << "_Servant"
<< " (void);" << be_nl;
- if (this->node_->has_attributes ())
+ if (this->node_->has_rw_attributes ())
{
os_ << be_nl
<< "virtual void" << be_nl
diff --git a/TAO/TAO_IDL/be/be_visitor_component/servant_svs.cpp b/TAO/TAO_IDL/be/be_visitor_component/servant_svs.cpp
index 046307858d5..82bef83d8a3 100644
--- a/TAO/TAO_IDL/be/be_visitor_component/servant_svs.cpp
+++ b/TAO/TAO_IDL/be/be_visitor_component/servant_svs.cpp
@@ -120,7 +120,7 @@ be_visitor_servant_svs::visit_component (be_component *node)
<< "{" << be_nl
<< "}";
- if (this->node_->has_attributes ())
+ if (this->node_->has_rw_attributes ())
{
os_ << be_nl << be_nl
<< "void" << be_nl
diff --git a/TAO/TAO_IDL/be_include/be_component.h b/TAO/TAO_IDL/be_include/be_component.h
index c94d55cc345..2d4df6ed171 100644
--- a/TAO/TAO_IDL/be_include/be_component.h
+++ b/TAO/TAO_IDL/be_include/be_component.h
@@ -64,7 +64,7 @@ public:
bool has_publishes (void);
bool has_consumes (void);
bool has_emits (void);
- bool has_attributes (void);
+ bool has_rw_attributes (void);
// Narrowing.
@@ -86,7 +86,7 @@ private:
bool has_publishes_;
bool has_consumes_;
bool has_emits_;
- bool has_attributes_;
+ bool has_rw_attributes_;
};
#endif // if !defined