diff options
author | Igor Kudrin <ikudrin@accesssoftek.com> | 2019-08-01 05:23:45 +0000 |
---|---|---|
committer | Igor Kudrin <ikudrin@accesssoftek.com> | 2019-08-01 05:23:45 +0000 |
commit | 510086b5e5cc402fa835d522373f9d9401291d73 (patch) | |
tree | effef28fead390d2a9fbb4593149e5962ad152d3 /lld/Common | |
parent | 67a8d6c795ded813c44bfcc54ac419bb51da5dbc (diff) | |
download | bcm5719-llvm-510086b5e5cc402fa835d522373f9d9401291d73.tar.gz bcm5719-llvm-510086b5e5cc402fa835d522373f9d9401291d73.zip |
[ELF] Fix finding locations in messages for undefined hidden symbols.
Previously, when `--vs-diagnostics` was used, the linker printed
something like
hidden(undef.s): error: undefined hidden symbol: foo
>>> referenced by undef.s:15
Differential Revision: https://reviews.llvm.org/D65499
llvm-svn: 367515
Diffstat (limited to 'lld/Common')
-rw-r--r-- | lld/Common/ErrorHandler.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/lld/Common/ErrorHandler.cpp b/lld/Common/ErrorHandler.cpp index 983962db579..7e417da8989 100644 --- a/lld/Common/ErrorHandler.cpp +++ b/lld/Common/ErrorHandler.cpp @@ -87,7 +87,7 @@ void lld::checkError(Error e) { static std::string getLocation(std::string msg, std::string defaultMsg) { static std::vector<std::regex> Regexes{ - std::regex(R"(^undefined symbol:.*\n>>> referenced by (\S+):(\d+)\n.*)"), + std::regex(R"(^undefined (?:\S+ )?symbol:.*\n>>> referenced by (\S+):(\d+)\n.*)"), std::regex(R"(^undefined symbol:.*\n>>> referenced by (.*):)"), std::regex( R"(^duplicate symbol: .*\n>>> defined in (\S+)\n>>> defined in.*)"), @@ -95,8 +95,6 @@ static std::string getLocation(std::string msg, std::string defaultMsg) { R"(^duplicate symbol: .*\n>>> defined at (\S+):(\d+).*)"), std::regex( R"(.*\n>>> defined in .*\n>>> referenced by (\S+):(\d+))"), - std::regex( - R"(^undefined (internal|hidden|protected) symbol: .*\n>>> referenced by (\S+):(\d+)\n.*)"), std::regex(R"((\S+):(\d+): unclosed quote)"), }; |