From 8549882418f574245c42afc3a927c7da59015843 Mon Sep 17 00:00:00 2001 From: Joseph Myers Date: Wed, 23 Mar 2005 01:35:06 +0000 Subject: c-common.c (c_common_truthvalue_conversion): Adjust comment. * c-common.c (c_common_truthvalue_conversion): Adjust comment. Call c_common_truthvalue_conversion rather than lang_hooks.truthvalue_conversion. * c-convert.c (convert): Call c_objc_common_truthvalue_conversion. * c-objc-common.c (c_objc_common_truthvalue_conversion): Move to c-typeck.c. * c-objc-common.h (LANG_HOOKS_TRUTHVALUE_CONVERSION): Change to c_common_truthvalue_conversion. * c-parser.c (c_parser_paren_condition, c_parser_for_statement, c_parser_conditional_expression, c_parser_binary_expression): Call c_objc_common_truthvalue_conversion. * c-typeck.c (build_unary_op): Call c_objc_common_truthvalue_conversion. (build_conditional_expr): Do not call lang_hooks.truthvalue_conversion. (build_binary_op): Call c_common_truthvalue_conversion. (c_objc_common_truthvalue_conversion): Moved from c-objc-common.c. Call default_function_array_conversion instead of default_conversion. objc: * objc-act.c (next_sjlj_build_enter_and_setjmp, next_sjlj_build_catch_list, next_sjlj_build_try_catch_finally): Call c_common_truthvalue_conversion. From-SVN: r96917 --- gcc/objc/objc-act.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'gcc/objc/objc-act.c') diff --git a/gcc/objc/objc-act.c b/gcc/objc/objc-act.c index e6201af..1848e3c 100644 --- a/gcc/objc/objc-act.c +++ b/gcc/objc/objc-act.c @@ -3019,7 +3019,7 @@ next_sjlj_build_enter_and_setjmp (void) sj = build_function_call (objc_setjmp_decl, t); cond = build (COMPOUND_EXPR, TREE_TYPE (sj), enter, sj); - cond = lang_hooks.truthvalue_conversion (cond); + cond = c_common_truthvalue_conversion (cond); return build (COND_EXPR, void_type_node, cond, NULL, NULL); } @@ -3086,7 +3086,7 @@ next_sjlj_build_catch_list (void) t = objc_get_class_reference (OBJC_TYPE_NAME (TREE_TYPE (type))); args = tree_cons (NULL, t, args); t = build_function_call (objc_exception_match_decl, args); - cond = lang_hooks.truthvalue_conversion (t); + cond = c_common_truthvalue_conversion (t); } t = build (COND_EXPR, void_type_node, cond, body, NULL); SET_EXPR_LOCUS (t, EXPR_LOCUS (stmt)); @@ -3208,7 +3208,7 @@ next_sjlj_build_try_catch_finally (void) /* Build the complete FINALLY statement list. */ t = next_sjlj_build_try_exit (); t = build_stmt (COND_EXPR, - lang_hooks.truthvalue_conversion (rethrow_decl), + c_common_truthvalue_conversion (rethrow_decl), NULL, t); SET_EXPR_LOCATION (t, cur_try_context->finally_locus); append_to_statement_list (t, &TREE_OPERAND (try_fin, 1)); @@ -3219,7 +3219,7 @@ next_sjlj_build_try_catch_finally (void) t = tree_cons (NULL, rethrow_decl, NULL); t = build_function_call (objc_exception_throw_decl, t); t = build_stmt (COND_EXPR, - lang_hooks.truthvalue_conversion (rethrow_decl), + c_common_truthvalue_conversion (rethrow_decl), t, NULL); SET_EXPR_LOCATION (t, cur_try_context->end_finally_locus); append_to_statement_list (t, &TREE_OPERAND (try_fin, 1)); -- cgit v1.1