diff options
Diffstat (limited to 'cpp/src/slice2cpp/Gen.cpp')
-rw-r--r-- | cpp/src/slice2cpp/Gen.cpp | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/cpp/src/slice2cpp/Gen.cpp b/cpp/src/slice2cpp/Gen.cpp index 6c82d60e60d..68d6bef1577 100644 --- a/cpp/src/slice2cpp/Gen.cpp +++ b/cpp/src/slice2cpp/Gen.cpp @@ -112,7 +112,7 @@ Slice::Gen::generate(const UnitPtr& unit) else { H << "\n#include <Ice/LocalObject.h>"; -// C << "\n#include <Ice/BasicStream.h>"; + C << "\n#include <Ice/BasicStream.h>"; } StringList includes = unit->includeFiles(); @@ -240,6 +240,13 @@ Slice::Gen::TypesVisitor::visitExceptionStart(const ExceptionPtr& p) C << sb; C << eb; } + else + { + H << nl << name << "();"; + C << sp << nl << scoped.substr(2) << "::" << name << "()"; + C << sb; + C << eb; + } H << nl << name << "(const " << name << "&);"; C << sp << nl << scoped.substr(2) << "::" << name << "(const " << name << "& ex) : "; @@ -1165,12 +1172,12 @@ Slice::Gen::DelegateMVisitor::visitOperation(const OperationPtr& p) C << eb; } C << eb; - C << nl << "throw ::Ice::UserException(__FILE__, __LINE__);"; + C << nl << "throw ::Ice::UserException();"; } else */ { - C << nl << "throw ::Ice::UserException(__FILE__, __LINE__);"; + C << nl << "throw ::Ice::UserException();"; } C << eb; writeAllocateCode(C, TypeStringList(), ret); @@ -1755,6 +1762,12 @@ Slice::Gen::ObjectVisitor::visitClassDefEnd(const ClassDefPtr& p) } bool +Slice::Gen::ObjectVisitor::visitExceptionStart(const ExceptionPtr&) +{ + return false; +} + +bool Slice::Gen::ObjectVisitor::visitStructStart(const StructPtr&) { return false; |