From a47a05a2f73e377053f9b864b0f36c99a84708af Mon Sep 17 00:00:00 2001 From: Jose Date: Mon, 20 Mar 2017 21:51:43 +0100 Subject: Fix (ICE-7684) - use Disp prefix only for class with operations skeletons --- cpp/src/Slice/PythonUtil.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'cpp/src/Slice/PythonUtil.cpp') diff --git a/cpp/src/Slice/PythonUtil.cpp b/cpp/src/Slice/PythonUtil.cpp index 05c928c0e7d..ae3c04aa9b9 100644 --- a/cpp/src/Slice/PythonUtil.cpp +++ b/cpp/src/Slice/PythonUtil.cpp @@ -521,8 +521,8 @@ Slice::Python::CodeVisitor::visitClassDefStart(const ClassDefPtr& p) string type = getAbsolute(p, "_t_"); string classType = getAbsolute(p, "_t_", "Disp"); string abs = getAbsolute(p); - string className = isLocal ? fixIdent(p->name()) : isAbstract ? fixIdent("_" + p->name() + "Disp") : "None"; - string classAbs = getAbsolute(p, "_", "Disp"); + string className = isLocal || isInterface ? fixIdent(p->name()) : isAbstract ? fixIdent(p->name() + "Disp") : "None"; + string classAbs = isInterface ? getAbsolute(p) : getAbsolute(p, "", "Disp"); string valueName = (isInterface && !isLocal) ? "Ice.Value" : fixIdent(p->name()); string prxAbs = getAbsolute(p, "", "Prx"); string prxName = fixIdent(p->name() + "Prx"); @@ -902,7 +902,7 @@ Slice::Python::CodeVisitor::visitClassDefStart(const ClassDefPtr& p) ClassDefPtr d = *q; if(d->isInterface() || d->allOperations().size() > 0) { - baseClasses.push_back(getSymbol(*q, "_", "Disp")); + baseClasses.push_back(getSymbol(*q, "", d->isInterface() ? "" : "Disp")); } } -- cgit v1.2.3