Skip to content

Commit a77f7e4

Browse files
committed
Do not shadow "it"
Just use a ranged for instead.
1 parent d65b9e3 commit a77f7e4

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

src/cpp/cpp_typecheck_namespace.cpp

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -93,10 +93,7 @@ void cpp_typecheckt::convert(cpp_namespace_spect &namespace_spec)
9393
else
9494
{
9595
// do the declarations
96-
for(cpp_namespace_spect::itemst::iterator
97-
it=namespace_spec.items().begin();
98-
it!=namespace_spec.items().end();
99-
it++)
100-
convert(*it);
96+
for(auto &item : namespace_spec.items())
97+
convert(item);
10198
}
10299
}

0 commit comments

Comments
 (0)