From: Davide Italiano Date: Sat, 10 Oct 2015 00:45:24 +0000 (+0000) Subject: [llvm-rtdyld] Use range-based loop. NFC. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=f2e1e0eaf4ae600b2158fe785f1ba2d91734b006;p=oota-llvm.git [llvm-rtdyld] Use range-based loop. NFC. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@249923 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/tools/llvm-rtdyld/llvm-rtdyld.cpp b/tools/llvm-rtdyld/llvm-rtdyld.cpp index d8699505f59..54b5aa03d7d 100644 --- a/tools/llvm-rtdyld/llvm-rtdyld.cpp +++ b/tools/llvm-rtdyld/llvm-rtdyld.cpp @@ -625,10 +625,10 @@ static int linkAndVerify() { // If we don't have any input files, read from stdin. if (!InputFileList.size()) InputFileList.push_back("-"); - for(unsigned i = 0, e = InputFileList.size(); i != e; ++i) { + for (auto &Filename : InputFileList) { // Load the input memory buffer. ErrorOr> InputBuffer = - MemoryBuffer::getFileOrSTDIN(InputFileList[i]); + MemoryBuffer::getFileOrSTDIN(Filename); if (std::error_code EC = InputBuffer.getError()) return Error("unable to read input: '" + EC.message() + "'");