diff options
author | Jose <jose@zeroc.com> | 2019-06-21 22:22:14 +0200 |
---|---|---|
committer | Jose <jose@zeroc.com> | 2019-06-21 22:22:14 +0200 |
commit | d1b7c66fab777fe72e5cf77fd284218e2080b017 (patch) | |
tree | b48615b2d9d2f59195c8a560e07585b9cbb77cb5 /cpp/src/Slice/PythonUtil.cpp | |
parent | Add ice_isFixed - Close #356 (diff) | |
download | ice-d1b7c66fab777fe72e5cf77fd284218e2080b017.tar.bz2 ice-d1b7c66fab777fe72e5cf77fd284218e2080b017.tar.xz ice-d1b7c66fab777fe72e5cf77fd284218e2080b017.zip |
Enable -Wconversion with clang - Close #363
Diffstat (limited to 'cpp/src/Slice/PythonUtil.cpp')
-rw-r--r-- | cpp/src/Slice/PythonUtil.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/cpp/src/Slice/PythonUtil.cpp b/cpp/src/Slice/PythonUtil.cpp index 8e95f47b753..83d8a8341d3 100644 --- a/cpp/src/Slice/PythonUtil.cpp +++ b/cpp/src/Slice/PythonUtil.cpp @@ -2486,10 +2486,10 @@ Slice::Python::CodeVisitor::parseOpComment(const string& comment, OpComment& c) // string name; bool inParam = false, inException = false, inReturn = false; - vector<string>::size_type i = 0; - while(i < lines.size()) + vector<string>::iterator i = lines.begin(); + while(i != lines.end()) { - string l = lines[i]; + string l = *i; string::size_type paramTag = l.find("@param"); string::size_type throwTag = l.find("@throw"); string::size_type returnTag = l.find("@return"); @@ -2533,7 +2533,7 @@ Slice::Python::CodeVisitor::parseOpComment(const string& comment, OpComment& c) } } } - lines.erase(lines.begin() + i); + i = lines.erase(i); continue; } else if(throwTag != string::npos) @@ -2575,7 +2575,7 @@ Slice::Python::CodeVisitor::parseOpComment(const string& comment, OpComment& c) } } } - lines.erase(lines.begin() + i); + i = lines.erase(i); continue; } else if(returnTag != string::npos) @@ -2592,7 +2592,7 @@ Slice::Python::CodeVisitor::parseOpComment(const string& comment, OpComment& c) inParam = false; c.returns = l.substr(pos); } - lines.erase(lines.begin() + i); + i = lines.erase(i); continue; } else @@ -2612,7 +2612,7 @@ Slice::Python::CodeVisitor::parseOpComment(const string& comment, OpComment& c) c.params[name] += " "; } c.params[name] += l.substr(pos); - lines.erase(lines.begin() + i); + i = lines.erase(i); continue; } else if(inException) @@ -2623,7 +2623,7 @@ Slice::Python::CodeVisitor::parseOpComment(const string& comment, OpComment& c) c.exceptions[name] += " "; } c.exceptions[name] += l.substr(pos); - lines.erase(lines.begin() + i); + i = lines.erase(i); continue; } else if(inReturn) @@ -2633,7 +2633,7 @@ Slice::Python::CodeVisitor::parseOpComment(const string& comment, OpComment& c) c.returns += " "; } c.returns += l.substr(pos); - lines.erase(lines.begin() + i); + i = lines.erase(i); continue; } } |