diff options
author | David Robillard <d@drobilla.net> | 2012-12-25 00:51:18 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2012-12-25 00:51:18 +0000 |
commit | 12314c754187ae246bc38aceb827bf51d1669d73 (patch) | |
tree | 920e8855c6e933a8da19c6402b27e9b52ac3a474 /src/depoly.cpp | |
parent | bf757dcc9b66ebb3bf7e2df8e8c7d3a011ddd6dc (diff) | |
download | resp-12314c754187ae246bc38aceb827bf51d1669d73.tar.gz resp-12314c754187ae246bc38aceb827bf51d1669d73.tar.bz2 resp-12314c754187ae246bc38aceb827bf51d1669d73.zip |
Use C++11 range-based for loops.
git-svn-id: http://svn.drobilla.net/resp/trunk@444 ad02d1e2-f140-0410-9f75-f8b11f17cedd
Diffstat (limited to 'src/depoly.cpp')
-rw-r--r-- | src/depoly.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/depoly.cpp b/src/depoly.cpp index 0ee89c1..cb698df 100644 --- a/src/depoly.cpp +++ b/src/depoly.cpp @@ -35,8 +35,8 @@ is_concrete(const AST* type) return isupper(type->as_symbol()->str()[0]); } else { const ATuple* tup = type->as_tuple(); - for (ATuple::const_iterator i = tup->begin(); i != tup->end(); ++i) { - if (!is_concrete(*i)) { + for (auto i : *tup) { + if (!is_concrete(i)) { return false; } } @@ -93,8 +93,8 @@ raise_type(CEnv& cenv, Code& code, const ATuple* type) static const AST* depoly_args(CEnv& cenv, Code& code, const ATuple* call) throw() { - for (ATuple::const_iterator i = call->begin(); i != call->end(); ++i) { - const AST* type = cenv.type(*i); + for (auto i : *call) { + const AST* type = cenv.type(i); if (type && type->to_tuple()) { if (is_concrete(type)) { raise_type(cenv, code, type->as_tuple()); |