xref: /dflybsd-src/contrib/gcc-4.7/gcc/errors.h (revision 04febcfb30580676d3e95f58a16c5137ee478b32)
1*e4b17023SJohn Marino /* Basic error reporting routines.
2*e4b17023SJohn Marino    Copyright (C) 1999, 2000, 2001, 2003, 2004, 2005, 2007, 2008
3*e4b17023SJohn Marino    Free Software Foundation, Inc.
4*e4b17023SJohn Marino 
5*e4b17023SJohn Marino This file is part of GCC.
6*e4b17023SJohn Marino 
7*e4b17023SJohn Marino GCC is free software; you can redistribute it and/or modify it under
8*e4b17023SJohn Marino the terms of the GNU General Public License as published by the Free
9*e4b17023SJohn Marino Software Foundation; either version 3, or (at your option) any later
10*e4b17023SJohn Marino version.
11*e4b17023SJohn Marino 
12*e4b17023SJohn Marino GCC is distributed in the hope that it will be useful, but WITHOUT ANY
13*e4b17023SJohn Marino WARRANTY; without even the implied warranty of MERCHANTABILITY or
14*e4b17023SJohn Marino FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
15*e4b17023SJohn Marino for more details.
16*e4b17023SJohn Marino 
17*e4b17023SJohn Marino You should have received a copy of the GNU General Public License
18*e4b17023SJohn Marino along with GCC; see the file COPYING3.  If not see
19*e4b17023SJohn Marino <http://www.gnu.org/licenses/>.  */
20*e4b17023SJohn Marino 
21*e4b17023SJohn Marino /* warning, error, and fatal.  These definitions are suitable for use
22*e4b17023SJohn Marino    in the generator programs; eventually we would like to use them in
23*e4b17023SJohn Marino    cc1 too, but that's a longer term project.
24*e4b17023SJohn Marino 
25*e4b17023SJohn Marino    N.B. We cannot presently use ATTRIBUTE_PRINTF with these functions,
26*e4b17023SJohn Marino    because they can be extended with additional format specifiers which
27*e4b17023SJohn Marino    GCC does not know about.  */
28*e4b17023SJohn Marino 
29*e4b17023SJohn Marino #ifndef GCC_ERRORS_H
30*e4b17023SJohn Marino #define GCC_ERRORS_H
31*e4b17023SJohn Marino 
32*e4b17023SJohn Marino extern void warning (const char *, ...) ATTRIBUTE_PRINTF_1 ATTRIBUTE_COLD;
33*e4b17023SJohn Marino extern void error (const char *, ...) ATTRIBUTE_PRINTF_1 ATTRIBUTE_COLD;
34*e4b17023SJohn Marino extern void fatal (const char *, ...) ATTRIBUTE_NORETURN ATTRIBUTE_PRINTF_1 ATTRIBUTE_COLD;
35*e4b17023SJohn Marino extern void internal_error (const char *, ...) ATTRIBUTE_NORETURN ATTRIBUTE_PRINTF_1 ATTRIBUTE_COLD;
36*e4b17023SJohn Marino extern const char *trim_filename (const char *);
37*e4b17023SJohn Marino 
38*e4b17023SJohn Marino extern int have_error;
39*e4b17023SJohn Marino extern const char *progname;
40*e4b17023SJohn Marino 
41*e4b17023SJohn Marino #endif /* ! GCC_ERRORS_H */
42