diff options
author | Jose <jose@zeroc.com> | 2019-04-04 15:00:49 +0200 |
---|---|---|
committer | Jose <jose@zeroc.com> | 2019-04-04 15:00:49 +0200 |
commit | 388b98cd14f2fa058cbff77b1b66a5a25e70a430 (patch) | |
tree | e1511f5b42ed87541f38ee75f2457464c9cb9c46 /cpp/src/slice2swift/SwiftUtil.cpp | |
parent | Fix for skip optionals (diff) | |
download | ice-388b98cd14f2fa058cbff77b1b66a5a25e70a430.tar.bz2 ice-388b98cd14f2fa058cbff77b1b66a5a25e70a430.tar.xz ice-388b98cd14f2fa058cbff77b1b66a5a25e70a430.zip |
Fix operation optional parameters declaration
Diffstat (limited to 'cpp/src/slice2swift/SwiftUtil.cpp')
-rw-r--r-- | cpp/src/slice2swift/SwiftUtil.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/cpp/src/slice2swift/SwiftUtil.cpp b/cpp/src/slice2swift/SwiftUtil.cpp index aa95817d4bc..4ea5414eeae 100644 --- a/cpp/src/slice2swift/SwiftUtil.cpp +++ b/cpp/src/slice2swift/SwiftUtil.cpp @@ -363,8 +363,10 @@ SwiftGenerator::writeConstantValue(IceUtilInternal::Output& out, const TypePtr& } string -SwiftGenerator::typeToString(const TypePtr& type, const ContainedPtr& toplevel, - const StringList& metadata, bool optional, +SwiftGenerator::typeToString(const TypePtr& type, + const ContainedPtr& toplevel, + const StringList& metadata, + bool optional, int typeCtx) { static const char* builtinTable[] = @@ -1768,7 +1770,7 @@ SwiftGenerator::writeProxyOperation(::IceUtilInternal::Output& out, const Operat out << spar; for(ParamInfoList::const_iterator q = allInParams.begin(); q != allInParams.end(); ++q) { - out << ((allInParams.size() == 1 ? "_ " : "") + q->name + ": " + typeToString(q->type, op)); + out << ((allInParams.size() == 1 ? "_ " : "") + q->name + ": " + q->typeStr); } out << "context: Context? = nil"; @@ -1855,7 +1857,7 @@ SwiftGenerator::writeProxyAsyncOperation(::IceUtilInternal::Output& out, const O out << spar; for(ParamInfoList::const_iterator q = allInParams.begin(); q != allInParams.end(); ++q) { - out << ((allInParams.size() == 1 ? "_ " : "") + q->name + ": " + typeToString(q->type, op)); + out << ((allInParams.size() == 1 ? "_ " : "") + q->name + ": " + q->typeStr); } out << "context: Context? = nil"; out << "sent: ((Bool) -> Void)? = nil"; |