From e57e265ba61a2e07623521dc872a2b7e82e70b37 Mon Sep 17 00:00:00 2001 From: Paolo Bonzini Date: Tue, 3 Feb 2004 11:22:41 +0000 Subject: re PR c/11658 (Wrong error message) 2004-02-03 Paolo Bonzini PR c/11658 PR c/13994 * Makefile.in (c-parse.o, c-convert.o, c-typeck.o): Depend on langhooks.h. * objc/Make-lang.in (objc-parse.o): Depend on langhooks.h. * c-parse.in, c-convert.c, c-typeck.c, objc/objc-act.c: Include langhooks.h. Replace c_common_truthvalue_conversion with the truthvalue_conversion language hook throughout. (expr_no_commas): Call default_conversion before save_expr for the first term of the production 'x ? : y'. * c-common.c (c_common_truthvalue_conversion): Remove obsolete block. Invoke recursively the hook instead of this function. * c-convert.c (convert): handle ERROR_MARK_NODE. * c-typeck.c (build_binary_op): handle ERROR_MARK_NODE returned by the truthvalue_conversion language hook. * c-lang.c (LANG_HOOKS_TRUTHVALUE_CONVERSION): Use c_objc_common_truthvalue_conversion. * c-objc-common.c (c_objc_common_truthvalue_conversion): New function. * c-tree.h (c_objc_common_truthvalue_conversion): Declare it. * objc/objc-lang.c (LANG_HOOKS_TRUTHVALUE_CONVERSION): Use c_objc_common_truthvalue_conversion. From-SVN: r77168 --- gcc/c-tree.h | 1 + 1 file changed, 1 insertion(+) (limited to 'gcc/c-tree.h') diff --git a/gcc/c-tree.h b/gcc/c-tree.h index 4849ab2..e9bc5c6 100644 --- a/gcc/c-tree.h +++ b/gcc/c-tree.h @@ -237,6 +237,7 @@ extern void merge_translation_unit_decls (void); extern int c_disregard_inline_limits (tree); extern int c_cannot_inline_tree_fn (tree *); extern bool c_objc_common_init (void); +extern tree c_objc_common_truthvalue_conversion (tree expr); extern int c_missing_noreturn_ok_p (tree); extern void c_objc_common_finish_file (void); extern int defer_fn (tree); -- cgit v1.1