summaryrefslogtreecommitdiff
path: root/cpp/src/Slice/Parser.cpp
diff options
context:
space:
mode:
authorBernard Normier <bernard@zeroc.com>2016-11-12 18:25:33 -0500
committerBernard Normier <bernard@zeroc.com>2016-11-12 18:25:33 -0500
commit838539aff5bf3f37f4d9a6f33713824e98fa3db3 (patch)
tree57cac4a47a00697d6f0011d9aff8f76d6994f2ed /cpp/src/Slice/Parser.cpp
parentMSBuild project updates (diff)
downloadice-838539aff5bf3f37f4d9a6f33713824e98fa3db3.tar.bz2
ice-838539aff5bf3f37f4d9a6f33713824e98fa3db3.tar.xz
ice-838539aff5bf3f37f4d9a6f33713824e98fa3db3.zip
Replaced non-public double underscores in C++
Diffstat (limited to 'cpp/src/Slice/Parser.cpp')
-rw-r--r--cpp/src/Slice/Parser.cpp17
1 files changed, 9 insertions, 8 deletions
diff --git a/cpp/src/Slice/Parser.cpp b/cpp/src/Slice/Parser.cpp
index e6e8fb768a6..3bcdd55a197 100644
--- a/cpp/src/Slice/Parser.cpp
+++ b/cpp/src/Slice/Parser.cpp
@@ -425,12 +425,13 @@ string
Slice::Contained::flattenedScope() const
{
string s = scope();
- string flattenedScope;
- for(string::const_iterator r = s.begin(); r != s.end(); ++r)
+ string::size_type pos = 0;
+ while((pos = s.find("::", pos)) != string::npos)
{
- flattenedScope += ((*r) == ':') ? '_' : *r;
+ s.replace(pos, 2, "_");
+
}
- return flattenedScope;
+ return s;
}
string
@@ -3805,13 +3806,13 @@ Slice::ClassDef::ClassDef(const ContainerPtr& container, const string& name, int
bool
Slice::Proxy::isLocal() const
{
- return __class->isLocal();
+ return _classDecl->isLocal();
}
string
Slice::Proxy::typeId() const
{
- return __class->scoped();
+ return _classDecl->scoped();
}
bool
@@ -3835,13 +3836,13 @@ Slice::Proxy::isVariableLength() const
ClassDeclPtr
Slice::Proxy::_class() const
{
- return __class;
+ return _classDecl;
}
Slice::Proxy::Proxy(const ClassDeclPtr& cl) :
SyntaxTreeBase(cl->unit()),
Type(cl->unit()),
- __class(cl)
+ _classDecl(cl)
{
}