summaryrefslogtreecommitdiff
path: root/cpp/src/Slice/Parser.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/src/Slice/Parser.cpp')
-rw-r--r--cpp/src/Slice/Parser.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/cpp/src/Slice/Parser.cpp b/cpp/src/Slice/Parser.cpp
index cea765dc172..8fd318910e1 100644
--- a/cpp/src/Slice/Parser.cpp
+++ b/cpp/src/Slice/Parser.cpp
@@ -1352,7 +1352,14 @@ Slice::ClassDef::createOperation(const string& name,
++q;
while (q != allParams.end())
{
- if (p->second == q->second)
+ //
+ // Complain about duplicate parameters only if they are
+ // non-empty; otherwise, we get a complaint about duplicates
+ // if two or more parameter names are missing in an operation
+ // signature (but the missing parameters have been reported
+ // already).
+ //
+ if (p->second == q->second && p->second != "")
{
string msg = "duplicate parameter `";
msg += p->second;