diff options
Diffstat (limited to 'cpp/src')
-rw-r--r-- | cpp/src/Slice/CPlusPlusUtil.cpp | 4 | ||||
-rw-r--r-- | cpp/src/slice2cpp/Gen.cpp | 8 |
2 files changed, 9 insertions, 3 deletions
diff --git a/cpp/src/Slice/CPlusPlusUtil.cpp b/cpp/src/Slice/CPlusPlusUtil.cpp index aab278a1bbc..3ec486668be 100644 --- a/cpp/src/Slice/CPlusPlusUtil.cpp +++ b/cpp/src/Slice/CPlusPlusUtil.cpp @@ -428,7 +428,7 @@ Slice::writeMarshalUnmarshalCode(Output& out, const TypePtr& type, const string& if(def && !def->isAbstract()) { factory = fixKwd(cl->scoped()); - factory += "::_factory"; + factory += "::ice_factory()"; type = fixKwd(cl->scoped()); type += "::ice_staticId()"; } @@ -647,7 +647,7 @@ Slice::writeGenericMarshalUnmarshalCode(Output& out, const TypePtr& type, const if(def && !def->isAbstract()) { factory = fixKwd(cl->scoped()); - factory += "::_factory"; + factory += "::ice_factory()"; type = fixKwd(cl->scoped()); type += "::ice_staticId()"; } diff --git a/cpp/src/slice2cpp/Gen.cpp b/cpp/src/slice2cpp/Gen.cpp index 86d37fd5756..e73cb72c486 100644 --- a/cpp/src/slice2cpp/Gen.cpp +++ b/cpp/src/slice2cpp/Gen.cpp @@ -1905,8 +1905,14 @@ Slice::Gen::ObjectVisitor::visitClassDefStart(const ClassDefPtr& p) if(!p->isAbstract()) { + H.dec(); + H << sp << nl << "private:"; + H.inc(); H << sp << nl << exp2 << "static ::Ice::ObjectFactoryPtr _factory;"; - H << nl << exp2 << "static const ::Ice::ObjectFactoryPtr& ice_factory();"; + H.dec(); + H << sp << nl << "public:"; + H.inc(); + H << sp << nl << exp2 << "static const ::Ice::ObjectFactoryPtr& ice_factory();"; } C << sp; C << nl << "const ::std::string " << scoped.substr(2) << "::__ids[" << ids.size() << "] ="; |