aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/f95-lang.c
diff options
context:
space:
mode:
authorTobias Burnus <burnus@net-b.de>2010-09-05 20:10:11 +0200
committerTobias Burnus <burnus@gcc.gnu.org>2010-09-05 20:10:11 +0200
commit433ce291b562b15ae197c373fb75bfa4944c1a02 (patch)
tree4d02d71598e853334e3a8c5d484b88da3249edf7 /gcc/fortran/f95-lang.c
parent226b53d2c179b8527abc1ce649fad94cc07aac71 (diff)
downloadgcc-433ce291b562b15ae197c373fb75bfa4944c1a02.zip
gcc-433ce291b562b15ae197c373fb75bfa4944c1a02.tar.gz
gcc-433ce291b562b15ae197c373fb75bfa4944c1a02.tar.bz2
re PR fortran/45186 (Gfortran 4.5.0 emits wrong linenumbers)
2010-09-05 Tobias Burnus <burnus@net-b.de> PR fortran/45186 * trans-intrinsic.c (gfc_conv_intrinsic_sign, gfc_conv_intrinsic_leadz): Use build_call_expr_loc instead of build_call_expr. * trans-expr.c (gfc_conv_expr_present, gfc_conv_missing_dummy, gfc_conv_string_length, gfc_conv_substring, gfc_conv_component_ref, gfc_conv_unary_op, gfc_conv_powi, gfc_conv_cst_int_power, gfc_conv_string_tmp, gfc_conv_concat_op, gfc_conv_expr_op, gfc_build_compare_string, gfc_set_interface_mapping_bounds, gfc_conv_subref_array_arg, gfc_conv_derived_to_class, conv_isocbinding_procedure, gfc_conv_procedure_call, fill_with_spaces, gfc_trans_string_copy, gfc_trans_alloc_subarray_assign, gfc_trans_structure_assign, gfc_trans_pointer_assignment, gfc_trans_scalar_assign, gfc_trans_zero_assign, gfc_trans_array_copy, gfc_trans_array_constructor_copy): Change fold_build[0-9] to fold_build[0-9]_loc. * trans-io.c (set_parameter_const, set_parameter_value, set_parameter_ref, gfc_convert_array_to_string, set_string, set_internal_unit, io_result, set_error_locus, nml_get_addr_expr, build_dt): Ditto. * trans-openmp.c (gfc_omp_clause_default_ctor, gfc_omp_clause_copy_ctor, gfc_omp_clause_assign_op, gfc_trans_omp_array_reduction, gfc_trans_omp_atomic, gfc_trans_omp_do): Ditto. * trans.c (gfc_add_modify, gfc_build_addr_expr, gfc_build_array_ref, gfc_trans_runtime_error_vararg, gfc_trans_runtime_check, gfc_call_malloc, gfc_allocate_with_status, gfc_allocate_array_with_status, gfc_call_free, gfc_deallocate_with_status, gfc_call_realloc): Ditto. From-SVN: r163879
Diffstat (limited to 'gcc/fortran/f95-lang.c')
-rw-r--r--gcc/fortran/f95-lang.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/gcc/fortran/f95-lang.c b/gcc/fortran/f95-lang.c
index c239702..8c957d2 100644
--- a/gcc/fortran/f95-lang.c
+++ b/gcc/fortran/f95-lang.c
@@ -200,17 +200,18 @@ gfc_truthvalue_conversion (tree expr)
return expr;
}
else if (TREE_CODE (expr) == NOP_EXPR)
- return fold_build1 (NOP_EXPR,
+ return fold_build1_loc (input_location, NOP_EXPR,
boolean_type_node, TREE_OPERAND (expr, 0));
else
- return fold_build1 (NOP_EXPR, boolean_type_node, expr);
+ return fold_build1_loc (input_location, NOP_EXPR, boolean_type_node,
+ expr);
case INTEGER_TYPE:
if (TREE_CODE (expr) == INTEGER_CST)
return integer_zerop (expr) ? boolean_false_node : boolean_true_node;
else
- return fold_build2 (NE_EXPR, boolean_type_node, expr,
- build_int_cst (TREE_TYPE (expr), 0));
+ return fold_build2_loc (input_location, NE_EXPR, boolean_type_node,
+ expr, build_int_cst (TREE_TYPE (expr), 0));
default:
internal_error ("Unexpected type in truthvalue_conversion");