From 474b650ec3b4e39efeced7d6f5cdea4b1f2b035a Mon Sep 17 00:00:00 2001 From: Kaveh R. Ghazi <ghazi@caip.rutgers.edu> Date: Wed, 1 Jun 2005 02:55:50 +0000 Subject: [PATCH] errors.h (warning, [...]): Add printf attribute. * errors.h (warning, error, fatal, internal_error): Add printf attribute. * genmodes.c (make_vector_mode): Fix format arguments. From-SVN: r100421 --- gcc/ChangeLog | 6 ++++++ gcc/errors.h | 8 ++++---- gcc/genmodes.c | 2 +- 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 468a0b7..2f31945 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,5 +1,11 @@ 2005-05-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> + * errors.h (warning, error, fatal, internal_error): Add printf + attribute. + * genmodes.c (make_vector_mode): Fix format arguments. + +2005-05-31 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> + * basic-block.h, bb-reorder.c, c-gimplify.c, config/darwin.c, config/rs6000/rs6000-c.c, dominance.c, gimple-low.c, gimplify.c, lambda-code.c, lambda-trans.c, tree-browser.c, tree-cfg.c, diff --git a/gcc/errors.h b/gcc/errors.h index 9aa87e7..cc0c4a0 100644 --- a/gcc/errors.h +++ b/gcc/errors.h @@ -30,10 +30,10 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA #ifndef GCC_ERRORS_H #define GCC_ERRORS_H -extern void warning (int, const char *, ...); -extern void error (const char *, ...); -extern void fatal (const char *, ...) ATTRIBUTE_NORETURN; -extern void internal_error (const char *, ...) ATTRIBUTE_NORETURN; +extern void warning (int, const char *, ...) ATTRIBUTE_PRINTF_2; +extern void error (const char *, ...) ATTRIBUTE_PRINTF_1; +extern void fatal (const char *, ...) ATTRIBUTE_NORETURN ATTRIBUTE_PRINTF_1; +extern void internal_error (const char *, ...) ATTRIBUTE_NORETURN ATTRIBUTE_PRINTF_1; extern const char *trim_filename (const char *); extern int have_error; diff --git a/gcc/genmodes.c b/gcc/genmodes.c index 74c71c9..42a8d03 100644 --- a/gcc/genmodes.c +++ b/gcc/genmodes.c @@ -620,7 +620,7 @@ make_vector_mode (enum mode_class bclass, ncomponents, base) >= sizeof namebuf) { error ("%s:%d: mode name \"%s\" is too long", - base, file, line); + file, line, base); return; } -- libgit2 0.26.0