Skip to content

Commit

Permalink
[lld-link] For suppressible warnings, print the warning number.
Browse files Browse the repository at this point in the history
The warning can be suppressed by passing the number to /ignore:.
https://reviews.llvm.org/D44297

llvm-svn: 327257
  • Loading branch information
nico committed Mar 12, 2018
1 parent 2b8b90a commit 11a6db3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lld/COFF/Driver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -806,7 +806,7 @@ static void parseOrderFile(StringRef Arg) {

if (Set.count(S) == 0) {
if (Config->WarnMissingOrderSymbol)
warn("/order:" + Arg + ": missing symbol: " + S);
warn("/order:" + Arg + ": missing symbol: " + S + " [LNK4037]");
}
else
Config->Order[S] = INT_MIN + Config->Order.size();
Expand Down
4 changes: 2 additions & 2 deletions lld/COFF/SymbolTable.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ void SymbolTable::reportRemainingUndefines() {
if (Config->WarnLocallyDefinedImported)
if (Symbol *Imp = LocalImports.lookup(B))
warn("<root>: locally defined symbol imported: " + Imp->getName() +
" (defined in " + toString(Imp->getFile()) + ")");
" (defined in " + toString(Imp->getFile()) + ") [LNK4217]");
}

for (ObjFile *File : ObjFile::Instances) {
Expand All @@ -136,7 +136,7 @@ void SymbolTable::reportRemainingUndefines() {
if (Symbol *Imp = LocalImports.lookup(Sym))
warn(toString(File) + ": locally defined symbol imported: " +
Imp->getName() + " (defined in " + toString(Imp->getFile()) +
")");
") [LNK4217]");
}
}
}
Expand Down

0 comments on commit 11a6db3

Please sign in to comment.