X-Git-Url: http://git.efficios.com/?a=blobdiff_plain;f=gold%2Ferrors.h;h=ac681e965bb2b131dae37fd1fe0495ba5bcf884b;hb=c1b5c1ebc938b6dc0277363b8c47d75b0b5a621f;hp=4b71e6cf86df7b90e5d07d8d37e48a2cf2402c6d;hpb=f073bbf7e0a9d7ebe5323c660b34c893c5dfedee;p=deliverable%2Fbinutils-gdb.git diff --git a/gold/errors.h b/gold/errors.h index 4b71e6cf86..ac681e965b 100644 --- a/gold/errors.h +++ b/gold/errors.h @@ -1,6 +1,6 @@ // errors.h -- handle errors for gold -*- C++ -*- -// Copyright 2006, 2007, 2008 Free Software Foundation, Inc. +// Copyright (C) 2006-2019 Free Software Foundation, Inc. // Written by Ian Lance Taylor . // This file is part of gold. @@ -24,6 +24,7 @@ #define GOLD_ERRORS_H #include +#include #include "gold-threads.h" @@ -49,6 +50,12 @@ class Errors void fatal(const char* format, va_list) ATTRIBUTE_NORETURN; + // Report a fallback error. After printing the error, this must exit + // with a special status code indicating that fallback to + // --incremental-full is required. + void + fallback(const char* format, va_list) ATTRIBUTE_NORETURN; + // Report an error and continue. void error(const char* format, va_list); @@ -116,6 +123,8 @@ class Errors // This class can be accessed from multiple threads. This lock is // used to control access to the data structures. Lock* lock_; + // Used to initialize the lock_ field exactly once. + Initialize_lock initialize_lock_; // Numbers of errors reported. int error_count_; // Number of warnings reported.