diff options
author | Bill Wendling <isanbard@gmail.com> | 2008-07-03 23:13:02 +0000 |
---|---|---|
committer | Bill Wendling <isanbard@gmail.com> | 2008-07-03 23:13:02 +0000 |
commit | c04f46567c3ebf64257d8f03e29d80a69606a6bc (patch) | |
tree | 53afbe1b9267df3a9f088aa94f0ed1b92d31bb44 /lib/CodeGen/DwarfWriter.cpp | |
parent | 10fff6078a7bc42f142c536bd55e9569253b280b (diff) |
Don't return std::vector by value, but pass it in by reference to be filled.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@53123 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/DwarfWriter.cpp')
-rw-r--r-- | lib/CodeGen/DwarfWriter.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/CodeGen/DwarfWriter.cpp b/lib/CodeGen/DwarfWriter.cpp index a284ba19eb..2d0a114202 100644 --- a/lib/CodeGen/DwarfWriter.cpp +++ b/lib/CodeGen/DwarfWriter.cpp @@ -2630,8 +2630,8 @@ private: /// ConstructGlobalDIEs - Create DIEs for each of the externally visible /// global variables. void ConstructGlobalDIEs() { - std::vector<GlobalVariableDesc *> GlobalVariables = - MMI->getAnchoredDescriptors<GlobalVariableDesc>(*M); + std::vector<GlobalVariableDesc *> GlobalVariables; + MMI->getAnchoredDescriptors<GlobalVariableDesc>(*M, GlobalVariables); for (unsigned i = 0, N = GlobalVariables.size(); i < N; ++i) { GlobalVariableDesc *GVD = GlobalVariables[i]; @@ -2642,8 +2642,8 @@ private: /// ConstructSubprogramDIEs - Create DIEs for each of the externally visible /// subprograms. void ConstructSubprogramDIEs() { - std::vector<SubprogramDesc *> Subprograms = - MMI->getAnchoredDescriptors<SubprogramDesc>(*M); + std::vector<SubprogramDesc *> Subprograms; + MMI->getAnchoredDescriptors<SubprogramDesc>(*M, Subprograms); for (unsigned i = 0, N = Subprograms.size(); i < N; ++i) { SubprogramDesc *SPD = Subprograms[i]; |