summaryrefslogtreecommitdiff
path: root/cpp/src/slice2cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/src/slice2cpp')
-rw-r--r--cpp/src/slice2cpp/Gen.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/cpp/src/slice2cpp/Gen.cpp b/cpp/src/slice2cpp/Gen.cpp
index 7ec8e902650..994c62dc707 100644
--- a/cpp/src/slice2cpp/Gen.cpp
+++ b/cpp/src/slice2cpp/Gen.cpp
@@ -1395,6 +1395,10 @@ Slice::Gen::ProxyVisitor::visitOperation(const OperationPtr& p)
C << sb;
C << nl << "try";
C << sb;
+ if(p->returnsData())
+ {
+ C << "__checkTwowayOnly(\"" << p->name() << "\");";
+ }
C << nl << "::IceInternal::Handle< ::IceDelegate::Ice::Object> __delBase = __getDelegate();";
C << nl << "::IceDelegate" << thisPointer << " __del = dynamic_cast< ::IceDelegate"
<< thisPointer << ">(__delBase.get());";
@@ -1452,6 +1456,10 @@ Slice::Gen::ProxyVisitor::visitOperation(const OperationPtr& p)
C << sb;
C << nl << "try";
C << sb;
+ if(p->returnsData())
+ {
+ C << "__checkTwowayOnly(\"" << p->name() << "\");";
+ }
C << nl << "::IceInternal::Handle< ::IceDelegate::Ice::Object> __delBase = __getDelegate();";
C << nl << "::IceDelegate" << thisPointer << " __del = dynamic_cast< ::IceDelegate"
<< thisPointer << ">(__delBase.get());";