mirror of
https://github.com/rui314/mold.git
synced 2024-12-27 10:23:41 +03:00
Add "mold: " prefix for all error and warning messages
This commit is contained in:
parent
eb78d185f1
commit
b100f6a486
6
mold.h
6
mold.h
@ -1589,7 +1589,9 @@ private:
|
||||
template <typename E>
|
||||
class Fatal {
|
||||
public:
|
||||
Fatal(Context<E> &ctx) : out(ctx, std::cerr) {}
|
||||
Fatal(Context<E> &ctx) : out(ctx, std::cerr) {
|
||||
out << "mold: ";
|
||||
}
|
||||
|
||||
[[noreturn]] ~Fatal() {
|
||||
out.~SyncOut();
|
||||
@ -1610,6 +1612,7 @@ template <typename E>
|
||||
class Error {
|
||||
public:
|
||||
Error(Context<E> &ctx) : out(ctx, std::cerr) {
|
||||
out << "mold: ";
|
||||
ctx.has_error = true;
|
||||
}
|
||||
|
||||
@ -1633,6 +1636,7 @@ template <typename E>
|
||||
class Warn {
|
||||
public:
|
||||
Warn(Context<E> &ctx) : out(ctx, std::cerr) {
|
||||
out << "mold: ";
|
||||
if (ctx.arg.fatal_warnings)
|
||||
ctx.has_error = true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user