From: Rui Ueyama Date: Sat, 16 Jul 2016 02:00:43 +0000 (+0000) Subject: Use SymbolVersion::Id instead of a hard-coded local variable. X-Git-Tag: llvmorg-3.9.0-rc1~219 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=0ff953e8117e8435608630e82ed2d179c2d79519;p=platform%2Fupstream%2Fllvm.git Use SymbolVersion::Id instead of a hard-coded local variable. llvm-svn: 275660 --- diff --git a/lld/ELF/OutputSections.cpp b/lld/ELF/OutputSections.cpp index 7c94e84..573c7f7 100644 --- a/lld/ELF/OutputSections.cpp +++ b/lld/ELF/OutputSections.cpp @@ -1527,9 +1527,8 @@ void VersionDefinitionSection::writeTo(uint8_t *Buf) { writeDefinition(Verdef, Verdaux, VER_FLG_BASE, 1, getFileDefName(), FileDefNameOff); - uint32_t I = 2; for (Version &V : Config->SymbolVersions) - writeDefinition(Verdef, Verdaux, 0 /* Flags */, I++, V.Name, V.NameOff); + writeDefinition(Verdef, Verdaux, 0, V.Id, V.Name, V.NameOff); Verdef[-1].vd_next = 0; }