Modernize a couple of loops

llvm-svn: 212394
This commit is contained in:
Alp Toker 2014-07-06 06:09:20 +00:00
parent d2c3ba6fbe
commit dbb0c75977
2 changed files with 4 additions and 10 deletions

View File

@ -73,11 +73,8 @@ void arcmt::writeARCDiagsToPlist(const std::string &outPath,
" <key>files</key>\n"
" <array>\n";
for (SmallVectorImpl<FileID>::iterator I=Fids.begin(), E=Fids.end();
I!=E; ++I) {
o << " ";
EmitString(o, SM.getFileEntryForID(*I)->getName()) << '\n';
}
for (FileID FID : Fids)
EmitString(o << " ", SM.getFileEntryForID(FID)->getName()) << '\n';
o << " </array>\n"
" <key>diagnostics</key>\n"

View File

@ -358,11 +358,8 @@ void PlistDiagnostics::FlushDiagnosticsImpl(
o << " <key>files</key>\n"
" <array>\n";
for (SmallVectorImpl<FileID>::iterator I=Fids.begin(), E=Fids.end();
I!=E; ++I) {
o << " ";
EmitString(o, SM->getFileEntryForID(*I)->getName()) << '\n';
}
for (FileID FID : Fids)
EmitString(o << " ", SM->getFileEntryForID(FID)->getName()) << '\n';
o << " </array>\n"
" <key>diagnostics</key>\n"