summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsma <sma@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2010-06-18 11:18:03 +0000
committersma <sma@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2010-06-18 11:18:03 +0000
commit0dc8b9fc2860a66915d606ba2ab15037159cc8b3 (patch)
tree73287507064bc7e171e9b956eeb555e03cd91e24
parent08823121d5fb07851b11943a92a2239adf00e74d (diff)
downloadATCD-0dc8b9fc2860a66915d606ba2ab15037159cc8b3.tar.gz
ChangeLogTag: Fri Jun 18 11:20:00 UTC 2010 Simon Massey <simon dot massey at prismtech dot com>
-rw-r--r--TAO/ChangeLog11
-rw-r--r--TAO/TAO_IDL/util/utl_scope.cpp9
2 files changed, 17 insertions, 3 deletions
diff --git a/TAO/ChangeLog b/TAO/ChangeLog
index af0c30bfd3d..c796cb7aaa5 100644
--- a/TAO/ChangeLog
+++ b/TAO/ChangeLog
@@ -1,3 +1,14 @@
+Fri Jun 18 11:20:00 UTC 2010 Simon Massey <simon dot massey at prismtech dot com>
+
+ * TAO_IDL/util/utl_scope.cpp:
+
+ Having talked this though with Jeff Parsons, we now have the
+ correct version of the call to add_to_referenced() at the end
+ of the lookup_by_name () function. Basically we always add to
+ the actual scope that the name was found in, and the name is
+ always the first real identifer in the ScopedName (not the
+ global scope empty identifier, if given).
+
Thu Jun 17 15:20:00 UTC 2010 Simon Massey <simon dot massey at prismtech dot com>
* TAO_IDL/util/utl_scope.cpp:
diff --git a/TAO/TAO_IDL/util/utl_scope.cpp b/TAO/TAO_IDL/util/utl_scope.cpp
index d9e192433b3..db212c1a351 100644
--- a/TAO/TAO_IDL/util/utl_scope.cpp
+++ b/TAO/TAO_IDL/util/utl_scope.cpp
@@ -1285,15 +1285,19 @@ UTL_Scope::lookup_by_name (UTL_ScopedName *e,
}
UTL_Scope *work = this;
- Identifier *const name = e->head ();
// If name starts with "::" or "" start lookup in global scope,
// if we're not there already, short_circuiting the
// scope-expanding iteration below.
+ Identifier *name = e->head ();
const bool global_scope_name = work->is_global_name (name);
if (global_scope_name)
{
+ // Remove the preceeding "::" or "" from the scopename
e = static_cast<UTL_ScopedName *> (e->tail ());
+ name = e->head ();
+
+ // Move directly to the root scope
work = idl_global->root ();
}
@@ -1340,10 +1344,9 @@ UTL_Scope::lookup_by_name (UTL_ScopedName *e,
}
}
}
-
- this->add_to_referenced (d, false, name);
}
+ work->add_to_referenced (d, false, name); // Doesn't add if !d
masks.reset ();
return d;
}