summaryrefslogtreecommitdiff
path: root/cpp/src/slice2cpp/Gen.cpp
diff options
context:
space:
mode:
authorMark Spruiell <mes@zeroc.com>2002-01-23 19:16:32 +0000
committerMark Spruiell <mes@zeroc.com>2002-01-23 19:16:32 +0000
commitfb8ce1e773d8ed7dff721f961ade15a7c361c3b8 (patch)
tree33f1f7398449615a96e64ddb7980db186d2c4e86 /cpp/src/slice2cpp/Gen.cpp
parentfix comments. (diff)
downloadice-fb8ce1e773d8ed7dff721f961ade15a7c361c3b8.tar.bz2
ice-fb8ce1e773d8ed7dff721f961ade15a7c361c3b8.tar.xz
ice-fb8ce1e773d8ed7dff721f961ade15a7c361c3b8.zip
fixing writeAssign, removing Communicator arg to constructor in sample
impls
Diffstat (limited to 'cpp/src/slice2cpp/Gen.cpp')
-rw-r--r--cpp/src/slice2cpp/Gen.cpp37
1 files changed, 4 insertions, 33 deletions
diff --git a/cpp/src/slice2cpp/Gen.cpp b/cpp/src/slice2cpp/Gen.cpp
index a0b247af227..4c8ab769272 100644
--- a/cpp/src/slice2cpp/Gen.cpp
+++ b/cpp/src/slice2cpp/Gen.cpp
@@ -2587,39 +2587,19 @@ Slice::Gen::ImplVisitor::writeAssign(Output& out, const TypePtr& type, const str
{
switch (builtin->kind())
{
- case Builtin::KindByte:
- {
- out << nl << name << " = ::Ice::Byte(0);";
- break;
- }
case Builtin::KindBool:
{
out << nl << name << " = false;";
break;
}
+ case Builtin::KindByte:
case Builtin::KindShort:
- {
- out << nl << name << " = ::Ice::Short(0);";
- break;
- }
case Builtin::KindInt:
- {
- out << nl << name << " = ::Ice::Int(0);";
- break;
- }
case Builtin::KindLong:
- {
- out << nl << name << " = ::Ice::Long(0);";
- break;
- }
case Builtin::KindFloat:
- {
- out << nl << name << " = ::Ice::Float(0);";
- break;
- }
case Builtin::KindDouble:
{
- out << nl << name << " = ::Ice::Double(0);";
+ out << nl << name << " = 0;";
break;
}
case Builtin::KindString:
@@ -2745,14 +2725,10 @@ Slice::Gen::ImplVisitor::visitClassDefStart(const ClassDefPtr& p)
H << nl << "public:";
H.inc();
- H << sp << nl << name << "I(const Ice::CommunicatorPtr&);";
+ H << sp << nl << name << "I();";
H << nl << "virtual ~" << name << "I();";
- C << sp << nl << cls << "::" << name
- << "I(const Ice::CommunicatorPtr& communicator)";
- C.inc();
- C << nl << "_communicator(communicator)";
- C.dec();
+ C << sp << nl << cls << "::" << name << "I()";
C << sb;
C << eb;
@@ -2865,11 +2841,6 @@ Slice::Gen::ImplVisitor::visitClassDefStart(const ClassDefPtr& p)
C << eb;
}
- H << sp;
- H.dec();
- H << nl << "private:";
- H.inc();
- H << sp << nl << "Ice::CommunicatorPtr _communicator;";
H << eb << ';';
return true;