OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [fortran/] [ChangeLog-2010] - Blame information for rev 712

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 712 jeremybenn
2010-12-31  Janus Weil  
2
 
3
        * intrinsic.texi (IANY): Correct section title.
4
        (IALL, IANY, IPARITY): Fix example codes.
5
 
6
2010-12-31  Thomas Koenig  
7
 
8
        PR fortran/47065
9
        * frontend-passes.c (count_arglist):  Static variable to
10
        count the nesting of argument lists.
11
        (optimize_code):  Set count_arglist to 1 if within a call
12
        statement, to 0 otherwise.
13
        (optimize_trim):  New function.
14
        (optimize_expr):  Adjust count_arglist.  Call optimize_trim.
15
 
16
2010-12-31  Thomas Koenig  
17
 
18
        PR fortran/45338
19
        * resolve.c (resolve_operator):  Mark function for user-defined
20
        operator as referenced.
21
 
22
2010-12-31  Janus Weil  
23
 
24
        PR fortran/46971
25
        * gfortran.h (gfc_hash_value): Add prototype.
26
        * class.c (get_unique_type_string): Check if proc_name is present and
27
        make sure string contains an underscore.
28
        (get_unique_hashed_string): New function which creates a hashed string
29
        if the given unique string is too long.
30
        (gfc_hash_value): Moved here from decl.c, renamed and simplified.
31
        (gfc_build_class_symbol, gfc_find_derived_vtab): Use hashed strings.
32
        * decl.c (hash_value): Moved to class.c.
33
        (gfc_match_derived_decl): Renamed 'hash_value'.
34
 
35
2010-12-30  Janus Weil  
36
 
37
        PR fortran/47085
38
        * match.c (gfc_match_allocate): Check for 'class_ok'.
39
        * primary.c (gfc_match_varspec): Ditto.
40
 
41
2010-12-29  Thomas Koenig  
42
 
43
        * dump_parse_tree.c (show_components):  Show
44
        ALLOCATABLE.
45
 
46
2010-12-29  Janus Weil  
47
 
48
        PR fortran/46838
49
        * expr.c (gfc_default_initializer): Handle allocatable CLASS components.
50
 
51
2010-12-29  Thomas Koenig  
52
 
53
        * frontend-passes.c (gfc_code_walker): Handle expressions
54
        in EXEC_CALL, EXEC_ASSIGN_CALL and EXEC_CALL_PPC.
55
        Separate cases in switch statements by blank lines.
56
 
57
2010-12-28  Janus Weil  
58
            Daniel Franke  
59
 
60
        PR fortran/45827
61
        * module.c (mio_component_ref): Handle components of CLASS variables.
62
 
63
2010-12-27  Thomas Koenig  
64
 
65
        * dump-parse-tree.c (show_typespec):  Also show character kind.
66
 
67
2010-12-24  Thomas Koenig  
68
 
69
        PR fortran/31821
70
        * check.c (gfc_var_strlen):  New function, also including
71
        substring references.
72
        (gfc_check_same_strlen):  Use gfc_var_strlen.
73
 
74
2010-12-23  Mikael Morin  
75
 
76
        PR fortran/46978
77
        Revert part of revision 164112
78
        * trans-array.c (gfc_trans_create_temp_array):
79
        Set loop n'th upper bound from (possibly transposed) array's dim bounds.
80
 
81
2010-12-18  Tobias Burnus  
82
 
83
        PR fortran/46974
84
        * target-memory.c (gfc_interpret_derived): Handle C_PTR/C_FUNPTR.
85
        * trans-expr.c (gfc_trans_structure_assign): Ditto.
86
        (gfc_conv_expr): Avoid crashes using non-C_NULL_(FUN)PTR const expr.
87
 
88
2010-12-17  Janus Weil  
89
            Tobias Burnus 
90
 
91
        PR fortran/46849
92
        * resolve.c (resolve_symbol): Remove symbols that wrongly ended up
93
        in a local BLOCK namespace.
94
 
95
2010-12-15  Jakub Jelinek  
96
 
97
        PR fortran/46945
98
        * trans-array.c (gfc_array_init_size): Perform stride overflow
99
        checking and multiplication by element_size in size_type_node instead
100
        of sizetype, return value with size_type_node type instead of
101
        sometimes with sizetype and sometimes with gfc_array_index_type.
102
 
103
2010-12-15  Janne Blomqvist  
104
 
105
        * trans.c (gfc_allocate_with_status): Better error message for
106
        malloc() failure.
107
        (gfc_call_realloc): Likewise.
108
        * misc.c (gfc_getmem): Likewise.
109
 
110
2010-12-15  Janne Blomqvist  
111
 
112
        PR fortran/28105
113
        * trans.c (gfc_call_malloc): Improve comment.
114
        (gfc_allocate_with_status): Remove size < 0 check.
115
        (gfc_call_realloc): Likewise.
116
 
117
2010-12-14  Tobias Burnus  
118
 
119
        PR fortran/46937
120
        * trans-types.c (create_fn_spec): "."-annotate derived types
121
        with (proc-)pointer components.
122
 
123
2010-12-14  Jakub Jelinek  
124
 
125
        PR fortran/46874
126
        * trans-openmp.c (gfc_trans_omp_array_reduction): Handle allocatable
127
        dummy variables.
128
 
129
2010-12-13  Janus Weil  
130
 
131
        PR fortran/46201
132
        * trans-expr.c (gfc_conv_procedure_call): Handle procedure pointer
133
        components called on a dimensionful base object.
134
 
135
2010-12-13  Janus Weil  
136
 
137
        PR fortran/46841
138
        * trans-expr.c (gfc_trans_subcomponent_assign): Handle array-valued
139
        procedure pointer components.
140
 
141
2010-12-13  Jakub Jelinek  
142
 
143
        PR fortran/46884
144
        * symbol.c (gfc_new_charlen): If old_cl is non-NULL, put it
145
        at the ns->old_cl_list spot in the chain rather than at
146
        ns->cl_list.
147
 
148
2010-12-12  Thomas Koenig  
149
 
150
        * dump-parse-tree.c (show_expr): Add space for parens.
151
 
152
2010-12-12  Janus Weil  
153
 
154
        PR fortran/46809
155
        * resolve.c (resolve_select_type): Set the location of the first
156
        argument when generating the EXTENDS_TYPE_OF call.
157
 
158
2010-12-11  Jerry DeLisle  
159
 
160
        PR fortran/46705
161
        * gfortran.h: New enum gfc_instring.
162
        (gfc_next_char_literal): Update prototype.
163
        * scanner.c (gfc_next_char_literal): Use new enum. Only give missing
164
        '&' warning for INSTRING_WARN. (gfc_next_char): Use new enum.
165
        (gfc_gobble_whitespace): Likewise.
166
        * io.c (next_char): Use new enum. (next_char_not_space): Likewise.
167
        (format_lex): Likewise.
168
        * match.c (gfc_match_parens): Likewise.
169
        (gfc_match_special_char): Likewise. (gfc_match_name_C): Likewise.
170
        * parse.c (next_fixed): Likewise.
171
        * primary.c (match_hollerith_constant): Likewise.
172
        (next_string_char): Likewise.
173
 
174
2010-12-11  Tobias Burnus  
175
 
176
        PR fortran/46370
177
        * primary.c (gfc_match_varspec): Pass information about codimension
178
        to gfc_match_array_ref also for BT_CLASS.
179
        * resolve.c (resolve_procedure): Correct check for C612.
180
 
181
2010-12-11  Mikael Morin   
182
            Jerry DeLisle  
183
 
184
        PR fortran/46842
185
        * trans-array.c (dim_ok): New helper function.
186
        (gfc_conv_expr_descriptor): Use new helper function to check
187
        function array is full.
188
 
189
2010-12-10  Tobias Burnus  
190
 
191
        PR fortran/46540
192
        * trans-types.c (gfc_init_kinds): Handle
193
        --disable-libquadmath-support.
194
 
195
2010-12-09  Steven G. Kargl  
196
 
197
        * check.c (gfc_check_sngl): Insert missing space in error message.
198
 
199
2010-12-09  Steven G. Kargl  
200
 
201
        * check.c (gfc_check_float): Insert missing space in error message.
202
 
203
2010-12-07  Tobias Burnus  
204
 
205
        PR fortran/44352
206
        * trans-expr.c (gfc_string_to_single_character): Return if not
207
        POINTER_TYPE_P.
208
        (gfc_trans_string_copy): gfc_build_addr_expr if src or dest is
209
        not a pointer.
210
        (gfc_trans_string_copy): Make sure the argument string type
211
        has a string length, fix indention, and remove not needed
212
        gfc_build_addr_expr.
213
 
214
2010-12-04  Daniel Kraft  
215
 
216
        PR fortran/46794
217
        * trans-expr.c (gfc_conv_power_op): Handle kind of result expression
218
        correctly for integer kind 1 and 2 operands.
219
 
220
2010-12-03  Thomas Koenig  
221
 
222
        PR fortran/44352
223
        * dump-parse-tree.c (show_symbol):  Don't show formal namespace
224
        for statement functions in order to avoid infinite recursion.
225
 
226
2010-12-03  Thomas Koenig  
227
 
228
        PR fortran/45159
229
        * dependency.c (check_section_vs_section):  Pre-calculate
230
        the relationship between the strides and the relationship
231
        between the start values.  Use an integer constant one for
232
        that purpose.
233
        Forward dependencies for positive strides apply for where
234
        the lhs start <= rhs start and lhs stride <= rhs stride
235
        and vice versa for negative stride.  No need to compare
236
        end expressions in either case (assume no bounds violation).
237
 
238
2010-12-03  Thomas Koenig  
239
 
240
        * trans-array.c (gfc_could_be_alias):  Handle BT_CLASS
241
        as well as BT_DERIVED.
242
        (gfc_array_allocate):  Likewise.
243
        (gfc_conv_array_parameter):  Likewise.
244
        (structure_alloc_comps):  Likewise.
245
        (gfc_is_reallocatable_lhs):  Likewise.
246
        (gfc_trans_deferred_array):  Likewise.
247
 
248
2010-12-02  Jakub Jelinek  
249
 
250
        PR fortran/46753
251
        * trans-openmp.c (gfc_trans_omp_do): Use build2_loc instead of
252
        fold_build2_loc for OMP_FOR conditions.
253
 
254
2010-11-30  Janne Blomqvist  
255
 
256
        PR fortran/28105
257
        * trans-array.c (gfc_unlikely): Helper function to mark boolean
258
        expr as unlikely.
259
        (gfc_array_index_size): Check whether the size overflows.
260
        (gfc_array_allocate): Check whether size overflows and generate
261
        error.
262
 
263
2010-11-30  Joseph Myers  
264
 
265
        * trans-common.c: Don't include toplev.h.
266
 
267
2010-11-29  Joseph Myers  
268
 
269
        * gfortran.h (alloca): Don't include definitions.
270
        (NULL): Don't define.
271
 
272
2010-11-28  Janus Weil  
273
 
274
        PR fortran/46662
275
        * resolve.c (update_ppc_arglist): Add check for abstract passed object.
276
 
277
2010-11-28  Paul Thomas  
278
 
279
         PR fortran/35810
280
        * trans-array.c (gfc_trans_array_constructor): If the loop->to
281
        is a VAR_DECL, assume this is dynamic. In this case, use the
282
        counter to obtain the value and set loop->to appropriately.
283
        (gfc_conv_ss_descriptor): Always save the offset of a variable
284
        in info.saved_offset.
285
        (gfc_conv_ss_startstride): Do not attempt bound checking of the
286
        lhs of an assignment, if allocatable and f2003 is allowed.
287
        (gfc_conv_loop_setup): If possible, do not use an allocatable
288
        lhs variable for the loopspec.
289
        (gfc_is_reallocatable_lhs): New function.
290
        (get_std_lbound): New function.
291
        (gfc_alloc_allocatable_for_assignment): New function.
292
        * gfortran.h : Add flag_realloc_lhs to the options structure.
293
        * lang.opt : Add option f(no-)realloc-lhs.
294
        * invoke.texi : Document option f(no-)realloc-lhs.
295
        * options.c (gfc_init_options, gfc_post_options,
296
        gfc_handle_option): Incorporate f(no-)realloc-lhs with default
297
        to frealloc_lhs for -std > f95.
298
        * trans-array.h : Add primitive for previous.
299
        * trans-expr.c (gfc_conv_string_length): Return if character
300
        length is a variable and the expression is NULL.
301
        (gfc_conv_procedure_call): If the call is of the kind x = f(...)
302
        and the lhs is allocatable and reallocation on assignment OK,
303
        call gfc_alloc_allocatable_for_assignment. Do not generate the
304
        function call unless direct by reference.
305
        (realloc_lhs_loop_for_fcn_call): New function.
306
        (realloc_lhs_bounds_for_intrinsic_call): New function.
307
        (gfc_trans_arrayfunc_assign): Reallocation assignments need
308
        a loopinfo and for the loop bounds to be set.  With intrinsic
309
        functions, free the lhs data and let the library allocate the
310
        data array. Done by the new functions above.
311
        (gfc_trans_assignment_1): If the lhs is allocatable and
312
        reallocation on assignment is allowed, mark the lhs and use
313
        gfc_alloc_allocatable_for_assignment to make the reallocation.
314
        * trans.h : Add is_alloc_lhs bitfield to gfc_ss structure.
315
 
316
2010-11-27  Tobias Burnus  
317
            Jerry DeLisle  
318
 
319
        PR fortran/46678
320
        trans-decl.c (gfc_trans_auto_character_variable): Use gfc_init_block
321
        instead of gfc_start_block.
322
 
323
2010-11-27  Jerry DeLisle  
324
 
325
        PR fortran/46301
326
        trans-expr.c (gfc_trans_assignment): Add error message for not
327
        implemented assignment to deferred-length character variable.
328
 
329
2010-11-26  Jakub Jelinek  
330
 
331
        PR bootstrap/45700
332
        * trans.h (build1_stat_loc, build2_stat_loc, build3_stat_loc,
333
        build4_stat_loc): Removed.
334
        (build1_loc, build2_loc, build3_loc, build4_loc): Removed.
335
 
336
2010-11-25  Janus Weil  
337
 
338
        PR fortran/46581
339
        * trans.h (gfc_process_block_locals): Removed second argument.
340
        * trans-decl.c (trans_associate_var): Moved to trans-stmt.c.
341
        (gfc_trans_deferred_vars): Skip ASSOCIATE variables.
342
        (gfc_process_block_locals): Don't mark associate names to be
343
        initialized.
344
        * trans-stmt.c (trans_associate_var): Moved here from trans-decl.c.
345
        (gfc_trans_block_construct): Call 'trans_associate_var' from here
346
        to make sure SELECT TYPE with associate-name is treated correctly.
347
 
348
2010-11-24  Tobias Burnus  
349
 
350
        PR fortran/46638
351
        * target-memory.c (gfc_interpret_derived): Correctly handle
352
        component offset.
353
 
354
2010-11-23  Tobias Burnus  
355
 
356
        PR fortran/46545
357
        * gfortran.texi (KIND Type Parameters): Quadmath and F2008 changes.
358
 
359
2010-11-22  Michael Matz  
360
 
361
        * gfortranspec.c (library): New global, moved from ...
362
        (lang_specific_driver): ... here.
363
        (lang_specific_pre_link): Test it here before including
364
        libgfortran.spec.
365
 
366
2010-11-21  Michael Matz  
367
            Tobias Burnus  
368
 
369
        PR driver/46516
370
        * gfortranspec.c (lang_specific_driver,
371
        lang_specific_pre_link): Load libgfortran.spec in
372
        lang_specific_pre_link unless found in the -L path.
373
 
374
2010-11-20  Janne Blomqvist  
375
 
376
        * f95-lang.c (gfc_init_decl_processing): Set size_type_node as
377
        unsigned int of pointer size and set sizetype based on that.
378
        * trans-types.c (gfc_init_types): Don't set size_type_node to an
379
        unsigned type.
380
 
381
2010-11-17  Joseph Myers  
382
 
383
        * f95-lang.c (gfc_be_parse_file): Take no arguments.
384
 
385
2010-11-16  Francois-Xavier Coudert  
386
            Tobias Burnus  
387
 
388
        PR fortran/32049
389
        * gfortranspec.c (find_spec_file): New function.
390
        (lang_specific_driver): Try to find .spec file and use it.
391
        * trans-io.c (iocall): Define IOCALL_X_REAL128/COMPLEX128(,write).
392
        (gfc_build_io_library_fndecls): Build decl for __float128 I/O.
393
        (transfer_expr): Call __float128 I/O functions.
394
        * trans-types.c (gfc_init_kinds): Allow kind-16 belonging
395
        to __float128.
396
 
397
2010-11-15  Tobias Burnus  
398
 
399
        PR fortran/46484
400
        * check.c (variable_check): Don't treat functions calls as variables;
401
        optionally accept function themselves.
402
        (gfc_check_all_any, gfc_check_loc, gfc_check_move_alloc,
403
        gfc_check_null, gfc_check_present, gfc_check_cpu_time,
404
        gfc_check_date_and_time, gfc_check_mvbits, gfc_check_random_number,
405
        gfc_check_random_seed, gfc_check_system_clock,
406
        gfc_check_dtime_etime, gfc_check_dtime_etime_sub,
407
        gfc_check_itime_idate,gfc_check_ltime_gmtime): Update call.
408
 
409
2010-11-13  Tobias Burnus  
410
 
411
        PR fortran/45742
412
        * trans-common.c (build_field): Add TREE_SIDE_EFFECTS for volatile.
413
        * trans-decl.c (gfc_finish_var_decl): Ditto.
414
        (create_function_arglist): Handle volatile dummy arguments.
415
 
416
2010-11-12  Joseph Myers  
417
 
418
        * Make-lang.in (gfortranspec.o): Use $(OPTS_H).
419
        * gfortran.h (gfc_handle_option): Take location_t parameter.
420
        * options.c (gfc_handle_option): Take location_t parameter.
421
 
422
2010-11-12  Jerry DeLisle  
423
 
424
        PR fortran/45794
425
        trans-expr.c (gfc_conv_procedure_call): Avoid NULL array spec.
426
 
427
2010-11-11  Nathan Froyd  
428
 
429
        PR c/44782
430
        * options.c (gfc_post_options): Initialize gfc_option.max_errors.
431
        (gfc_handle_option) [OPT_fmax_errors_]: Remove.
432
        * lang.opt (fmax-errors=): Remove.
433
 
434
2010-11-11  Steven G. Kargl 
435
 
436
        * symbol.c (verify_bind_c_derived_type):  Accept BIND(C) on an empty
437
        derived type.
438
 
439
2010-11-11  Jan Hubicka  
440
 
441
        * options.c (gfc_post_options): Remove flag_whopr.
442
 
443
2010-11-11  Tobias Burnus  
444
 
445
        PR fortran/46413
446
        * resolve.c (resolve_transfer): Reject I/O transfer of
447
        polymorphic type.
448
 
449
        PR fortran/46205
450
        * resolve.c (resolve_code): Reject nonscalar FORALL masks.
451
 
452
2010-11-11  Janus Weil  
453
 
454
        * resolve.c (resolve_procedure_interface): Copy 'is_bind_c' attribute.
455
 
456
2010-11-10  Joseph Myers  
457
 
458
        * trans-array.c (gfc_trans_deferred_array): Use "front-end"
459
        spelling in diagnostic.
460
        * trans.c (gfc_allocate_array_with_status): Add missing space in
461
        diagnostic.
462
 
463
2010-11-10  Joseph Myers  
464
 
465
        * cpp.c (asm_file_name): Don't declare here.
466
 
467
2010-11-10  Tobias Burnus  
468
 
469
        PR fortran/46411
470
        * intrinsic.c (gfc_intrinsic_sub_interface): Check for attr.pure
471
        and not for attr.elemental.
472
        * intrinsic.texi (move_alloc): Document as being pure.
473
 
474
2010-11-10  Tobias Burnus 
475
 
476
        PR fortran/46244
477
        * resolve.c (resolve_fl_derived): Don't allow CLASS in
478
        sequence/BIND(C) types.
479
 
480
2010-11-09  Jerry DeLisle  
481
            Mikael Morin   
482
 
483
        PR fortran/46331
484
        * intrinsic.c: Correctly set the pure attributes for intrinsic
485
        functions.
486
        * expr.c (check_specification_function): Remove this function and move
487
        its code into gfc_is_constant_expr. (gfc_is_constant_expr): Change the
488
        order of checks by checking for non-constant arguments first.  Then,
489
        check for initialization functions, followed by intrinsics.
490
 
491
2010-11-09  Janus Weil  
492
 
493
        PR fortran/46313
494
        * gfortran.h (gfc_add_data_component,gfc_add_vptr_component,
495
        gfc_add_hash_component,gfc_add_size_component,
496
        gfc_add_def_init_component): New macros.
497
        * class.c (gfc_add_component_ref): Renamed data component.
498
        (get_unique_type_string): New function.
499
        (gfc_build_class_symbol): Use 'get_unique_type_string' to construct
500
        uniques names for the class containers. Rename components.
501
        (gfc_find_derived_vtab): Use 'get_unique_type_string' to construct
502
        uniques names for the vtab symbols. Rename components.
503
        * decl.c (attr_decl1): Renamed class container components.
504
        * iresolve.c (gfc_resolve_extends_type_of): Ditto.
505
        * match.c (select_type_set_tmp): Renamed temporaries.
506
        * module.c (read_module): Renamed vtab and vtype symbols.
507
        * resolve.c (resolve_structure_cons,resolve_typebound_function,
508
        resolve_typebound_subroutine,resolve_deallocate_expr,
509
        resolve_select_type,resolve_fl_derived): Renamed class container and
510
        vtab components.
511
        * trans-array.c (structure_alloc_comps): Ditto.
512
        * trans-decl.c (gfc_trans_deferred_vars): Ditto.
513
        * trans-expr.c (gfc_conv_derived_to_class,gfc_conv_structure,
514
        gfc_trans_class_init_assign,gfc_trans_class_assign): Ditto.
515
        * trans-intrinsic.c (gfc_conv_intrinsic_sizeof,
516
        gfc_conv_intrinsic_storage_size,gfc_conv_allocated,gfc_conv_associated,
517
        gfc_conv_same_type_as): Ditto.
518
        * trans-stmt.c (gfc_trans_allocate): Ditto.
519
 
520
2010-11-08  Jerry DeLisle  
521
 
522
        PR fortran/43899
523
        * trans-decl.c (generate_local_decl): Do not generate unused warning
524
        for variables in namelists.
525
 
526
2010-11-08  Janus Weil  
527
 
528
        PR fortran/46344
529
        * decl.c (build_struct): Build vtab immediately if derived type
530
        has already been declared.
531
 
532
2010-11-08  Janus Weil  
533
 
534
        PR fortran/46344
535
        * trans-types.c (gfc_copy_dt_decls_ifequal): Handle CLASS components.
536
 
537
2010-11-06  Janus Weil  
538
 
539
        PR fortran/46330
540
        * trans-expr.c (gfc_trans_class_assign): Find 'vtab' symbol in correct
541
        namespace.
542
 
543
2010-11-05  Janus Weil  
544
 
545
        PR fortran/45451
546
        PR fortran/46174
547
        * class.c (gfc_find_derived_vtab): Improved search for existing vtab.
548
        Add component '$copy' to vtype symbol for polymorphic deep copying.
549
        * expr.c (gfc_check_pointer_assign): Make sure the vtab is generated
550
        during resolution stage.
551
        * resolve.c (resolve_codes): Don't resolve code if namespace is already
552
        resolved.
553
        * trans-stmt.c (gfc_trans_allocate): Call '$copy' procedure for
554
        polymorphic ALLOCATE statements with SOURCE.
555
 
556
2010-11-03  Thomas Koenig  
557
            Paul Thomas  
558
 
559
        * dump-parse-tree.c (code_indent):  Take label into acount
560
        when calculating indent.
561
        (show_typespec):  Also display class.
562
        (show_attr):  Add module name to argument.
563
        Don't show UNKNOWN for flavor, access and save. Don't show
564
        SAVE_NONE.  Don't show INTENT_UNKNOWN.  Show module for use
565
        association.  Show intent only for dummy arguments.
566
        Set length of shown symbol names to minimum of 12.
567
        Show attributes header.
568
        (show_symbol):  Adjust show_level.
569
        (show_symtree):  Clear up display for ambiguous.  Show if symbol
570
        was imported from namespace.
571
        (show_code_node):  Clear up indenting.  Traverse symtree and
572
        show code directly instead of calling show_namespace.
573
 
574
2010-11-02  Nathan Froyd  
575
 
576
        * trans-decl.c (add_argument_checking): Use build_zero_cst instead of
577
        fold_convert.
578
        * trans-expr.c (gfc_conv_missing_dummy, fill_with_spaces): Likewise.
579
        * trans-stmt.c (gfc_trans_do): Likewise.
580
 
581
2010-11-02  Steven G. Kargl  < kargl@gcc.gnu.org>
582
            Tobias Burnus  
583
 
584
        PR fortran/45170
585
        * array.c (gfc_match_array_constructor): Reject deferred type
586
        parameter (DTP) in type-spec.
587
        * decl.c (char_len_param_value, match_char_length,
588
        gfc_match_char_spec, build_sym, variable_decl,
589
        enumerator_decl): Support DTP.
590
        * expr.c (check_inquiry): Fix check due to support for DTP.
591
        * gfortran.h (gfc_typespec): Add Boolean 'deferred'.
592
        * misc.c (gfc_clear_ts): Set it to false.
593
        * match.c (gfc_match_allocate): Support DTP.
594
        * resolve.c (resolve_allocate_expr): Not-implemented error for DTP.
595
        (resolve_fl_variable): Add DTP constraint check.
596
        * trans-decl.c (gfc_trans_deferred_vars): Add not-implemented
597
        error for DTP.
598
 
599
2010-11-01  Steven G. Kargl  
600
 
601
        PR fortran/46152
602
        * fortran/match.c (match_derived_type_spec): Reoplace gfc_match_symbol
603
        with a gfc_find_symbol to prevent namespace pollution.  Remove dead
604
        code.
605
        (match_type_spec): Remove parsing of '::'.  Collapse character
606
        kind checking to one location.
607
        (gfc_match_allocate): Use correct locus in error message.
608
 
609
2010-10-30  Thomas Koenig  
610
 
611
        * gfortran.h (gfc_option_t):  Replace dump_parse_tree by
612
        dump_fortran_original and add dump_fortran_optimized.
613
        * lang.opt: Add fdump-fortran-original and
614
        fdump-fortran-optimized.  Document that fdump-parse-tree is
615
        deprecated.
616
        * gfortran.texi: Add -fdump-fortran-original and
617
        -fdump-fortran-optimized.  -fdump-parse-tree is deprecated.
618
        * frontend-passes.c (gfc_run_passes):  If optimizing and
619
        if gfc_option.dump_fortran_optimized is set, dump the parse tree
620
        after optimization.
621
        * parse.c:  Rename gfc_option.dump_parse_tree to
622
        gfc_option.dump_fortran_original.
623
        * options.c (gfc_init_options):  Rename gfc_option.dump_parse_tree
624
        to gfc_option.dump_fortran_original and handle
625
        gfc_option.dump_fortran_optimize.
626
        (gfc_post_options): Rename gfc_option.dump_parse_tree
627
        to gfc_option.dump_fortran_original.
628
        (gfc_handle_option):  Rename OPT_fdump_parse_tree to
629
        OPT_fdump_fortran_original and gfc_option.dump_parse_tree
630
        to gfc_option.dump_fortran_original.  Handle
631
        OPT_fdump_fortran_optimized.
632
 
633
2010-10-30  Janus Weil  
634
 
635
        PR fortran/44917
636
        PR fortran/44926
637
        PR fortran/46196
638
        * interface.c (count_types_test): Symmetrize type check.
639
        (generic_correspondence): Ditto.
640
 
641
2010-10-27  Janus Weil  
642
 
643
        PR fortran/46161
644
        * interface.c (compare_allocatable): Handle polymorphic allocatables.
645
        (compare_parameter): Add two error messages for polymorphic dummies.
646
 
647
2010-10-26  Janus Weil  
648
 
649
        PR fortran/42647
650
        * trans.h (gfc_deallocate_scalar_with_status): New prototype.
651
        * trans.c (gfc_deallocate_scalar_with_status): New function for
652
        deallocation of allocatable scalars.
653
        * trans-array.c (structure_alloc_comps): Call it here ...
654
        * trans-decl.c (gfc_trans_deferred_vars): ... here ...
655
        * trans-stmt.c (gfc_trans_deallocate): ... and here.
656
 
657
2010-10-26  Tobias Burnus  
658
 
659
        PR fortran/45451
660
        * trans-stmt.c (gfc_trans_allocate): Do a deep-copy for SOURCE=.
661
 
662
        PR fortran/43018
663
        * trans-array.c (duplicate_allocatable): Use size of type and not
664
        the size of the pointer to the type.
665
 
666
2010-10-25  Steven G. Kargl  
667
 
668
        PR fortran/46140
669
        * fortran/scanner.c (include_line): Check return value of load_file.
670
 
671
2010-10-23  Tobias Burnus  
672
 
673
        PR fortran/46122
674
        * expr.c (gfc_check_vardef_context): Fix PROTECTED check.
675
 
676
2010-10-21  Janus Weil  
677
 
678
        PR fortran/46060
679
        * match.h (gfc_matching_ptr_assignment): New global variable to indicate
680
        we're currently matching a (non-proc-)pointer assignment.
681
        * decl.c (match_pointer_init): Set it.
682
        * match.c (gfc_match_pointer_assignment): Ditto.
683
        * primary.c (matching_actual_arglist): New global variable to indicate
684
        we're currently matching an actual argument list.
685
        (gfc_match_actual_arglist): Set it.
686
        (gfc_match_varspec): Reject procedure pointer component calls with
687
        missing argument list.
688
 
689
2010-10-21  Janus Weil  
690
 
691
        PR fortran/46067
692
        * interface.c (gfc_compare_interfaces): Switch arguments of type
693
        comparison (important for polymorphic variables).
694
 
695
2010-10-21  Tobias Burnus  
696
 
697
        PR fortran/46100
698
        * expr.c (gfc_check_vardef_context): Treat pointer functions
699
        as variables.
700
 
701
2010-10-20  Jerry DeLisle  
702
 
703
        PR fortran/46079
704
        * trans_stmt.c (gfc_trans_stop): Fix whitespace.  Build a call to new
705
        F08 numeric stop function.
706
        * trans.h: Add declaration for gfor_fndecl_stop_numeric_f08.
707
        * trans-decl.c (gfc_build_builtin_function_decls): Build declaration
708
        for stop_numeric_f08.
709
 
710
2010-10-18  Jerry DeLisle  
711
 
712
        * gfortran.h: Remove definition of bt enumerator.
713
        * libgfortran.h: Add bt enumerator type alighned with defintion.
714
        Remove the dtype enumerator, no longer used.
715
        previously given in libgfortran/io.h
716
        * trans-types.c: Use new bt enumerator.
717
        * trans-io.c: Likewise.
718
 
719
2010-10-16  Thomas Koenig  
720
 
721
        * trans-io.c (gfc_build_io_library_fndecls):
722
        Array descriptor arguments to transfer_array can be
723
        dereferenced recursively.
724
 
725
2010-10-16  Thomas Koenig  
726
 
727
        PR fortran/20165
728
        PR fortran/31593
729
        PR fortran/43665
730
        * trans-io.c (enum iocall): Add IOCALL_X_INTEGER_WRITE,
731
        IOCALL_X_LOGICAL_WRITE, IOCALL_X_CHARACTER_WRITE,
732
        IOCALL_X_CHARACTER_WIDE_WRIE, IOCALL_X_REAL_WRITE,
733
        IOCALL_X_COMPLEX_WRITE and IOCALL_X_ARRAY_WRITE.
734
        (gfc_build_io_library_fndecls):  Add corresponding function
735
        decls.
736
        (transfer_expr):  If the current transfer is a READ, use
737
        the iocall with the original version, otherwise the version
738
        with _WRITE.
739
        (transfer_array_desc):  Likewise.
740
 
741
2010-10-15  Tobias Burnus  
742
 
743
        PR fortran/45186
744
        * trans.h (gfc_add_modify_loc, gfc_evaluate_now_loc): New prototypes.
745
        (gfc_trans_runtime_error_vararg): Remove prototype.
746
        * trans.c (gfc_add_modify_loc, gfc_evaluate_now_loc): New functions.
747
        (gfc_add_modify, gfc_evaluate_now): Use them.
748
        (trans_runtime_error_vararg): Renamed from
749
        gfc_trans_runtime_error_vararg, made static and use locus.
750
        (gfc_trans_runtime_error): Use it.
751
        (gfc_trans_runtime_check): Ditto and make use of locus.
752
        * trans-stmt.c (gfc_trans_if_1, gfc_trans_simple_do,
753
        gfc_trans_do, gfc_trans_do_while): Improve line number
754
        associated with generated expressions.
755
 
756
2010-10-12  Daniel Kraft  
757
 
758
        PR fortran/38936
759
        * parse.c (parse_associate): Set typespec of associate-name if that of
760
        the target is already available.
761
 
762
2010-10-10  Janus Weil  
763
 
764
        PR fortran/45961
765
        * resolve.c (resolve_typebound_function): Bugfix for type-bound
766
        operators.
767
 
768
2010-10-09  Thomas Koenig  
769
 
770
        * frontend-passes.c:  Include opts.h.
771
        (optimize_comparison):  Renamed from optimize_equality.
772
        Change second argument to operation to be compared.
773
        Use flag_finite_math_only to avoid comparing REAL and
774
        COMPLEX only when NANs are honored.  Simplify comparing
775
        of string concatenations where left or right operands are
776
        equal.  Simplify all comparison operations, based on the result
777
        of gfc_dep_compare_expr.
778
        * dependency.c:  Include arith.h.
779
        (gfc_are_identical_variables):  Volatile variables should not
780
        compare equal to themselves.
781
        (gfc_dep_compare_expr):  Handle string constants and string
782
        concatenations.
783
 
784
2010-10-08  Joseph Myers  
785
 
786
        * f95-lang.c (LANG_HOOKS_INIT_OPTIONS_STRUCT): Define.
787
        * gfortran.h (gfc_init_options_struct): Declare.
788
        * options.c (gfc_init_options_struct): New.  Split out from
789
        gfc_init_options.
790
 
791
2010-10-07  Janus Weil  
792
 
793
        PR fortran/45933
794
        * resolve.c (resolve_typebound_function): Use correct declared type
795
        for type-bound operators.
796
 
797
2010-10-07  Mikael Morin  
798
 
799
        PR fortran/45916
800
        Revert revision 165026:
801
        2010-10-06  Mikael Morin  
802
 
803
        * decl.c (match_procedure_in_type): Assertify if conditions.
804
 
805
2010-10-06  Jerry DeLisle  
806
 
807
        PR fortran/45889
808
        * resolve.c (resolve_transfer): Use expression inside parenthesis to
809
        find acutal component to be transgferred.
810
 
811
2010-10-06  Mikael Morin  
812
 
813
        * trans-stmt.c (gfc_trans_allocate): free lhs expr.
814
 
815
2010-10-06  Mikael Morin  
816
 
817
        * trans-array.c (gfc_free_ss_chain): Made non-static.
818
        * trans-array.h (gfc_free_ss_chain): New prototype.
819
        * trans-stmt.c (gfc_trans_where_2): Free ss chains.
820
 
821
2010-10-06  Mikael Morin  
822
 
823
        * trans-intrinsic.c (gfc_conv_intrinsic_funcall): Also free symbol's
824
        subcomponents.
825
 
826
2010-10-06  Mikael Morin  
827
 
828
        * trans-stmt.c (gfc_trans_forall_1): Free forall struct at the end.
829
 
830
2010-10-06  Mikael Morin  
831
 
832
        * trans-expr.c (get_proc_ptr_comp): Restore initial expression type
833
        before calling gfc_free_expr.
834
 
835
2010-10-06  Mikael Morin  
836
 
837
        * trans-array.c (gfc_conv_tmp_array_ref): Add factorized call to
838
        gfc_advance_se_ss_chain.
839
        * trans-expr.c (gfc_conv_subref_array_ref, gfc_conv_procedure_call,
840
        gfc_conv_array_constructor_expr, gfc_trans_assignment_1): Remove
841
        calls to gfc_advance_se_ss_chain after gfc_conv_tmp_array_ref.
842
        * trans-intrinsic.c (gfc_conv_intrinsic_function): Ditto.
843
        * trans-stmt.c (gfc_trans_where_assign, gfc_trans_where_3): Ditto.
844
 
845
2010-10-06  Mikael Morin  
846
 
847
        * trans.c (gfc_restore_backend_locus): New function.
848
        (gfc_get_backend_locus): Renamed to ...
849
        (gfc_save_backend_locus): ... this.
850
        * trans.h (gfc_restore_backend_locus, gfc_get_backend_locus,
851
        gfc_save_backend_locus): Same.
852
        * trans-array.c (gfc_trans_g77_array, gfc_trans_dummy_array_bias,
853
        gfc_trans_deferred_array): Rename gfc_get_backend_locus to
854
        gfc_save_backend_locus.
855
        (gfc_trans_dummy_array_bias): Call gfc_restore_backend_locus at the
856
        end.
857
        (gfc_trans_g77_array, gfc_trans_deferred_array): Use
858
        gfc_restore_backend_locus instead of gfc_set_backend_locus.
859
        (gfc_trans_deferred_array): Call gfc_restore_backend_locus on early
860
        return.
861
        * trans-decl.c (gfc_get_extern_function_decl, build_entry_thunks,
862
        gfc_trans_deferred_vars):
863
        Rename gfc_get_backend_locus to gfc_save_backend_locus.
864
        Use gfc_restore_backend_locus insted of gfc_set_backend_locus.
865
 
866
2010-10-06  Mikael Morin  
867
 
868
        * trans-array.c (gfc_build_constant_array_constructor): Free array
869
        spec when done.
870
 
871
2010-10-06  Mikael Morin  
872
 
873
        * symbol.c (gfc_copy_formal_args_ppc): Free previous formal arg list
874
        before overwriting it.
875
 
876
2010-10-06  Mikael Morin  
877
 
878
        * array.c (gfc_match_array_spec): Don't re-initialize cleared struct.
879
        * symbol.c (gen_shape_param): Ditto.
880
 
881
2010-10-06  Mikael Morin  
882
 
883
        * symbol.c (free_entry_list): New function.
884
        (gfc_free_namespace): Free list of entries.
885
 
886
2010-10-06  Mikael Morin  
887
 
888
        * symbol.c (free_components): Free list of formal args and formal
889
        namespace.
890
 
891
2010-10-06  Mikael Morin  
892
 
893
        * simplify.c (gfc_simplify_size): Clear temporary mpz int before
894
        returning.
895
 
896
2010-10-06  Mikael Morin  
897
 
898
        * resolve.c (add_dt_to_dt_list): Remove unneeded if.
899
 
900
2010-10-06  Mikael Morin  
901
 
902
        * resolve.c (check_typebound_baseobject): Free local expr before
903
        returning.
904
 
905
2010-10-06  Mikael Morin  
906
 
907
        * primary.c (gfc_match_structure_constructor): Invert the assert logic.
908
 
909
2010-10-06  Mikael Morin  
910
 
911
        * primary.c (gfc_free_structure_ctor_component): Also free the
912
        component structure itself.
913
 
914
2010-10-06  Mikael Morin  
915
 
916
        * module.c (gfc_use_module): Free atom_string when done with it.
917
 
918
2010-10-06  Mikael Morin  
919
 
920
        * module.c (read_module): Remove useless string duplication.
921
 
922
2010-10-06  Mikael Morin  
923
 
924
        * gfortranspec.c (append_arg): Remove commented code.
925
 
926
2010-10-06  Mikael Morin  
927
 
928
        * decl.c (match_procedure_in_type): Assertify if conditions.
929
 
930
2010-10-06  Mikael Morin  
931
 
932
        * cpp.c (gfc_cpp_post_options): Don't create a cpp reader if
933
        preprocessing is disabled.
934
 
935
2010-10-06  Jakub Jelinek  
936
 
937
        PR middle-end/45838
938
        * f95-lang.c (ATTR_NOTHROW_LEAF_LIST, ATTR_CONST_NOTHROW_LEAF_LIST,
939
        ATTR_NOTHROW_LIST, ATTR_CONST_NOTHROW_LIST): Define.
940
        (gfc_define_builtin): Change last argument to int bitmask from bool,
941
        control addition of TREE_NOTHROW and leaf attribute as well.
942
        (DO_DEFINE_MATH_BUILTIN): Adjust callers.
943
        (gfc_init_builtin_functions): Likewise.  Remove
944
        ATTR_{,CONST_}NOTHROW_LIST enum.
945
 
946
2010-10-04  Andi Kleen 
947
 
948
        * Make-lang.in (gfortran, f951): Add + to build rule.
949
 
950
2010-10-04  Richard Guenther  
951
 
952
        * f95-lang.c (current_translation_unit): New global variable.
953
        (gfc_create_decls): Build a translation-unit decl.
954
        (pushdecl): In the global binding-level use the
955
        translation-unit decl as DECL_CONTEXT.
956
        * trans-decl.c (gfc_get_symbol_decl): Use DECL_FILE_SCOPE_P.
957
        (build_function_decl): Likewise.  Delay setting the assembler
958
        name, leave setting of DECL_CONTEXT to pushdecl.
959
        (trans_function_start): Use DECL_FILE_SCOPE_P.
960
        (gfc_create_module_variable): Likewise.  Remove questionable
961
        asserts.
962
        * trans.c (gfc_generate_module_code): Likewise.
963
 
964
2010-10-03  Francois-Xavier Coudert  
965
 
966
        * cpp.c (cpp_define_builtins): Call functions from cppbuiltin.c
967
        instead of duplicating code.
968
        * Make-lang.in: Add dependency on cppbuiltin.h. Don't define
969
        BASEVER.
970
 
971
2010-10-02  Janus Weil  
972
 
973
        PR fortran/45748
974
        * resolve.c (resolve_formal_arglist): Avoid setting default type for
975
        formal arguments of intrinsic procedures.
976
 
977
2010-09-30  Janus Weil  
978
 
979
        PR fortran/45828
980
        * resolve.c (resolve_allocate_expr): Do not use
981
        'gfc_has_default_initializer'.
982
 
983
2010-09-30  Tobias Burnus  
984
 
985
        * gfortran.tex (Fortran 2008 status): Update list of
986
        implemented features.
987
 
988
2010-09-29  Joseph Myers  
989
 
990
        * lang.opt: Don't use VarExists.
991
 
992
2010-09-29  Joseph Myers  
993
 
994
        * cpp.c (cpp_define_builtins): Update names of gfc_option_t
995
        members.
996
        (gfc_cpp_post_options): Update names of cpp_options members.
997
        (cb_cpp_error): Update names of diagnostic_context members.
998
        * f95-lang.c (gfc_init_builtin_functions): Update names of
999
        gfc_option_t members.
1000
        * gfortran.h (gfc_option_t): Rename warn_conversion and
1001
        flag_openmp.
1002
        * intrinsic.c (gfc_convert_type_warn): Update names of
1003
        gfc_option_t members.
1004
        * options.c (gfc_init_options, gfc_post_options, set_Wall,
1005
        gfc_handle_option): Update names of gfc_option_t members.
1006
        * parse.c (next_free, next_fixed): Update names of gfc_option_t
1007
        members.
1008
        * scanner.c (pedantic): Remove extern declaration.
1009
        (skip_free_comments, skip_fixed_comments, include_line): Update
1010
        names of gfc_option_t members.
1011
        * trans-decl.c (gfc_generate_function_code): Update names of
1012
        gfc_option_t members.
1013
 
1014
2010-09-28  Tobias Burnus  
1015
 
1016
        PR fortran/40569
1017
        PR fortran/40568
1018
        * intrinsic.c (add_functions): Make compiler_version and
1019
        compiler_options CLASS_INQUIRY.
1020
        * gfortran.h (gfc_get_option_string): New prototype.
1021
        * intrinsic.texi (COMPILER_VERSION, COMPILER_OPTIONS):
1022
        Add documentation.
1023
        (C_SIZEOF): Mark as inquiry function of ISO_C_BINDING.
1024
        (ISO_FORTRAN_ENV): Refer to COMPILER_VERSION and COMPILER_OPTIONS.
1025
        (ISO_C_BINDING): Refer to C_SIZEOF.
1026
        * options.c (gfc_get_option_string): New function.
1027
        * simplify.c (gfc_simplify_compiler_options): Use it.
1028
        (gfc_simplify_compiler_version): Include compiler name.
1029
 
1030
2010-09-28  Jan Hubicka  
1031
 
1032
        * f95-lang.c (gfc_define_builtin): Make leaf.
1033
        (gfc_init_builtin_functions): Handle only ATTR_CONST_NOTHROW_LEAF_LIST
1034
        and ATTR_NOTHROW_LEAF_LIST.
1035
        (DEF_SYNC_BUILTIN): Check ATTR_CONST_NOTHROW_LEAF_LIST.
1036
        (DEF_GOMP_BUILTIN): Likewise.
1037
 
1038
2010-09-28  Tobias Burnus  
1039
 
1040
        PR fortran/45756
1041
        * trans-decl.c (gfc_get_symbol_decl): Use gsym for decl of
1042
        module parameters.
1043
 
1044
2010-09-27  Tobias Burnus  
1045
 
1046
        PR fortran/40569
1047
        PR fortran/40568
1048
        * intrinsic.h (gfc_simplify_compiler_options,
1049
        gfc_simplify_compiler_version): New prototypes.
1050
        * intrinsic.c (gfc_intrinsic_function_by_id,
1051
        make_from_module): New functions.
1052
        (gfc_find_function, gfc_find_subroutine, gfc_generic_intrinsic,
1053
        gfc_specific_intrinsic): Don't return module intrinsics.
1054
        (add_functions): Add compiler_options, compiler_version.
1055
        (gfc_intrinsic_func_interface): Also lookup symbol by ISYM ID.
1056
        * symbol.c (std_for_isocbinding_symbol): Add version check for
1057
        NAMED_FUNCTIONS.
1058
        * iso-fortran-env.def: Add compiler_options, compiler_version.
1059
        * iso-c-binding.def: Add c_sizeof.
1060
        * gfortran.h (gfc_intrinsic_sym): Add from_module:1.
1061
        (iso_c_binding_symbol, iso_fortran_env_symbol): Add NAMED_FUNCTIONS.
1062
        (gfc_intrinsic_function_by_id): New prototype.
1063
        * module.c (create_intrinsic_function): New function.
1064
        (import_iso_c_binding_module, use_iso_fortran_env_module): Use it.
1065
        * trans-types.c (init_c_interop_kinds): Add NAMED_FUNCTIONS.
1066
        * resolve.c (resolve_intrinsic): Try also to resolve intrinsics
1067
        by ISYM ID.
1068
        * simplify.c (gfc_simplify_compiler_options,
1069
        gfc_simplify_compiler_version): New functions.
1070
 
1071
2010-09-26  Daniel Kraft  
1072
 
1073
        PR fortran/45783
1074
        PR fortran/45795
1075
        * resolve.c (resolve_select_type): Clarify code.
1076
        (resolve_assoc_var): Only set typespec if it is currently unknown.
1077
 
1078
2010-09-26  Jerry DeLisle  
1079
 
1080
        PR fortran/45793
1081
        * module.c (create_int_parameter_array): Set the array value shape.
1082
 
1083
2010-09-25  Tobias Burnus  
1084
 
1085
        * gfortran.texi: Re-add accidently removed \input line.
1086
 
1087
2010-09-25  Daniel Kraft  
1088
 
1089
        PR fortran/45776
1090
        * gfortran.h (struct gfc_dt): New member `dt_io_kind'.
1091
        * io.c (resolve_tag): F2008 check for NEWUNIT and variable
1092
        definition checks for NEWUNIT, IOSTAT, SIZE and IOMSG.
1093
        (gfc_free_dt): Correctly handle freeing of `dt_io_kind' and
1094
        `extra_comma' with changed semantics.
1095
        (gfc_resolve_dt): Check variable definitions.
1096
        (match_io_element): Remove INTENT and PURE checks here and
1097
        initialize code->ext.dt member.
1098
        (match_io): Set dt->dt_io_kind.
1099
        (gfc_resolve_inquire): Check variable definition for all tags
1100
        except UNIT, FILE and ID.
1101
        * resolve.c (resolve_transfer): Variable definition check.
1102
 
1103
2010-09-25  Tobias Burnus  
1104
 
1105
        * interface.c (gfc_match_end_interface): Constify char pointer
1106
        to fix warning.
1107
 
1108
2010-09-24  Steven G. Kargl  < kargl@gcc.gnu.org>
1109
 
1110
        * interface.c (gfc_match_end_interface): Deal with user defined
1111
        operators that overload rational operators and C1202.
1112
 
1113
2010-09-24  Tobias Burnus  
1114
 
1115
        * gfortran.texi: Add second space after end-of-sentence period;
1116
        change / to /@/ to allow hyphenation of URLs.
1117
        (Standards): Remove duplicated OpenMP, update wording given that
1118
        Fortran 2008 now released.
1119
        (Fortran 2008 status): Update and add list of implemented features.
1120
 
1121
2010-09-24  Tobias Burnus  
1122
 
1123
        PR fortran/40571
1124
        * iso-fortran-env.def: Add NAMED_KINDARRAY with
1125
        character_kinds, integer_kinds, logical_kinds and
1126
        real_kinds.
1127
        * gfortran.h: Add them to iso_fortran_env_symbol.
1128
        * libgfortran.h: Rename GFC_INQUIRE_INTERNAL_UNIT to
1129
        LIBERROR_INQUIRE_INTERNAL_UNIT and move it from
1130
        libgfortran_stat_codes to libgfortran_error_codes.
1131
        * module.c (create_int_parameter_array): New function.
1132
        (use_iso_fortran_env_module): Use it for
1133
        NAMED_KINDARRAY of iso-fortran-env.def.
1134
        * trans-decl.c (gfc_get_symbol_decl): Parameter
1135
        arrays of intrinsics modules become local static variables.
1136
        * intrinsic.texi (ISO_FORTRAN_ENV): Add character_kinds,
1137
        integer_kinds, logical_kinds and real_kinds.
1138
 
1139
2010-09-23  Thomas Koenig  
1140
 
1141
        PR fortran/45744
1142
        * frontend-passes.c (optimize_binop_array_assignment):
1143
        Only re-use lhs as intermediate storage if kind and type
1144
        parameters match.
1145
 
1146
2010-09-23  Mikael Morin  
1147
 
1148
        PR fortran/45745
1149
        PR fortran/45648
1150
        * trans-array.c (gfc_conv_expr_descriptor): Handle
1151
        ss->type == GFC_SS_INTRINSIC (for {l,u}bound intrinsics) case.
1152
 
1153
2010-09-23  Tobias Burnus  
1154
 
1155
        * intrinsic.texi (OpenMP modules): Add named constants of
1156
        OMP_LIB.
1157
 
1158
2010-09-23  Daniel Kraft  
1159
 
1160
        PR fortran/38936
1161
        PR fortran/44044
1162
        PR fortran/45474
1163
        * gfortran.h (gfc_check_vardef_context): New method.
1164
        (struct symbol_attribute): New flag `select_type_temporary'.
1165
        * primary.c (gfc_variable_attr): Clarify initialization of ref.
1166
        (match_variable): Remove PROTECTED check and assignment check
1167
        for PARAMETERs (this is now done later).
1168
        * match.c (gfc_match_iterator): Remove INTENT(IN) check.
1169
        (gfc_match_associate): Defer initialization of newAssoc->variable.
1170
        (gfc_match_nullify): Remove PURE definability check.
1171
        (select_type_set_tmp): Set new `select_type_temporary' flag.
1172
        * expr.c (gfc_check_assign): Remove INTENT(IN) check here.
1173
        (gfc_check_pointer_assign): Ditto (and other checks removed).
1174
        (gfc_check_vardef_context): New method.
1175
        * interface.c (compare_parameter_protected): Removed.
1176
        (compare_actual_formal): Use `gfc_check_vardef_context' for checks
1177
        related to INTENT([IN]OUT) arguments.
1178
        * intrinsic.c (check_arglist): Check INTENT for intrinsics.
1179
        * resolve.c (gfc_resolve_iterator): Use `gfc_check_vardef_context'.
1180
        (remove_last_array_ref): New method.
1181
        (resolve_deallocate_expr), (resolve_allocate_expr): Ditto.
1182
        (resolve_allocate_deallocate): Ditto (for STAT and ERRMSG).
1183
        (resolve_assoc_var): Remove checks for definability here.
1184
        (resolve_select_type): Handle resolving of code->block here.
1185
        (resolve_ordinary_assign): Remove PURE check.
1186
        (resolve_code): Do not resolve code->blocks for SELECT TYPE here.
1187
        Use `gfc_check_vardef_context' for assignments and pointer-assignments.
1188
 
1189
2010-08-22  Ralf Wildenhues  
1190
 
1191
        * gfortran.texi (Argument list functions): Allow URL to wrap.
1192
        * intrinsic.texi (GETGID, GETPID, GETUID, IMAGE_INDEX)
1193
        (IS_IOSTAT_END, IS_IOSTAT_EOR, NUM_IMAGES, THIS_IMAGE)
1194
        (ISO_FORTRAN_ENV): Fix markup in index entries, and a couple of
1195
        code markups in the text.
1196
        * invoke.texi (Fortran Dialect Options)
1197
        (Error and Warning Options, Directory Options, Code Gen Options):
1198
        Likewise.  Remove @code inside @smallexample.
1199
 
1200
2010-09-22  Joseph Myers  
1201
 
1202
        * gfortranspec.c (lang_specific_driver): Handle OPT__version and
1203
        OPT__help instead of OPT_fversion and OPT_fhelp.
1204
        * lang.opt (-all-warnings, -assert, -assert=, -comments,
1205
        -comments-in-macros, -define-macro, -define-macro=, -dependencies,
1206
        -dump, -dump=, -include-barrier, -include-directory,
1207
        -include-directory=, -include-directory-after,
1208
        -include-directory-after=, -include-prefix, -include-prefix=,
1209
        -no-line-commands, -no-standard-includes, -output, -output=,
1210
        -preprocess, -print-missing-file-dependencies, -trace-includes,
1211
        -undefine-macro, -undefine-macro=, -user-dependencies, -verbose,
1212
        -write-dependencies, -write-user-dependencies): New.
1213
 
1214
2010-09-21  Jason Blevins  
1215
 
1216
        * intrinsics.texi (HYPOT, IMAGE_INDEX, BESSEL_JN, BESSEL_YN,
1217
        execute_command_line, IEOR, IOR, NORM2, NOT, NULL, PARITY):
1218
        Correct spelling.
1219
 
1220
2010-09-21  Mikael Morin  
1221
 
1222
        PR fortran/45648
1223
        * trans-array.c (gfc_conv_expr_descriptor): Calculate dim out of n and
1224
        info->dim.
1225
 
1226
        PR fortran/45648
1227
        * trans-array.c (gfc_conv_expr_descriptor): Unset full if we are
1228
        accessing dimensions in reversed order.
1229
 
1230
        PR fortran/45648
1231
        * trans-array.c (gfc_conv_expr_descriptor): Special case noncopying
1232
        intrinsic function call.
1233
 
1234
        * trans-array.c (gfc_conv_expr_descriptor): Remove ss lookup.
1235
        Update asserts accordingly.
1236
 
1237
        PR fortran/45648
1238
        * trans.h (gfc_se): New field force_tmp.
1239
        * trans-expr.c (gfc_conv_procedure_call): Check for argument alias
1240
        and set parmse.force_tmp if some alias is found.
1241
        * trans-array.c (gfc_conv_expr_descriptor): Force a temporary creation
1242
        if se->force_tmp is set.
1243
 
1244
2010-09-20  Janus Weil  
1245
 
1246
        PR fortran/45438
1247
        * trans-expr.c (gfc_conv_procedure_call): Fix pointer checking for
1248
        TBPs, PPCs and pointer/allocatable components.
1249
 
1250
2010-09-20  Paul Thomas  
1251
 
1252
        PR fortran/45081
1253
        * simplify.c (is_constant_array_expr): Allow structure array
1254
        elements as well as constants.
1255
        (gfc_simplify_pack, gfc_simplify_reshape, gfc_simplify_spread,
1256
        gfc_simplify_transpose, gfc_simplify_unpack): Copy the derived
1257
        type of source to the result.
1258
 
1259
2010-09-19  Thomas Koenig  
1260
 
1261
        * frontend-passes.c (gfc_expr_walker):  Also
1262
        handle EXPR_SUBSTRING.
1263
 
1264
2010-09-19  Thomas Koenig  
1265
 
1266
        * frontend-passes.c (gfc_expr_walker):  Handle
1267
        constructors and references.
1268
 
1269
2010-09-16  Tobias Burnus  
1270
 
1271
        PR fortran/43665
1272
        * trans-types.c (create_fn_spec): New function.
1273
        (gfc_get_function_type): Call it.
1274
 
1275
2010-09-16  Jakub Jelinek  
1276
 
1277
        * gfortran.h (walk_code_fn_t, walk_expr_fn_t): New types.
1278
        (gfc_expr_walker, gfc_code_walker): New prototypes.
1279
        * frontend-passes.c (gfc_expr_walker, gfc_code_walker): New functions.
1280
        (WALK_SUBEXPR, WALK_SUBEXPR_TAIL, WALK_SUBCODE): Define.
1281
        (optimize_namespace): Use gfc_code_walker.
1282
        (optimize_code, optimize_expr): Rewritten as gfc_code_walker hooks.
1283
        (optimize_expr_0, optimize_code_node,
1284
        optimize_actual_arglist): Removed.
1285
        (optimize_assignment): Don't call optimize_expr_0.
1286
 
1287
2010-09-16  Janus Weil  
1288
 
1289
        PR fortran/45674
1290
        * interface.c (compare_parameter): Create vtab for actual argument,
1291
        instead of formal (if needed).
1292
 
1293
2010-09-15  Janus Weil  
1294
 
1295
        PR fortran/45577
1296
        * resolve.c (resolve_allocate_expr): Do default initialization via
1297
        EXEC_INIT_ASSIGN.
1298
 
1299
2010-09-11  Francois-Xavier Coudert  
1300
 
1301
        * mathbuiltins.def: Do not defined huge_val built-in.
1302
        * trans-const.c (gfc_build_inf_or_huge): New function.
1303
        * trans-const.h (gfc_build_inf_or_huge): New prototype.
1304
        * f95-lang.c (gfc_init_builtin_functions): Don't defined
1305
        huge_val built-ins.
1306
        * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): We don't
1307
        have functions of type (*) (void) anymore.
1308
        (gfc_conv_intrinsic_minmaxloc): Call gfc_build_inf_or_huge.
1309
        (gfc_conv_intrinsic_nearest): Call gfc_build_inf_or_huge instead
1310
        of generating a call to huge_val().
1311
 
1312
2010-09-11  Mikael Morin  
1313
 
1314
        * gfortran.h (gfc_expr): Remove inline_noncopying_intrinsic attribute.
1315
        * dependency.c (gfc_check_dependency): Don't depend on
1316
        expr's inline_noncopying_intrinsic_attribute.
1317
        * dependency.c (gfc_check_argument_var_dependency,
1318
        gfc_check_argument_dependency): Ditto. Recursively check dependency
1319
        as NOT_ELEMENTAL in the non-copying (=transpose) case.
1320
        * trans-intrinsic.c (gfc_conv_intrinsic_function): Ditto.
1321
        * resolve.c (find_noncopying_intrinsics): Remove.
1322
        (resolve_function, resolve_call): Remove call to
1323
        find_noncopying_intrinsics.
1324
 
1325
        * trans-array.c (gfc_conv_array_transpose): Remove.
1326
        (gfc_walk_subexpr): Make non-static. Move prototype...
1327
        * trans-array.h (gfc_walk_subexpr): ... here.
1328
        * trans-intrinsic.c (gfc_conv_intrinsic_function): Update transpose
1329
        handling.
1330
        (walk_inline_intrinsic_transpose, walk_inline_intrinsic_function,
1331
        gfc_inline_intrinsic_function_p): New.
1332
        (gfc_is_intrinsic_libcall): Return early in inline intrinsic case.
1333
        Remove transpose from the libcall list.
1334
        (gfc_walk_intrinsic_function): Special case inline intrinsic.
1335
        * trans.h (gfc_inline_intrinsic_function_p): New prototype.
1336
 
1337
2010-09-10  Mikael Morin  
1338
 
1339
        * trans-expr.c (expr_is_variable): New function taking non-copying
1340
        intrinsic functions into account.
1341
        (gfc_trans_assignment_1): Use expr_is_variable.
1342
 
1343
2010-09-10  Mikael Morin  
1344
 
1345
        * trans-array.c (gfc_conv_loop_setup): Access the shape along the
1346
        real array dimension instead of the scalarizer (loop) dimension.
1347
 
1348
2010-09-10  Mikael Morin  
1349
 
1350
        * trans-array.c (gfc_conv_resolve_dependencies): Handle same-array
1351
        transposed references.
1352
 
1353
2010-09-10  Tobias Burnus  
1354
 
1355
        PR fortran/45186
1356
        * trans.h (build1_stat_loc, build2_stat_loc, build3_stat_loc,
1357
        build4_stat_loc): New inline functions.
1358
        (build1_loc, build2_loc, build3_loc, build4_loc): New macros.
1359
        (build1_v, build2_v, build3_v, build4_v): Use input_location
1360
        as locus.
1361
        * trans-array.c (gfc_trans_scalarized_loop_end,
1362
        gfc_conv_array_parameter): Replace build[1-4] by build[1-4]_loc.
1363
        * trans.c (gfc_build_addr_expr, gfc_build_array_ref,
1364
        gfc_finish_wrapped_block): Ditto.
1365
        * trans-decl.c (gfc_init_default_dt, init_intent_out_dt): Ditto.
1366
        * trans-expr.c (gfc_conv_missing_dummy,
1367
        gfc_trans_alloc_subarray_assign, gfc_trans_zero_assign): Ditto.
1368
        * trans-openmp.c (gfc_omp_clause_default_ctor,
1369
        gfc_trans_omp_critical, gfc_trans_omp_parallel,
1370
        gfc_trans_omp_parallel_do, gfc_trans_omp_parallel_sections,
1371
        gfc_trans_omp_parallel_workshare, gfc_trans_omp_sections
1372
        gfc_trans_omp_single, gfc_trans_omp_task,
1373
        gfc_trans_omp_workshare): Ditto.
1374
 
1375
2010-09-09  Steven G. Kargl  
1376
 
1377
        * fortran/expr.c (check_inquiry): OPTIONAL attribute is not allowed
1378
        for dummy argument that appears in a specification statement.
1379
 
1380
2010-09-09  Mikael Morin  
1381
 
1382
        * trans-array.c (gfc_get_array_ref_dim): New function.
1383
        (gfc_trans_create_temp_array): Reconstruct array
1384
        bounds from loop bounds. Use array bounds instead of loop bounds.
1385
 
1386
2010-09-09  Mikael Morin  
1387
 
1388
        * trans-array.c (gfc_set_loop_bounds_from_array_spec):
1389
        Get the array dimension from the dim array.
1390
 
1391
2010-09-09  Mikael Morin  
1392
 
1393
        * trans-array.c (gfc_trans_preloop_setup): Unconditionally use the
1394
        dim array to get the stride in the innermost loop.
1395
 
1396
2010-09-09  Mikael Morin  
1397
 
1398
        * trans-array.c (gfc_trans_create_temp_array): Don't set dim array.
1399
        (gfc_conv_loop_setup, gfc_walk_function_expr): Set dim array.
1400
        * trans-intrinsic.c (gfc_walk_intrinsic_libfunc): Ditto.
1401
 
1402
2010-09-09  Mikael Morin  
1403
 
1404
        * trans-array.c (gfc_trans_create_temp_array): Assert loop dimension
1405
        and info dimension are the same. Loop over loop dimension.
1406
        * trans-stmt.c (gfc_conv_elemental_dependencies): Set loop dimension
1407
 
1408
2010-09-09  Mikael Morin  
1409
 
1410
        * trans-array.c (gfc_conv_array_transpose): Change generated descriptor
1411
        name
1412
 
1413
2010-09-09  Tobias Burnus  
1414
 
1415
        PR fortran/43665
1416
        * intrincic.texi (FGET, FGETC, FPUT, FPUTC, FSTAT, GETCWD, KILL,
1417
        STAT): Show also syntax for the function version.
1418
        * intrinsic.c (add_sym_1s_intent, add_sym_2s_intent,
1419
         add_sym_3s_intent): Remove function.
1420
        (add_sym_1s, add_sym_2s, add_sym_3s): Take always the intent
1421
        as argument.
1422
        (add_sym_2_intent): New function.
1423
        (add_functions): Set intent for functions which modify
1424
        the argument: fstat, fgetc, fget, hostnm, lstat, stat. Change
1425
        argument name of hostnm from "a" to "c"
1426
        (add_subroutines): Change add_sym_*s_intent to
1427
        add_sym_*s and add intent to the add_sym_*s calls.
1428
 
1429
2010-09-08  Francois-Xavier Coudert  
1430
 
1431
        PR fortran/38282
1432
        * intrinsic.c (add_functions): Add B{G,L}{E,T}, DSHIFT{L,R},
1433
        MASK{L,R}, MERGE_BITS and SHIFT{A,L,R}.
1434
        * gfortran.h: Define ISYM values for above intrinsics.
1435
        * intrinsic.h (gfc_check_bge_bgt_ble_blt, gfc_check_dshift,
1436
        gfc_check_mask, gfc_check_merge_bits, gfc_check_shift,
1437
        gfc_simplify_bge, gfc_simplify_bgt, gfc_simplify_ble,
1438
        gfc_simplify_blt, gfc_simplify_dshiftl, gfc_simplify_dshiftr,
1439
        gfc_simplify_lshift, gfc_simplify_maskl, gfc_simplify_maskr,
1440
        gfc_simplify_merge_bits, gfc_simplify_rshift,
1441
        gfc_simplify_shifta, gfc_simplify_shiftl, gfc_simplify_shiftr,
1442
        gfc_resolve_dshift, gfc_resolve_mask, gfc_resolve_merge_bits,
1443
        gfc_resolve_shift): New prototypes.
1444
        * iresolve.c (gfc_resolve_dshift, gfc_resolve_mask,
1445
        gfc_resolve_merge_bits, gfc_resolve_shift): New functions.
1446
        * check.c (gfc_check_bge_bgt_ble_blt, gfc_check_dshift,
1447
        gfc_check_mask, gfc_check_merge_bits, gfc_check_shift): New
1448
        functions.
1449
        * trans-intrinsic.c (gfc_conv_intrinsic_dshift,
1450
        gfc_conv_intrinsic_bitcomp, gfc_conv_intrinsic_shift,
1451
        gfc_conv_intrinsic_merge_bits, gfc_conv_intrinsic_mask): New
1452
        functions.
1453
        (gfc_conv_intrinsic_function): Call above static functions.
1454
        * intrinsic.texi: Document new intrinsics.
1455
        * simplify.c (gfc_simplify_bge, gfc_simplify_bgt, gfc_simplify_ble,
1456
        gfc_simplify_blt, gfc_simplify_dshiftl, gfc_simplify_dshiftr,
1457
        gfc_simplify_lshift, gfc_simplify_maskl, gfc_simplify_maskr,
1458
        gfc_simplify_merge_bits, gfc_simplify_rshift,
1459
        gfc_simplify_shifta, gfc_simplify_shiftl, gfc_simplify_shiftr):
1460
        New functions.
1461
 
1462
2010-09-08  Jakub Jelinek  
1463
 
1464
        * frontend-passes.c (optimize_code_node): Walk block chain by default.
1465
 
1466
        PR fortran/45597
1467
        * trans-openmp.c (gfc_trans_omp_do): Store exit/cycle labels on code
1468
        instead of code->block.
1469
 
1470
        PR fortran/45595
1471
        * openmp.c (resolve_omp_do): Report not enough do loops for
1472
        collapse even if block->next is NULL.
1473
 
1474
2010-09-07  Thomas Koenig  
1475
 
1476
        PR fortran/45576
1477
        * dependency.c (gfc_deb_compare_expr):  Take missing optional
1478
        arguments into account.
1479
 
1480
2010-09-08  Francois-Xavier Coudert  
1481
 
1482
        * trans.h (gfor_fndecl_clz128, gfor_fndecl_ctz128): Remove.
1483
        * trans-decl.c (gfor_fndecl_clz128, gfor_fndecl_ctz128): Remove.
1484
        (gfc_build_intrinsic_function_decls): Don't build the
1485
        gfor_fndecl_clz128 and gfor_fndecl_ctz128.
1486
        * trans-intrinsic.c (gfc_conv_intrinsic_leadz,
1487
        gfc_conv_intrinsic_trailz): Generate inline arithmetic instead
1488
        of calling clz128/ctz128 library functions.
1489
 
1490
2010-09-07  Jan Hubicka  
1491
 
1492
        * trans-expr.c (gfc_conv_initializer): Set STATIC flags for
1493
        initializers.
1494
 
1495
2010-09-07  Tobias Burnus 
1496
 
1497
        PR fortran/45583
1498
        * intrinsic.texi (COS): Remove superfluous "n".
1499
 
1500
2010-09-07  Tobias Burnus 
1501
 
1502
        PR fortran/45186
1503
        * trans-array.c (gfc_conv_descriptor_data_get,
1504
        gfc_conv_descriptor_data_set, gfc_conv_descriptor_data_addr,
1505
        gfc_conv_descriptor_offset, gfc_conv_descriptor_dtype,
1506
        gfc_conv_descriptor_dimension, gfc_conv_descriptor_stride,
1507
        gfc_conv_descriptor_lbound, gfc_conv_descriptor_ubound,
1508
        gfc_conv_shift_descriptor_lbound,
1509
        gfc_set_loop_bounds_from_array_spec,
1510
        gfc_trans_allocate_array_storage, gfc_trans_create_temp_array,
1511
        gfc_conv_array_transpose, gfc_get_iteration_count,
1512
        gfc_grow_array, gfc_trans_array_ctor_element,
1513
        gfc_trans_array_constructor_subarray,
1514
        gfc_trans_array_constructor_value,
1515
        constant_array_constructor_loop_size, gfc_trans_array_constructor,
1516
        gfc_set_vector_loop_bounds, gfc_trans_array_bound_check,
1517
        gfc_conv_array_index_offset, gfc_conv_scalarized_array_ref,
1518
        gfc_conv_array_ref, gfc_trans_preloop_setup,
1519
        gfc_trans_scalarized_loop_end, gfc_conv_ss_startstride,
1520
        gfc_conv_loop_setup, gfc_conv_array_extent_dim,
1521
        gfc_conv_descriptor_size, gfc_array_init_size,
1522
        gfc_array_allocate, gfc_array_deallocate,
1523
        gfc_trans_array_bounds, gfc_trans_auto_array_allocation,
1524
        gfc_trans_dummy_array_bias, gfc_get_dataptr_offset,
1525
        get_array_charlen, gfc_conv_expr_descriptor,
1526
        array_parameter_size, gfc_conv_array_parameter,
1527
        gfc_trans_dealloc_allocated, get_full_array_size,
1528
        duplicate_allocatable,
1529
        structure_alloc_comps): Change fold_build[0-9] to
1530
        fold_build[0-9]_loc.
1531
        (duplicate_allocatable, structure_alloc_comps,
1532
        gfc_duplicate_allocatable): Add space after function name.
1533
 
1534
2010-09-07  Mikael Morin  
1535
 
1536
        * trans-stmt.c (gfc_trans_character_select): Be conversion-safe while
1537
        checking string length value.
1538
        * trans-intrinsic.c (gfc_conv_intrinsic_char): Build integer using
1539
        gfc_charlen_type_node type.
1540
 
1541
        PR fortran/45564
1542
        * trans-intrinsic.c (gfc_conv_intrinsic_transfer): Convert string
1543
        length to gfc_charlen_type_node.
1544
 
1545
2010-09-06  Thomas Koenig  
1546
 
1547
        PR fortran/36931
1548
        * frontend-passes.c (optimize_binop_array_assignment):  New
1549
        function.
1550
        (optimize_assignment):  Call it.
1551
 
1552
2010-09-06  Thomas Koenig  
1553
 
1554
        PR fortran/34145
1555
        * trans-expr.c (gfc_conv_substring):  If start and end
1556
        of the string reference are equal, set the length to one.
1557
 
1558
2010-09-06  Tobias Burnus  
1559
 
1560
        PR fortran/45560
1561
        * dump-parse-tree.c (gfc_debug_expr): Use stderr instead of stdout.
1562
 
1563
2010-09-06  Tobias Burnus  
1564
 
1565
        PR fortran/45560
1566
        * dump-parse-tree.c (gfc_debug_expr): New function.
1567
 
1568
2010-09-06  Tobias Burnus  
1569
 
1570
        PR fortran/38282
1571
        * intrinsic.c (add_functions): Support IALL, IANY, IPARITY.
1572
        (check_specific): Special case for those intrinsics.
1573
        * gfortran.h (gfc_isym_id): Add new intrinsics
1574
        * intrinsic.h (gfc_check_transf_bit_intrins,
1575
        gfc_simplify_iall, gfc_simplify_iany, gfc_simplify_iparity,
1576
        gfc_resolve_iall, gfc_resolve_iany, gfc_resolve_iparity):
1577
        New prototypes.
1578
        * iresolve.c (gfc_resolve_iall, gfc_resolve_iany,
1579
        gfc_resolve_iparity, resolve_transformational): New functions.
1580
        (gfc_resolve_product, gfc_resolve_sum,
1581
        gfc_resolve_parity): Use resolve_transformational.
1582
        * check.c (gfc_check_transf_bit_intrins): New function.
1583
        * simplify.c (gfc_simplify_iall, gfc_simplify_iany,
1584
        gfc_simplify_iparity, do_bit_any, do_bit_ior,
1585
        do_bit_xor, simplify_transformation): New functions.
1586
        (gfc_simplify_all, gfc_simplify_any, gfc_simplify_parity,
1587
        gfc_simplify_sum, gfc_simplify_product): Use simplify_transformation.
1588
        * trans-intrinsic.c (gfc_conv_intrinsic_arith,
1589
        gfc_conv_intrinsic_function, gfc_is_intrinsic_libcall):
1590
        Handle IALL, IANY and IPARITY intrinsics.
1591
        * intrinsic.texi (IMAGE_INDEX): Move up to fix alphabetic
1592
        order.
1593
        (IALL, IANY, IPARITY): Document new intrinsics.
1594
 
1595
2010-09-05  Tobias Burnus 
1596
 
1597
        PR fortran/45186
1598
        * f95-lang.c (gfc_truthvalue_conversion): Use
1599
        fold_build[0-9]_loc instead of fold_build[0-9].
1600
        * convert.c (convert): Ditto.
1601
        * trans-intrinsic.c (gfc_conv_intrinsic_conversion,
1602
        build_fixbound_expr, build_fix_expr, gfc_conv_intrinsic_aint,
1603
        gfc_conv_intrinsic_int, gfc_conv_intrinsic_imagpart,
1604
        gfc_conv_intrinsic_conjg, gfc_trans_same_strlen_check,
1605
        gfc_conv_intrinsic_bound, gfc_conv_intrinsic_abs,
1606
        gfc_conv_intrinsic_cmplx, gfc_conv_intrinsic_mod,
1607
        gfc_conv_intrinsic_dim, gfc_conv_intrinsic_sign,
1608
        gfc_conv_intrinsic_dprod, gfc_conv_intrinsic_char,
1609
        gfc_conv_intrinsic_ctime, gfc_conv_intrinsic_fdate,
1610
        gfc_conv_intrinsic_ttynam, gfc_conv_intrinsic_minmax,
1611
        gfc_conv_intrinsic_minmax_char, gfc_conv_intrinsic_anyall,
1612
        gfc_conv_intrinsic_count, gfc_conv_intrinsic_arith,
1613
        gfc_conv_intrinsic_dot_product, gfc_conv_intrinsic_minmaxloc,
1614
        gfc_conv_intrinsic_minmaxval, gfc_conv_intrinsic_btest,
1615
        gfc_conv_intrinsic_bitop, gfc_conv_intrinsic_not,
1616
        gfc_conv_intrinsic_singlebitop, gfc_conv_intrinsic_ibits,
1617
        gfc_conv_intrinsic_rlshift, gfc_conv_intrinsic_ishft,
1618
        gfc_conv_intrinsic_ishftc, gfc_conv_intrinsic_leadz,
1619
        gfc_conv_intrinsic_trailz, gfc_conv_intrinsic_popcnt_poppar,
1620
        gfc_conv_intrinsic_ichar, gfc_conv_has_intvalue,
1621
        gfc_conv_intrinsic_merge, gfc_conv_intrinsic_spacing,
1622
        gfc_conv_intrinsic_rrspacing, gfc_conv_intrinsic_size,
1623
        size_of_string_in_bytes, gfc_conv_intrinsic_sizeof,
1624
        gfc_conv_intrinsic_storage_size, gfc_conv_intrinsic_strcmp,
1625
        gfc_conv_intrinsic_transfer, gfc_conv_allocated,
1626
        gfc_conv_associated, gfc_conv_same_type_as,
1627
        gfc_conv_intrinsic_trim, gfc_conv_intrinsic_repeat): Ditto.
1628
 
1629
2010-09-04  Tobias Burnus  
1630
 
1631
        PR fortran/45530
1632
        * resolve.c (resolve_fl_namelist): Change constraint checking
1633
        order to prevent endless loop.
1634
 
1635
2010-09-04  Janus Weil  
1636
 
1637
        PR fortran/45507
1638
        * resolve.c (resolve_allocate_expr): Generate default initializers
1639
        already at this point, resolve them and put them into expr3, ...
1640
        * trans-stmt.c (gfc_trans_allocate): ... instead of waiting until
1641
        translation stage.
1642
 
1643
2010-09-03  Tobias Burnus  
1644
 
1645
        PR fortran/45186
1646
        * trans-intrinsic.c (gfc_conv_intrinsic_sign,
1647
        gfc_conv_intrinsic_leadz): Use build_call_expr_loc instead
1648
        of build_call_expr.
1649
        * trans-expr.c (gfc_conv_expr_present, gfc_conv_missing_dummy,
1650
        gfc_conv_string_length, gfc_conv_substring,
1651
        gfc_conv_component_ref, gfc_conv_unary_op, gfc_conv_powi,
1652
        gfc_conv_cst_int_power, gfc_conv_string_tmp, gfc_conv_concat_op,
1653
        gfc_conv_expr_op, gfc_build_compare_string,
1654
        gfc_set_interface_mapping_bounds, gfc_conv_subref_array_arg,
1655
        gfc_conv_derived_to_class, conv_isocbinding_procedure,
1656
        gfc_conv_procedure_call, fill_with_spaces,
1657
        gfc_trans_string_copy, gfc_trans_alloc_subarray_assign,
1658
        gfc_trans_structure_assign, gfc_trans_pointer_assignment,
1659
        gfc_trans_scalar_assign, gfc_trans_zero_assign,
1660
        gfc_trans_array_copy, gfc_trans_array_constructor_copy): Change
1661
        fold_build[0-9] to fold_build[0-9]_loc.
1662
        * trans-io.c (set_parameter_const, set_parameter_value,
1663
        set_parameter_ref, gfc_convert_array_to_string, set_string,
1664
        set_internal_unit, io_result, set_error_locus,
1665
        nml_get_addr_expr, build_dt): Ditto.
1666
        * trans-openmp.c (gfc_omp_clause_default_ctor,
1667
        gfc_omp_clause_copy_ctor, gfc_omp_clause_assign_op,
1668
        gfc_trans_omp_array_reduction, gfc_trans_omp_atomic,
1669
        gfc_trans_omp_do): Ditto.
1670
        * trans.c (gfc_add_modify, gfc_build_addr_expr,
1671
        gfc_build_array_ref, gfc_trans_runtime_error_vararg,
1672
        gfc_trans_runtime_check, gfc_call_malloc,
1673
        gfc_allocate_with_status, gfc_allocate_array_with_status,
1674
        gfc_call_free, gfc_deallocate_with_status,
1675
        gfc_call_realloc): Ditto.
1676
 
1677
2010-09-03  Thomas Koenig  
1678
 
1679
        PR fortran/45159
1680
        * dependency.c (gfc_deb_compare_expr):  Compare equal for equal
1681
        arglists for pure user functions, or for those intrinsic
1682
        functions which are also pure.
1683
        * intrinsics.c (add_conv):  Mark conversion functions as pure.
1684
        (add_char_conversions):  Likewise.
1685
 
1686
2010-09-03  Daniel Kraft  
1687
 
1688
        PR fortran/34162
1689
        * resolve.c (resolve_actual_arglist): Allow internal procedure
1690
        as actual argument with Fortran 2008.
1691
 
1692
2010-09-03  Daniel Kraft  
1693
 
1694
        PR fortran/44602
1695
        * gfortran.h (struct gfc_code): Renamed `whichloop' to
1696
        `which_construct' as this is no longer restricted to loops.
1697
        * parse.h (struct gfc_state_data): New field `construct'.
1698
        * match.c (match_exit_cycle): Handle EXIT from non-loops.
1699
        * parse.c (push_state): Set `construct' field.
1700
        * resolve.c (resolve_select_type): Extend comment.
1701
        * trans-stmt.c (gfc_trans_if): Add exit label.
1702
        (gfc_trans_block_construct), (gfc_trans_select): Ditto.
1703
        (gfc_trans_simple_do): Store exit/cycle labels on the gfc_code itself.
1704
        (gfc_trans_do), (gfc_trans_do_while): Ditto.
1705
        (gfc_trans_exit): Use new name `which_construct' instead of `whichloop'.
1706
        (gfc_trans_cycle): Ditto.
1707
        (gfc_trans_if_1): Use fold_build3_loc instead of fold_build3.
1708
 
1709
2010-09-03  Francois-Xavier Coudert  
1710
 
1711
        * trans-intrinsic.c (gfc_conv_intrinsic_aint): Fix whitespace.
1712
        (gfc_conv_intrinsic_ishft): Only evaluate arguments once.
1713
        (gfc_conv_intrinsic_ishftc): Only evaluate arguments once.
1714
        * intrinsic.texi (RSHIFT): Fix documentation.
1715
 
1716
2010-09-02  Tobias Burnus  
1717
 
1718
        PR fortran/45186
1719
        * trans-common.c (create_common): Change build[0-9] to
1720
        build[0-9]_loc.
1721
        * trans-const.c (gfc_conv_constant_to_tree,
1722
        gfc_conv_constant_to_tree): Ditto.
1723
        * trans-decl.c (gfc_build_qualified_array, build_entry_thunks,
1724
        gfc_get_fake_result_decl, gfc_trans_auto_character_variable,
1725
        add_argument_checking, create_main_function,
1726
        gfc_generate_return): Ditto.
1727
        * trans-types.c (gfc_get_dtype, gfc_get_array_type_bounds): Ditto.
1728
        * trans-stmt.c (allocate_temp_for_forall_nest_1,
1729
        compute_inner_temp_size, compute_overall_iter_number,
1730
        generate_loop_for_rhs_to_temp, generate_loop_for_temp_to_lhs,
1731
        gfc_conv_elemental_dependencies, gfc_do_allocate,
1732
        gfc_evaluate_where_mask, gfc_trans_allocate,
1733
        gfc_trans_arithmetic_if, gfc_trans_call,
1734
        gfc_trans_character_select, gfc_trans_deallocate,
1735
        gfc_trans_do, gfc_trans_do_while, gfc_trans_forall_1,
1736
        gfc_trans_forall_loop, gfc_trans_goto, gfc_trans_if_1,
1737
        gfc_trans_integer_select, gfc_trans_logical_select,
1738
        gfc_trans_pointer_assign_need_temp, gfc_trans_return,
1739
        gfc_trans_simple_do, gfc_trans_sync, gfc_trans_where_2,
1740
        gfc_trans_where_assign) Ditto.
1741
 
1742
2010-09-02  Janus Weil  
1743
 
1744
        PR fortran/44541
1745
        * resolve.c (resolve_symbol): Correct check for attributes of CLASS
1746
        variable.
1747
 
1748
2010-09-02  Tobias Burnus  
1749
 
1750
        PR fortran/45489
1751
        * resolve.c (apply_default_init): Mark symbol as referenced,
1752
        if it is initialized.
1753
        (resolve_symbol): Change intialized check for BT_DERIVED such
1754
        that also function results get initialized; remove now obsolete
1755
        gfc_set_sym_referenced for BT_CLASS.
1756
 
1757
2010-09-01  Janus Weil  
1758
 
1759
        PR fortran/44541
1760
        * class.c (gfc_find_derived_vtab): Add component '$def_init'.
1761
        * resolve.c (resolve_allocate_expr): Defer handling of default
1762
        initialization to 'gfc_trans_allocate'.
1763
        (apply_default_init,resolve_symbol): Handle polymorphic dummies.
1764
        (resolve_fl_derived): Suppress error messages for vtypes.
1765
        * trans-stmt.c (gfc_trans_allocate): Handle initialization via
1766
        polymorphic MOLD expression.
1767
        * trans-expr.c (gfc_trans_class_init_assign): Now only used for
1768
        dummy initialization.
1769
 
1770
2010-09-01  Tobias Burnus  
1771
 
1772
        * gfortran.texi (preprocessing): Update URL to COCO.
1773
 
1774
2010-09-01  Francois-Xavier Coudert  
1775
 
1776
        * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): Resize
1777
        array quad_decls. Remove unnecessary assignment.
1778
 
1779
2010-09-01  Francois-Xavier Coudert  
1780
 
1781
        * trans-expr.c (gfc_conv_power_op): Handle floating-point types
1782
        other than long double.
1783
        * mathbuiltins.def: Add builtins from the POW and CPOW family.
1784
        * trans.h (gfc_builtin_decl_for_float_kind): New prototype.
1785
        * trans-intrinsic.c (gfc_builtin_decl_for_float_kind): Add gfc_
1786
        prefix to function name.
1787
        (gfc_build_intrinsic_lib_fndecls): Add cpow prototype.
1788
        (gfc_conv_intrinsic_aint): Use gfc_builtin_decl_for_float_kind
1789
        function name.
1790
        (gfc_conv_intrinsic_exponent): Likewise.
1791
        (gfc_conv_intrinsic_abs): Likewise.
1792
        (gfc_conv_intrinsic_mod): Likewise.
1793
        (gfc_conv_intrinsic_sign): Likewise.
1794
        (gfc_conv_intrinsic_arith): Likewise.
1795
        (gfc_conv_intrinsic_fraction): Likewise.
1796
        (gfc_conv_intrinsic_nearest): Likewise.
1797
        (gfc_conv_intrinsic_spacing): Likewise.
1798
        (gfc_conv_intrinsic_rrspacing): Likewise.
1799
        (gfc_conv_intrinsic_scale): Likewise.
1800
        (gfc_conv_intrinsic_set_exponent): Likewise.
1801
 
1802
2010-09-01  Francois-Xavier Coudert  
1803
 
1804
        * intrinsic.c: Add EXECUTE_COMMAND_LINE intrinsic.
1805
        * intrinsic.h (gfc_resolve_execute_command_line): New function.
1806
        * iresolve.c (gfc_resolve_execute_command_line): New function.
1807
        * gfortran.h (GFC_ISYM_EXECUTE_COMMAND_LINE): New value.
1808
        * intrinsic.texi: Document EXECUTE_COMMAND_LINE.
1809
 
1810
2010-08-31  Francois-Xavier Coudert  
1811
 
1812
        PR fortran/38282
1813
        * f95-lang.c (gfc_init_builtin_functions): Define popcount{,l,ll}
1814
        and parity{,l,ll} builtins.
1815
        * trans-intrinsic.c (gfc_conv_intrinsic_popcnt_poppar): New function.
1816
        (gfc_conv_intrinsic_function): Call above new functions.
1817
        * simplify.c (gfc_simplify_popcnt, gfc_simplify_poppar): New
1818
        functions.
1819
        * intrinsic.texi: Document POPCNT and POPPAR.
1820
 
1821
2010-08-30  Janus Weil  
1822
 
1823
        PR fortran/45456
1824
        * resolve.c (resolve_structure_cons): Handle pointer-valued PPCs.
1825
 
1826
2010-08-30  Francois-Xavier Coudert  
1827
 
1828
        * Make-lang.in: Add frontend-passes.o dependencies.
1829
 
1830
2010-08-29  Janus Weil  
1831
 
1832
        PR fortran/42769
1833
        * resolve.c (resolve_structure_cons): For derived types, make sure the
1834
        type has been resolved.
1835
        (resolve_typebound_procedures): Make sure the vtab has been generated.
1836
 
1837
2010-08-29  Janus Weil  
1838
 
1839
        PR fortran/45439
1840
        * match.c (gfc_match_select_type): Give the associate-name the
1841
        FL_VARIABLE attribute.
1842
 
1843
2010-08-28  Steven G. Kargl  
1844
 
1845
        * simplify.c (gfc_simplify_bessel_n2): Fix indention
1846
        and argument type.
1847
 
1848
2010-08-28  Francois-Xavier Coudert  
1849
 
1850
        PR fortran/45436
1851
        * trans-types.c (gfc_init_kinds): Disable TFmode.
1852
 
1853
2010-08-27  Janus Weil  
1854
 
1855
        PR fortran/45432
1856
        * match.c (gfc_match_allocate): Avoid double free on error.
1857
 
1858
2010-08-27  Francois-Xavier Coudert  
1859
 
1860
        PR fortran/32049
1861
        * gfortran.h (gfc_real_info): Add c_float128 field.
1862
        * mathbuiltins.def: Indicate which builtins are const.
1863
        * trans-types.h (float128_type_node, complex_float128_type_node,
1864
        gfc_real16_is_float128): New variables.
1865
        * trans-types.c (float128_type_node, complex_float128_type_node,
1866
        gfc_real16_is_float128): New variables.
1867
        (gfc_init_kinds): Allow TFmode.
1868
        (gfc_build_real_type): Mark __float128 types as such.
1869
        (gfc_init_types): Initialize float128_type_node and
1870
        complex_float128_type_node
1871
        * f95-lang.c (gfc_init_builtin_functions): Adjust for new
1872
        argument of OTHER_BUILTIN macro.
1873
        * trans-intrinsic.c (gfc_intrinsic_map_t): Likewise.
1874
        (builtin_decl_for_precision): Special case for __float128.
1875
        (builtin_decl_for_float_kind): Likewise.
1876
        (define_quad_builtin): New function.
1877
        (gfc_build_intrinsic_lib_fndecls): Create all __float128
1878
        library decls if necessary. Store them in the real16_decl and
1879
        complex16_decl builtin map fields.
1880
        (gfc_get_intrinsic_lib_fndecl): Handle q-suffixed __float128
1881
        library function names.
1882
 
1883
2010-08-27  Tobias Burnus  
1884
 
1885
        PR fortran/33197
1886
        * gcc/fortran/intrinsic.c (add_functions): Add norm2 and parity.
1887
        * gcc/fortran/intrinsic.h (gfc_check_norm2, gfc_check_parity):
1888
        gfc_simplify_norm2, gfc_simplify_parity, gfc_resolve_norm2,
1889
        gfc_resolve_parity): New prototypes.
1890
        * gcc/fortran/gfortran.h (gfc_isym_id): New enum items
1891
        GFC_ISYM_NORM2 and GFC_ISYM_PARITY.
1892
        * gcc/fortran/iresolve.c (gfc_resolve_norm2,
1893
        gfc_resolve_parity): New functions.
1894
        * gcc/fortran/check.c (gfc_check_norm2, gfc_check_parity):
1895
        New functions.
1896
        * gcc/fortran/trans-intrinsic.c (gfc_conv_intrinsic_arith,
1897
        gfc_conv_intrinsic_function): Handle NORM2 and PARITY.
1898
        * gcc/fortran/intrinsic.texi (NORM2, PARITY): Add.
1899
        * gcc/fortran/simplify.c (simplify_transformation_to_array):
1900
        Add post-processing opterator.
1901
        (gfc_simplify_all, gfc_simplify_any, gfc_simplify_count,
1902
        gfc_simplify_product, gfc_simplify_sum): Update call.
1903
        (add_squared, do_sqrt, gfc_simplify_norm2, do_xor,
1904
        gfc_simplify_parity): New functions.
1905
 
1906
2010-08-27  Janus Weil  
1907
 
1908
        PR fortran/45420
1909
        * match.c (select_type_set_tmp): Add the possibility to reset the
1910
        temporary to NULL.
1911
        (gfc_match_class_is): Reset the temporary in CLASS DEFAULT clauses.
1912
 
1913
2010-08-27  Thomas Koenig  
1914
 
1915
        PR fortran/45159
1916
        * dependency.c (check_section_vs_section):  Single test for
1917
        identical strides which takes into account that only one
1918
        of the strides may be NULL.
1919
 
1920
2010-08-27  Jerry DeLisle  
1921
 
1922
        PR fortran/43217
1923
        * primary.c (match_hollerith_constant): Calculate padding needed to
1924
        fill default integer and allocate string for that size.  Set pad bytes
1925
        to ' '.
1926
        * gfortran.h: Add hollerith pad value to type spec union.
1927
        * data.c (create_character_initializer): Fix spelling of function name.
1928
        Use hollerith pad value to calculate length.
1929
        * arith.c (hollerith2representation); Use hollerith pad value to
1930
        calculate length.
1931
 
1932
2010-08-26  Daniel Kraft  
1933
 
1934
        PR fortran/38936
1935
        PR fortran/44047
1936
        PR fortran/45384
1937
        * gfortran.h (struct gfc_association_list): New flag `dangling'.
1938
        (gfc_build_block_ns): Declared here...
1939
        * parse.h (gfc_build_block_ns): ...instead of here.
1940
        * trans.h (gfc_process_block_locals): Expect additionally the
1941
        gfc_association_list of BLOCK (if present).
1942
        * match.c (select_type_set_tmp): Create sym->assoc for temporary.
1943
        * resolve.c (resolve_variable): Only check for invalid *array*
1944
        references on associate-names.
1945
        (resolve_assoc_var): New method with code previously in resolve_symbol.
1946
        (resolve_select_type): Use association to give the selector and
1947
        temporaries their values instead of ordinary assignment.
1948
        (resolve_fl_var_and_proc): Allow CLASS associate-names.
1949
        (resolve_symbol): Use new `resolve_assoc_var' instead of inlining here.
1950
        * trans-stmt.c (gfc_trans_block_construct): Pass association-list
1951
        to `gfc_process_block_locals' to match new interface.
1952
        * trans-decl.c (gfc_get_symbol_decl): Don't defer associate-names
1953
        here automatically.
1954
        (gfc_process_block_locals): Defer them rather here when linked to
1955
        from the BLOCK's association list.
1956
 
1957
2010-08-25  Jakub Jelinek  
1958
 
1959
        * trans-decl.c (gfc_build_intrinsic_function_decls): Set
1960
        TREE_NOTHROW on fndecls that can't throw.  Set
1961
        TREE_READONLY on gfor_fndecl_math_ishftc{4,8,16}.
1962
        (gfc_build_builtin_function_decls): Set TREE_NOTHROW on
1963
        gfor_fndecl_associated.
1964
 
1965
2010-08-23  Mikael Morin  
1966
 
1967
        PR fortran/45380
1968
        * frontend-passes.c (optimize_equality): Don't optimize array equality
1969
 
1970
2010-08-23  Janus Weil  
1971
 
1972
        PR fortran/45366
1973
        * resolve.c (resolve_procedure_interface): New function split off from
1974
        'resolve_symbol'.
1975
        (resolve_formal_arglist): Call it here ...
1976
        (resolve_symbol): ... and here.
1977
 
1978
2010-08-22  Joseph Myers  
1979
 
1980
        * Make-lang.in (gfortranspec.o): Update dependencies.
1981
        * gfortranspec.c: Include coretypes.h before gcc.h.  Include
1982
        opts.h.
1983
        (MATH_LIBRARY, FORTRAN_LIBRARY): Remove initial "-l".
1984
        (ADD_ARG_LIBGFORTRAN, Option, lookup_option): Remove.
1985
        (g77_xargc): Make unsigned.
1986
        (g77_xargv): Change to g77_x_decoded_options.
1987
        (g77_newargc): Make unsigned.
1988
        (g77_newargv): Change to g77_new_decoded_options.
1989
        (strings_same, options_same): New.
1990
        (append_arg): Use cl_decoded_option structures.
1991
        (append_option): New.
1992
        (add_arg_libgfortran): New.
1993
        (lang_specific_driver): Use cl_decoded_option structures.
1994
 
1995
2010-08-21  Janus Weil  
1996
 
1997
        PR fortran/45271
1998
        PR fortran/45290
1999
        * class.c (add_proc_comp): Add static initializer for PPCs.
2000
        (add_procs_to_declared_vtab): Modified comment.
2001
        * module.c (mio_component): Add argument 'vtype'. Don't read/write the
2002
        initializer if the component is part of a vtype.
2003
        (mio_component_list): Add argument 'vtype', pass it on to
2004
        'mio_component'.
2005
        (mio_symbol): Modified call to 'mio_component_list'.
2006
        * trans.h (gfc_conv_initializer): Modified prototype.
2007
        (gfc_trans_assign_vtab_procs): Removed.
2008
        * trans-common.c (create_common): Modified call to
2009
        'gfc_conv_initializer'.
2010
        * trans-decl.c (gfc_get_symbol_decl,get_proc_pointer_decl,
2011
        gfc_emit_parameter_debug_info): Modified call to
2012
        'gfc_conv_initializer'.
2013
        (build_function_decl): Remove assertion.
2014
        * trans-expr.c (gfc_conv_derived_to_class,gfc_trans_class_assign):
2015
        Removed call to 'gfc_trans_assign_vtab_procs'.
2016
        (gfc_conv_initializer): Add argument 'procptr'.
2017
        (gfc_conv_structure): Modified call to 'gfc_conv_initializer'.
2018
        (gfc_trans_assign_vtab_procs): Removed.
2019
        * trans-stmt.c (gfc_trans_allocate): Removed call to
2020
        'gfc_trans_assign_vtab_procs'.
2021
 
2022
2010-08-21  Tobias Burnus  
2023
 
2024
        PR fortran/36158
2025
        PR fortran/33197
2026
        * intrinsic.c (add_sym): Init value attribute.
2027
        (set_attr_value): New function.
2028
        (add_functions) Use it and add JN/YN resolvers.
2029
        * symbol.c (gfc_copy_formal_args_intr): Copy value attr.
2030
        * intrinsic.h (gfc_resolve_bessel_n2): New prototype.
2031
        * gfortran.h (gfc_intrinsic_arg): Add value attribute.
2032
        * iresolve.c (gfc_resolve_bessel_n2): New function.
2033
        * trans-intrinsic.c (gfc_get_symbol_for_expr): Create
2034
        formal arg list.
2035
        (gfc_conv_intrinsic_function,gfc_is_intrinsic_libcall):
2036
        Add GFC_ISYM_JN2/GFC_ISYM_YN2 as case value.
2037
        * simplify.c (): For YN set to -INF if previous values
2038
        was -INF.
2039
        * trans-expr.c (gfc_conv_procedure_call): Don't crash
2040
        if sym->as is NULL.
2041
        * iresolve.c (gfc_resolve_extends_type_of): Set the
2042
        type of the dummy argument to the one of the actual.
2043
 
2044
2010-08-20  Joseph Myers  
2045
 
2046
        * lang.opt (MD, MMD): Use NoDriverArg instead of NoArgDriver.
2047
 
2048
2010-08-20  Joseph Myers  
2049
 
2050
        * gfortranspec.c (lang_specific_driver): Refer to -lgfortran in
2051
        comment, not -lg2c.
2052
 
2053
2010-08-20  Nathan Froyd  
2054
 
2055
        * trans-openmp.c: Use FOR_EACH_VEC_ELT.
2056
 
2057
2010-08-19  Daniel Kraft  
2058
 
2059
        PR fortran/29785
2060
        PR fortran/45016
2061
        * trans.h (struct gfc_se): New flag `byref_noassign'.
2062
        * trans-array.h (gfc_conv_shift_descriptor_lbound): New method.
2063
        (gfc_conv_array_extent_dim), (gfc_conv_descriptor_size): New methods.
2064
        * expr.c (gfc_check_pointer_assign): Allow bounds and rank remapping
2065
        and check for compile-time errors with those.
2066
        * trans-decl.c (trans_associate_var): Use new routine
2067
        `gfc_conv_shift_descriptor_lbound' instead of doing it manually.
2068
        * trans-array.c (gfc_conv_shift_descriptor_lbound): New method.
2069
        (gfc_conv_array_extent_dim), (gfc_conv_descriptor_size): New methods.
2070
        (gfc_array_init_size): Use new `gfc_conv_array_extent_dim'.
2071
        (gfc_conv_expr_descriptor): Handle new flag `byref_noassign'.
2072
        * trans-expr.c (gfc_trans_pointer_assignment): Handle bounds and
2073
        rank remapping for assignment.
2074
 
2075
2010-08-19  Tobias Burnus  
2076
 
2077
        * intrinsic.texi (Bessel_jn, Bessel_yn): Fix typo.
2078
        * * simplify.c (gfc_simplify_bessel_yn): Change recursive
2079
        into recurrence.
2080
 
2081
2010-08-19  Tobias Burnus  
2082
 
2083
        PR fortran/36158
2084
        PR fortran/33197
2085
        * check.c (gfc_check_bessel_n2): New function.
2086
        * gfortran.h (gfc_isym_id): Add GFC_ISYM_JN2 and GFC_ISYM_YN2.
2087
        * intrinsic.c (add_functions): Add transformational version
2088
        of the Bessel_jn/yn intrinsics.
2089
        * intrinsic.h (gfc_check_bessel_n2,gfc_simplify_bessel_jn2,
2090
        gfc_simplify_bessel_yn2): New prototypes.
2091
        * intrinsic.texi (Bessel_jn, Bessel_yn): Document
2092
        transformational variant.
2093
        * simplify.c (gfc_simplify_bessel_jn, gfc_simplify_bessel_yn):
2094
        Check for negative order.
2095
        (gfc_simplify_bessel_n2,gfc_simplify_bessel_jn2,
2096
        gfc_simplify_bessel_yn2): New functions.
2097
 
2098
2010-08-19  Jerry DeLisle  
2099
 
2100
        PR fortran/41859
2101
        * resolve.c (resolve_transfer): Traverse operands and set expression
2102
        to be checked to a non EXPR_OP type.
2103
 
2104
2010-08-19  Janus Weil  
2105
 
2106
        PR fortran/45290
2107
        * gfortran.h (gfc_add_save): Modified prototype.
2108
        * decl.c (add_init_expr_to_sym): Defer checking of proc pointer init.
2109
        (match_pointer_init): New function to match F08 pointer initialization.
2110
        (variable_decl,match_procedure_decl,match_ppc_decl): Use
2111
        'match_pointer_init'.
2112
        (match_attr_spec): Module variables are implicitly SAVE.
2113
        (gfc_match_save): Modified call to 'gfc_add_save'.
2114
        * expr.c (gfc_check_assign_symbol): Extra checks for pointer
2115
        initialization.
2116
        * primary.c (gfc_variable_attr): Handle SAVE attribute.
2117
        * resolve.c (resolve_structure_cons): Add new argument and do pointer
2118
        initialization checks.
2119
        (gfc_resolve_expr): Modified call to 'resolve_structure_cons'.
2120
        (resolve_values): Call 'resolve_structure_cons' directly with init arg.
2121
        (resolve_fl_variable): Handle SAVE_IMPLICIT.
2122
        * symbol.c (gfc_add_save,gfc_copy_attr,save_symbol): Handle
2123
        SAVE_IMPLICIT.
2124
        * trans-decl.c (gfc_create_module_variable): Module variables with
2125
        TARGET can already exist.
2126
        * trans-expr.c (gfc_conv_variable): Check for 'current_function_decl'.
2127
        (gfc_conv_initializer): Implement non-NULL pointer
2128
        initialization.
2129
 
2130
2010-08-18  Tobias Burnus  
2131
 
2132
        PR fortran/45295
2133
        * intrinsic.texi (selected_char_kind): Document ISO_10646
2134
        support.
2135
 
2136
2010-08-17  Jakub Jelinek  
2137
 
2138
        PR fortran/45304
2139
        * trans-decl.c (build_library_function_decl_1): Chain on
2140
        void_list_node instead of creating a new TREE_LIST.
2141
        * trans-intrinsic.c (gfc_get_intrinsic_lib_fndecl): Likewise.
2142
        * trans-types.c (gfc_get_function_type): Likewise.  Set
2143
        typelist to void_list_node for the main program.
2144
 
2145
2010-08-17  Daniel Kraft  
2146
 
2147
        PR fortran/38936
2148
        * gfortran.h (struct gfc_association_list): New member `where'.
2149
        (gfc_is_associate_pointer) New method.
2150
        * match.c (gfc_match_associate): Remember locus for each associate
2151
        name matched and do not try to set variable flag.
2152
        * parse.c (parse_associate): Use remembered locus for symbols.
2153
        * primary.c (match_variable): Instead of variable-flag check for
2154
        associate names set it for all such names used.
2155
        * symbol.c (gfc_is_associate_pointer): New method.
2156
        * resolve.c (resolve_block_construct): Don't generate assignments
2157
        to give associate-names their values.
2158
        (resolve_fl_var_and_proc): Allow associate-names to be deferred-shape.
2159
        (resolve_symbol): Set some more attributes for associate variables,
2160
        set variable flag here and check it and don't try to build an
2161
        explicitely shaped array-spec for array associate variables.
2162
        * trans-expr.c (gfc_conv_variable): Dereference in case of association
2163
        to scalar variable.
2164
        * trans-types.c (gfc_is_nodesc_array): Handle array association symbols.
2165
        (gfc_sym_type): Return pointer type for association to scalar vars.
2166
        * trans-decl.c (gfc_get_symbol_decl): Defer association symbols.
2167
        (trans_associate_var): New method.
2168
        (gfc_trans_deferred_vars): Handle association symbols.
2169
 
2170
2010-08-16  Joseph Myers  
2171
 
2172
        * lang.opt (MDX): Change back to MD.  Mark NoDriverArg instead of
2173
        RejectDriver.
2174
        (MMDX): Change back to MMD.  Mark NoDriverArg instead of
2175
        RejectDriver.
2176
        * cpp.c (gfc_cpp_handle_option): Use OPT_MD and OPT_MMD instead of
2177
        OPT_MDX and OPT_MMDX.
2178
 
2179
2010-08-16  Joseph Myers  
2180
 
2181
        * lang.opt (MDX, MMDX): Mark RejectDriver.
2182
 
2183
2010-08-15  Janus Weil  
2184
 
2185
        * trans-expr.c (gfc_trans_assign_vtab_procs): Clean up (we don't have
2186
        vtabs for generics any more).
2187
 
2188
2010-08-15  Daniel Kraft  
2189
 
2190
        PR fortran/38936
2191
        * gfortran.h (gfc_find_proc_namespace): New method.
2192
        * expr.c (gfc_build_intrinsic_call): No need to build symtree messing
2193
        around with namespace.
2194
        * symbol.c (gfc_find_proc_namespace): New method.
2195
        * trans-decl.c (gfc_build_qualified_array): Use it for correct
2196
        value of nest.
2197
        * primary.c (gfc_match_varspec): Handle associate-names as arrays.
2198
        * parse.c (parse_associate): Removed assignment-generation here...
2199
        * resolve.c (resolve_block_construct): ...and added it here.
2200
        (resolve_variable): Handle names that are arrays but were not parsed
2201
        as such because of association.
2202
        (resolve_code): Fix BLOCK resolution.
2203
        (resolve_symbol): Generate array-spec for associate-names.
2204
 
2205
2010-08-15  Tobias Burnus  
2206
 
2207
        PR fortran/45211
2208
        * decl.c (verify_c_interop_param): Remove superfluous space (" ").
2209
        (verify_c_interop): Handle unresolved DT with bind(C).
2210
 
2211
2010-08-15  Tobias Burnus  
2212
 
2213
        * trans-expr.c (gfc_conv_expr_present): Regard nullified
2214
        pointer arrays as absent.
2215
        (gfc_conv_procedure_call): Handle EXPR_NULL for non-pointer
2216
        dummys as absent argument.
2217
        * interface.c (compare_actual_formal,compare_parameter):
2218
        Ditto.
2219
 
2220
2010-08-15  Tobias Burnus  
2221
 
2222
        * interface.c (compare_pointer, ): Allow passing TARGETs to pointers
2223
        dummies with intent(in).
2224
 
2225
2010-08-15  Daniel Kraft  
2226
 
2227
        PR fortran/45197
2228
        * decl.c (gfc_match_prefix): Match IMPURE prefix and mark ELEMENTAL
2229
        routines not IMPURE also as PURE.
2230
        * intrinsic.c (enum klass): New class `CLASS_PURE' and renamed
2231
        `NO_CLASS' in `CLASS_IMPURE'.
2232
        (add_sym): Set symbol-attributes `pure' and `elemental' correctly.
2233
        (add_sym_0s): Renamed `NO_CLASS' in `CLASS_IMPURE'.
2234
        (add_functions): Ditto.
2235
        (add_subroutines): Ditto and mark `MOVE_ALLOC' as CLASS_PURE.
2236
        * resolve.c (gfc_pure): Do not treat ELEMENTAL as automatically PURE.
2237
        (resolve_formal_arglist): Check that arguments to ELEMENTAL procedures
2238
        are not ALLOCATABLE and have their INTENT specified.
2239
 
2240
2010-08-13  Daniel Kraft  
2241
 
2242
        * gfortran.h (array_type): New type `AS_IMPLIED_SHAPE'.
2243
        * array.c (gfc_match_array_spec): Match implied-shape specification and
2244
        handle AS_IMPLIED_SHAPE correctly otherwise.
2245
        * decl.c (add_init_expr_to_sym): Set upper bounds for implied-shape.
2246
        (variable_decl): Some checks for implied-shape declaration.
2247
        * resolve.c (resolve_symbol): Assert that array-spec is no longer
2248
        AS_IMPLIED_SHAPE in any case.
2249
 
2250
2010-08-12  Joseph Myers  
2251
 
2252
        * lang.opt (MD, MMD): Change to MDX and MMDX.
2253
        * cpp.c (gfc_cpp_handle_option): Use OPT_MMD and OPT_MMDX.
2254
 
2255
2010-08-11  Janus Weil  
2256
 
2257
        PR fortran/44595
2258
        * intrinsic.c (gfc_current_intrinsic_arg): Change type from 'char' to
2259
        'gfc_intrinsic_arg'.
2260
        (check_arglist,check_specific): Add reference to 'name' field.
2261
        (init_arglist): Remove reference to 'name' field.
2262
        * intrinsic.h (gfc_current_intrinsic_arg): Modify prototype.
2263
        * check.c (variable_check): Reverse order of checks. Respect intent of
2264
        formal arg.
2265
        (int_or_proc_check): New function.
2266
        (coarray_check): New function.
2267
        (allocatable_check): New function.
2268
        (gfc_check_allocated,gfc_check_move_alloc): Use 'allocatable_check'.
2269
        (gfc_check_complex): Use 'int_or_real_check'.
2270
        (gfc_check_lcobound,gfc_check_image_index,gfc_check_this_image,
2271
        gfc_check_ucobound): Use 'coarray_check'.
2272
        (gfc_check_pack): Use 'real_or_complex_check'.
2273
        (gfc_check_alarm_sub,gfc_check_signal,gfc_check_signal_sub): Use
2274
        'int_or_proc_check'.
2275
        (scalar_check,type_check,numeric_check,int_or_real_check,
2276
        real_or_complex_check,kind_check,double_check,logical_array_check,
2277
        array_check,same_type_check,rank_check,nonoptional_check,
2278
        kind_value_check,gfc_check_a_p,gfc_check_associated,gfc_check_cmplx,
2279
        gfc_check_cshift,gfc_check_dcmplx,gfc_check_dot_product,gfc_check_dprod,
2280
        gfc_check_eoshift,gfc_check_fn_rc2008,gfc_check_index,gfc_check_kind,
2281
        gfc_check_matmul,gfc_check_minloc_maxloc,check_reduction,gfc_check_null,
2282
        gfc_check_present,gfc_check_reshape,gfc_check_same_type_as,
2283
        gfc_check_spread,gfc_check_unpack,gfc_check_random_seed,
2284
        gfc_check_getarg,gfc_check_and,gfc_check_storage_size): Add reference
2285
        to 'name' field.
2286
 
2287
2010-08-10  Daniel Kraft  
2288
 
2289
        * gfortran.texi (Interoperability with C): Fix ordering in menu
2290
        and add new subsection about pointers.
2291
        (Interoperable Subroutines and Functions): Split off the pointer part.
2292
        (working with Pointers): New subsection with extended discussion
2293
        of pointers (especially procedure pointers).
2294
 
2295
2010-08-09  Thomas Koenig  
2296
 
2297
        PR fortran/44235
2298
        * array.c (gfc_ref_dimen_size):  Add end argument.
2299
        If end is non-NULL, calculate it.
2300
        (ref_size):  Adjust call to gfc_ref_dimen_size.
2301
        (gfc_array_dimen_size):  Likewise.
2302
        (gfc_array_res_shape):  Likewise.
2303
        * gfortran.h:  Adjust prototype for gfc_ref_dimen_size.
2304
        * resolve.c (resolve_array_ref):  For stride not equal to -1,
2305
        fill in the lowest possible end.
2306
 
2307
2010-08-09  Janus Weil  
2308
 
2309
        * intrinsic.texi: Correct documentation of ASINH, ACOSH and ATANH.
2310
 
2311
2010-08-07  Nathan Froyd  
2312
 
2313
        * interface.c (compare_actual_formal): Use XALLOCAVEC instead of
2314
        alloca.
2315
        (check_some_aliasing): Likewise.
2316
        * trans-intrinsic.c (gfc_conv_intrinsic_conversion): Likewise.
2317
        (gfc_conv_intrinsic_int): Likewise.
2318
        (gfc_conv_intrinsic_lib_function): Likewise.
2319
        (gfc_conv_intrinsic_cmplx): Likewise.
2320
        (gfc_conv_intrinsic_ctime): Likewise.
2321
        (gfc_conv_intrinsic_fdate): Likewise.
2322
        (gfc_conv_intrinsic_ttynam): Likewise.
2323
        (gfc_conv_intrinsic_minmax): Likewise.
2324
        (gfc_conv_intrinsic_minmax_char): Likewise.
2325
        (gfc_conv_intrinsic_ishftc): Likewise.
2326
        (gfc_conv_intrinsic_index_scan_verify): Likewise.
2327
        (gfc_conv_intrinsic_merge): Likewise.
2328
        (gfc_conv_intrinsic_trim): Likewise.
2329
        * trans.c (gfc_trans_runtime_error_vararg): Likewise.
2330
 
2331
2010-08-06  Thomas Koenig  
2332
 
2333
        PR fortran/45159
2334
        * dependency.c (check_section_vs_section):  Handle cases where
2335
        the start expression coincides with the lower or upper
2336
        bound of the array.
2337
 
2338
2010-08-04  Janus Weil  
2339
 
2340
        PR fortran/42207
2341
        PR fortran/44064
2342
        PR fortran/44065
2343
        * class.c (gfc_find_derived_vtab): Do not generate vtabs for class
2344
        container types. Do not artificially increase refs. Commit symbols one
2345
        by one.
2346
        * interface.c (compare_parameter): Make sure vtabs are present before
2347
        generating module variables.
2348
        * resolve.c (resolve_allocate_expr): Ditto.
2349
 
2350
2010-08-04  Tobias Burnus  
2351
 
2352
        PR fortran/45183
2353
        PR fortran/44857
2354
        * resolve.c (resolve_structure_cons): Fix
2355
        freeing of charlen.
2356
 
2357
2010-08-04  Mikael Morin  
2358
 
2359
        PR fortran/42051
2360
        PR fortran/44064
2361
        * symbol.c (changed_syms): Made static again.
2362
        (gfc_symbol_state): Don't conditionalize on GFC_DEBUG.
2363
        Changed conditional internal error into assert.
2364
        Rename function to ...
2365
        (gfc_enforce_clean_symbol_state): ... this.
2366
        * gfortran.h (gfc_symbol_state, gfc_enforce_clean_symbol_state):
2367
        Rename the former to the latter.
2368
        * parse.c (decode_statement, decode_omp_directive,
2369
        decode_gcc_attribute): Update callers accordingly. Don't conditionalize
2370
        on GFC_DEBUG.
2371
        (changed_syms): Remove declaration.
2372
        (next_statement): Use gfc_enforce_clean_symbol_state.
2373
 
2374
2010-08-04  Tobias Burnus  
2375
 
2376
        PR fortran/44857
2377
        * resolve.c (resolve_structure_cons): Fix handling of
2378
        initialization structure constructors with character
2379
        elements of the wrong length.
2380
        * array.c (gfc_check_iter_variable): Add NULL check.
2381
        (gfc_resolve_character_array_constructor): Also truncate
2382
        character length.
2383
 
2384
2010-08-04  Tobias Burnus  
2385
 
2386
        * trans-io.c (gfc_build_io_library_fndecls): Fix return
2387
        value of some libgfortran functions.
2388
 
2389
2010-08-03  Thomas Koenig  
2390
 
2391
        PR fortran/45159
2392
        * dependency.c (gfc_deb_compare_expr):  Remove any integer
2393
        conversion functions to larger types from both arguments.
2394
        Remove handling these functions futher down.
2395
 
2396
2010-08-03  Janus Weil  
2397
 
2398
        PR fortran/44584
2399
        PR fortran/45161
2400
        * class.c (add_procs_to_declared_vtab1): Don't add erroneous procedures.
2401
        * resolve.c (resolve_tb_generic_targets): Check for errors.
2402
 
2403
2010-08-02  Thomas Koenig  
2404
 
2405
        PR fortran/45159
2406
        * depencency.c (gfc_dep_resolver):  Fix logic for when a loop
2407
        can be reversed.
2408
 
2409
2010-08-02  Thomas Koenig  
2410
 
2411
        PR fortran/36854
2412
        * dependency.h:  Add prototype for gfc_are_identical_variables.
2413
        * frontend-passes.c:  Include depencency.h.
2414
        (optimimize_equality):  Use gfc_are_identical_variables.
2415
        * dependency.c (identical_array_ref): New function.
2416
        (gfc_are_identical_variables):  New function.
2417
        (gfc_deb_compare_expr):  Use gfc_are_identical_variables.
2418
        * dependency.c (gfc_check_section_vs_section).  Rename gfc_
2419
        prefix from statc function.
2420
        (check_section_vs_section): Change arguments to gfc_array_ref,
2421
        adjust function body accordingly.
2422
 
2423
2010-08-02  Mikael Morin  
2424
            Janus Weil  
2425
 
2426
        PR fortran/42051
2427
        PR fortran/44064
2428
        PR fortran/45151
2429
        * intrinsic.c (gfc_get_intrinsic_sub_symbol): Commit changed symbol.
2430
        * symbol.c (gen_cptr_param, gen_fptr_param, gen_shape_param,
2431
        gfc_copy_formal_args, gfc_copy_formal_args_intr,
2432
        gfc_copy_formal_args_ppc, generate_isocbinding_symbol): Ditto.
2433
        * parse.c (parse_derived_contains, parse_spec, parse_progunit):
2434
        Call reject_statement in case of error.
2435
        (match_deferred_characteritics): Call gfc_undo_symbols in case match
2436
        fails.
2437
 
2438
2010-08-01  Janus Weil  
2439
 
2440
        PR fortran/44912
2441
        * class.c (gfc_build_class_symbol): Make '$vptr' component private.
2442
        (gfc_find_derived_vtab): Make vtabs and vtypes public.
2443
        * module.c (read_module): When reading module files, always import
2444
        vtab and vtype symbols.
2445
 
2446
2010-07-31  Mikael Morin  
2447
 
2448
        PR fortran/42051
2449
        PR fortran/44064
2450
        * symbol.c (changed_syms): Made non-static.
2451
        * parse.c (changed_syms): Declare new external.
2452
        (next_statement): Assert changed_syms is NULL at the beginning.
2453
 
2454
2010-07-30  Janus Weil  
2455
            Steven G. Kargl  
2456
 
2457
        PR fortran/44929
2458
        * match.c (match_type_spec): Try to parse derived types before
2459
        intrinsic types.
2460
 
2461
2010-07-30  Mikael Morin  
2462
 
2463
        * gfortran.h (gfc_release_symbol): New prototype.
2464
        * symbol.c (gfc_release_symbol): New. Code taken from free_sym_tree.
2465
        (gfc_undo_symbols, free_sym_tree, gfc_free_finalizer):
2466
        Use gfc_release_symbol.
2467
        * parse.c (gfc_fixup_sibling_symbols): Ditto.
2468
        * resolve.c (resolve_symbol): Ditto.
2469
 
2470
2010-07-29  Tobias Burnus  
2471
 
2472
        PR fortran/45087
2473
        PR fortran/45125
2474
        * trans-decl.c (gfc_get_extern_function_decl): Correctly handle
2475
        external procedure declarations in modules.
2476
        (gfc_get_symbol_decl): Modify assert.
2477
 
2478
2010-07-29  Janus Weil  
2479
 
2480
        PR fortran/44962
2481
        * resolve.c (resolve_fl_derived): Call gfc_resolve_array_spec.
2482
 
2483
2010-07-29  Janus Weil  
2484
 
2485
        PR fortran/45004
2486
        * trans-stmt.h (gfc_trans_class_init_assign): New prototype.
2487
        (gfc_trans_class_assign): Modified prototype.
2488
        * trans.h (gfc_conv_intrinsic_move_alloc): New prototype.
2489
        * trans-expr.c (gfc_trans_class_init_assign): Split off from ...
2490
        (gfc_trans_class_assign): ... here. Modified actual arguments.
2491
        * trans-intrinsic.c (gfc_conv_intrinsic_move_alloc): New function to
2492
        handle the MOVE_ALLOC intrinsic with scalar and class arguments.
2493
        * trans.c (trans_code): Call 'gfc_conv_intrinsic_move_alloc'.
2494
 
2495
2010-07-29  Mikael Morin  
2496
 
2497
        PR fortran/42051
2498
        PR fortran/44064
2499
        * class.c (gfc_find_derived_vtab): Accept or discard newly created
2500
        symbols before returning.
2501
 
2502
2010-07-29  Joseph Myers  
2503
 
2504
        * lang.opt (cpp): Remove Joined and Separate markers.
2505
        (cpp=): New internal option.
2506
        * lang-specs.h (F951_CPP_OPTIONS): Generate -cpp= option.
2507
        * cpp.c (gfc_cpp_handle_option): Handle OPT_cpp_ instead of
2508
        OPT_cpp.
2509
 
2510
2010-07-29  Daniel Kraft  
2511
 
2512
        PR fortran/45117
2513
        * array.c (resolve_array_bound): Fix error message to properly handle
2514
        non-variable expressions.
2515
 
2516
2010-07-28  Mikael Morin  
2517
 
2518
        * decl.c (free_value): Also free repeat field.
2519
        * data.c (gfc_assign_data_value): Always free offset before returning.
2520
 
2521
2010-07-28  Daniel Kraft  
2522
 
2523
        * gfortran.h (gfc_build_intrinsic_call): New method.
2524
        * expr.c (gfc_build_intrinsic_call): New method.
2525
        * simplify.c (range_check): Ignore non-constant value.
2526
        (simplify_bound_dim): Handle non-variable expressions and
2527
        fix memory leak with non-free'ed expression.
2528
        (simplify_bound): Handle non-variable expressions.
2529
        (gfc_simplify_shape): Ditto.
2530
        (gfc_simplify_size): Ditto, but only in certain cases possible.
2531
 
2532
2010-07-28  Joseph Myers  
2533
 
2534
        * gfortranspec.c (SWITCH_TAKES_ARG, WORD_SWITCH_TAKES_ARG):
2535
        Remove.
2536
 
2537
2010-07-28  Tobias Burnus  
2538
 
2539
        PR fortran/45077
2540
        * trans-types.c (gfc_get_derived_type): Fix DT declaration
2541
        from modules for whole-file mode.
2542
 
2543
2010-07-27  Joseph Myers  
2544
 
2545
        * gfortran.h (gfc_handle_option): Update prototype and return
2546
        value type.
2547
        * options.c (gfc_handle_option): Update prototype and return value
2548
        type.
2549
 
2550
2010-07-27  Joseph Myers  
2551
 
2552
        * cpp.c (gfc_cpp_init_options): Update prototype.  Use number of
2553
        decoded options in allocating deferred_opt.
2554
        * cpp.h (gfc_cpp_init_options): Update prototype.
2555
        * f95-lang.c (LANG_HOOKS_OPTION_LANG_MASK): Define.
2556
        * gfortran.h (gfc_option_lang_mask): New.
2557
        (gfc_init_options): Update prototype.
2558
        * options.c (gfc_option_lang_mask): New.
2559
        (gfc_init_options): Update prototype.  Pass new arguments to
2560
        gfc_cpp_init_options.
2561
 
2562
2010-07-26  Tobias Burnus  
2563
 
2564
        PR fortran/40873
2565
        * trans-decl.c (gfc_get_extern_function_decl): Fix generation
2566
        for functions which are later in the same file.
2567
        (gfc_create_function_decl, build_function_decl,
2568
        build_entry_thunks): Add global argument.
2569
        * trans.c (gfc_generate_module_code): Update
2570
        gfc_create_function_decl call.
2571
        * trans.h (gfc_create_function_decl): Update prototype.
2572
        * resolve.c (resolve_global_procedure): Also resolve for
2573
        IFSRC_IFBODY.
2574
 
2575
2010-07-26  Richard Henderson  
2576
 
2577
        PR target/44132
2578
        * f95-lang.c (LANG_HOOKS_WRITE_GLOBALS): New.
2579
        (gfc_write_global_declarations): New.
2580
 
2581
2010-07-26  Tobias Burnus  
2582
 
2583
        PR fortran/45066
2584
        * trans-io.c (build_dt): Use NULL_TREE rather than NULL
2585
        for call to transfer_namelist_element.
2586
        * trans-decl.c (gfc_get_symbol_decl): Also set sym->backend_decl
2587
        for -fwhole-file.
2588
 
2589
2010-07-25  Thomas Koenig  
2590
 
2591
        PR fortran/40628
2592
        * Make-lang.in:  Add fortran/frontend-passes.o.
2593
        * gfortran.h:  Add prototype for gfc_run_passes.
2594
        * resolve.c (gfc_resolve):  Call gfc_run_passes.
2595
        * frontend-passes.c:  New file.
2596
 
2597
2010-07-25  Jerry DeLisle  
2598
 
2599
        PR fortran/42852
2600
        * scanner.c (gfc_next_char_literal): Enable truncation warning for
2601
        free-form '&'.
2602
 
2603
2010-07-25  Mikael Morin  
2604
 
2605
        PR fortran/44660
2606
        * gfortran.h (gfc_namespace): New field old_equiv.
2607
        (gfc_free_equiv_until): New prototype.
2608
        * match.c (gfc_free_equiv_until): New, renamed from gfc_free_equiv with
2609
        a parameterized stop condition.
2610
        (gfc_free_equiv): Use gfc_free_equiv_until.
2611
        * parse.c (next_statement): Save equivalence list.
2612
        (reject_statement): Restore equivalence list.
2613
 
2614
2010-07-25  Jerry DeLisle  
2615
 
2616
        PR fortran/42852
2617
        * scanner.c (gfc_next_char_literal): Move check for truncation earlier
2618
        in the function so that it does not get missed by early exits.
2619
        (load_line): Add checks for quoted strings and free form comments to
2620
        disable warnings on comments. Add check for ampersand as first
2621
        character after truncation and don't warn for this case, but warn if
2622
        there are subsequent non-whitespace characters.
2623
 
2624
2010-07-24  Tobias Burnus  
2625
 
2626
        PR fortran/40011
2627
        * parse.c (gfc_parse_file): Do not override
2628
        gfc_global_ns_list items.
2629
 
2630
2010-07-24  Tobias Burnus  
2631
 
2632
        * options.c (gfc_init_options): Enable -fwhole-file by default.
2633
        * interface.c (compare_parameter): Assume a Hollerith constant is
2634
        compatible with all other argument types.
2635
 
2636
2010-07-23  Tobias Burnus  
2637
 
2638
        PR fortran/44945
2639
        * trans-decl.c (gfc_get_symbol_decl): Use module decl with
2640
        -fwhole-file also for derived types.
2641
        * trans-types.c (copy_dt_decls_ifequal): Remove static and
2642
        rename to gfc_copy_dt_decls_ifequal.
2643
        (gfc_get_derived_type): Update call.
2644
        * trans-types.h (gfc_copy_dt_decls_ifequal): Add prototype.
2645
 
2646
2010-07-23  Tobias Burnus  
2647
 
2648
        PR fortran/45030
2649
        * resolve.c (resolve_global_procedure): Properly handle ENTRY.
2650
 
2651
2010-07-23  Jakub Jelinek  
2652
 
2653
        * trans-types.c (gfc_get_array_descriptor_base,
2654
        gfc_get_array_type_bounds): Set TYPE_NAMELESS.
2655
        * trans-decl.c (gfc_build_qualified_array): Set DECL_NAMELESS
2656
        instead of clearing DECL_NAME.
2657
        (gfc_build_dummy_array_decl): Set DECL_NAMELESS.
2658
 
2659
2009-07-23  Paul Thomas  
2660
 
2661
        PR fortran/24524
2662
        * trans-array.c (gfc_init_loopinfo): Initialize the reverse
2663
        field.
2664
        gfc_trans_scalarized_loop_end: If reverse set in dimension n,
2665
        reverse the scalarization loop.
2666
        gfc_conv_resolve_dependencies: Pass the reverse field of the
2667
        loopinfo to gfc_dep_resolver.
2668
        trans-expr.c (gfc_trans_assignment_1): Enable loop reversal for
2669
        assignment by resetting loop.reverse.
2670
        gfortran.h : Add the gfc_reverse enum.
2671
        trans.h : Add the reverse field to gfc_loopinfo.
2672
        dependency.c (gfc_check_dependency): Pass null to the new arg
2673
        of gfc_dep_resolver.
2674
        (gfc_check_section_vs_section): Check for reverse dependencies.
2675
        (gfc_dep_resolver): Add reverse argument and deal with the loop
2676
        reversal logic.
2677
        dependency.h : Modify prototype for gfc_dep_resolver to include
2678
        gfc_reverse *.
2679
 
2680
2010-07-23  Daniel Kraft  
2681
 
2682
        PR fortran/44709
2683
        * gfortran.h (gfc_find_symtree_in_proc): New method.
2684
        * symbol.c (gfc_find_symtree_in_proc): New method.
2685
        * match.c (match_exit_cycle): Look for loop name also in parent
2686
        namespaces within current procedure.
2687
 
2688
2010-07-22  Tobias Burnus  
2689
 
2690
        PR fortran/45019
2691
        * dependency.c (gfc_check_dependency): Add argument alising check.
2692
        * symbol.c (gfc_symbols_could_alias): Add argument alising check.
2693
 
2694
2010-07-22  Daniel Kraft  
2695
 
2696
        * trans-stmt.c (gfc_trans_return): Put back in the handling of se.post,
2697
        now in the correct place.
2698
 
2699
2010-07-21  Steven G. Kargl  
2700
 
2701
        PR fortran/44929
2702
        * Revert my commit r162325.
2703
 
2704
2010-07-21  Daniel Kraft  
2705
 
2706
        * trans.h (gfc_get_return_label): Removed.
2707
        (gfc_generate_return): New method.
2708
        (gfc_trans_deferred_vars): Update gfc_wrapped_block rather than
2709
        returning a tree directly.
2710
        * trans-stmt.c (gfc_trans_return): Use `gfc_generate_return'.
2711
        (gfc_trans_block_construct): Update for new interface to
2712
        `gfc_trans_deferred_vars'.
2713
        * trans-decl.c (current_function_return_label): Removed.
2714
        (current_procedure_symbol): New variable.
2715
        (gfc_get_return_label): Removed.
2716
        (gfc_trans_deferred_vars): Update gfc_wrapped_block rather than
2717
        returning a tree directly.
2718
        (get_proc_result), (gfc_generate_return): New methods.
2719
        (gfc_generate_function_code): Clean up and do init/cleanup here
2720
        also with gfc_wrapped_block.  Remove return-label but rather
2721
        return directly.
2722
 
2723
2010-07-19  Steven G. Kargl  
2724
 
2725
        PR fortran/44929
2726
        * fortran/match.c (match_type_spec): Check for derived type before
2727
        intrinsic types.
2728
 
2729
2010-07-19  Paul Thomas  
2730
 
2731
        PR fortran/42385
2732
        * interface.c (matching_typebound_op): Add argument for the
2733
        return of the generic name for the procedure.
2734
        (build_compcall_for_operator): Add an argument for the generic
2735
        name of an operator procedure and supply it to the expression.
2736
        (gfc_extend_expr, gfc_extend_assign): Use the generic name in
2737
        calls to the above procedures.
2738
        * resolve.c (resolve_typebound_function): Catch procedure
2739
        component calls for CLASS objects, check that the vtable is
2740
        complete and insert the $vptr and procedure components, to make
2741
        the call.
2742
        (resolve_typebound_function): The same.
2743
        * trans-decl.c (gfc_trans_deferred_vars): Do not deallocate
2744
        an allocatable scalar if it is a result.
2745
 
2746
2010-07-19  Paul Thomas  
2747
 
2748
        PR fortran/44353
2749
        * match.c (gfc_match_iterator): Reverted.
2750
 
2751
2010-07-18  Paul Thomas  
2752
 
2753
        PR fortran/44353
2754
        * match.c (gfc_match_iterator): Remove error that iterator
2755
        cannot be INTENT(IN).
2756
 
2757
2010-07-17  Mikael Morin  
2758
 
2759
        * trans-array.c (gfc_free_ss): Don't free beyond ss rank.
2760
        Access subscript through the "dim" field index.
2761
        (gfc_trans_create_temp_array): Access ss info through the "dim" field
2762
        index.
2763
        (gfc_conv_array_index_offset): Ditto.
2764
        (gfc_conv_loop_setup): Ditto.
2765
        (gfc_conv_expr_descriptor): Ditto.
2766
        (gfc_conv_ss_startstride): Ditto.  Update call to
2767
        gfc_conv_section_startstride.
2768
        (gfc_conv_section_startstride): Set values along the array dimension.
2769
        Get array dimension directly from the argument.
2770
 
2771
2010-07-15  Jakub Jelinek  
2772
 
2773
        * trans.h (gfc_string_to_single_character): New prototype.
2774
        * trans-expr.c (string_to_single_character): Renamed to ...
2775
        (gfc_string_to_single_character): ... this.  No longer static.
2776
        (gfc_conv_scalar_char_value, gfc_build_compare_string,
2777
        gfc_trans_string_copy): Adjust callers.
2778
        * config-lang.in (gtfiles): Add fortran/trans-stmt.c.
2779
        * trans-stmt.c: Include ggc.h and gt-fortran-trans-stmt.h.
2780
        (select_struct): Move to toplevel, add GTY(()).
2781
        (gfc_trans_character_select): Optimize SELECT CASE
2782
        with character length 1.
2783
 
2784
2010-07-15  Nathan Froyd  
2785
 
2786
        * f95-lang.c: Carefully replace TREE_CHAIN with DECL_CHAIN.
2787
        * trans-common.c: Likewise.
2788
        * trans-decl.c: Likewise.
2789
        * trans-types.c: Likewise.
2790
        * trans.c: Likewise.
2791
 
2792
2010-07-15  Janus Weil  
2793
 
2794
        PR fortran/44936
2795
        * resolve.c (resolve_typebound_generic_call): Resolve generic
2796
        non-polymorphic type-bound procedure calls to the correct specific
2797
        procedure.
2798
        (resolve_typebound_subroutine): Remove superfluous code.
2799
 
2800
2010-07-15  Daniel Kraft  
2801
 
2802
        PR fortran/44709
2803
        * trans.h (struct gfc_wrapped_block): New struct.
2804
        (gfc_start_wrapped_block), (gfc_add_init_cleanup): New methods.
2805
        (gfc_finish_wrapped_block): New method.
2806
        (gfc_init_default_dt): Add new init code to block rather than
2807
        returning it.
2808
        * trans-array.h (gfc_trans_auto_array_allocation): Use gfc_wrapped_block
2809
        (gfc_trans_dummy_array_bias): Ditto.
2810
        (gfc_trans_g77_array): Ditto.
2811
        (gfc_trans_deferred_array): Ditto.
2812
        * trans.c (gfc_add_expr_to_block): Call add_expr_to_chain.
2813
        (add_expr_to_chain): New method based on old gfc_add_expr_to_block.
2814
        (gfc_start_wrapped_block), (gfc_add_init_cleanup): New methods.
2815
        (gfc_finish_wrapped_block): New method.
2816
        * trans-array.c (gfc_trans_auto_array_allocation): use gfc_wrapped_block
2817
        (gfc_trans_g77_array), (gfc_trans_dummy_array_bias): Ditto.
2818
        (gfc_trans_deferred_array): Ditto.
2819
        * trans-decl.c (gfc_trans_dummy_character): Ditto.
2820
        (gfc_trans_auto_character_variable), (gfc_trans_assign_aux_var): Ditto.
2821
        (init_intent_out_dt): Ditto.
2822
        (gfc_init_default_dt): Add new init code to block rather than
2823
        returning it.
2824
        (gfc_trans_deferred_vars): Use gfc_wrapped_block to collect all init
2825
        and cleanup code and put it all together.
2826
 
2827
2010-07-15  Jakub Jelinek  
2828
 
2829
        * trans.h (gfc_build_compare_string): Add CODE argument.
2830
        * trans-intrinsic.c (gfc_conv_intrinsic_strcmp): Pass OP to
2831
        gfc_build_compare_string.
2832
        * trans-expr.c (gfc_conv_expr_op): Pass CODE to
2833
        gfc_build_compare_string.
2834
        (string_to_single_character): Rename len variable to length.
2835
        (gfc_optimize_len_trim): New function.
2836
        (gfc_build_compare_string): Add CODE argument.  If it is EQ_EXPR
2837
        or NE_EXPR and one of the strings is string literal with LEN_TRIM
2838
        bigger than the length of the other string, they compare unequal.
2839
 
2840
        PR fortran/40206
2841
        * trans-stmt.c (gfc_trans_character_select): Always use NULL for high
2842
        in CASE_LABEL_EXPR and use NULL for low for the default case.
2843
 
2844
2010-07-14  Mikael Morin  
2845
 
2846
        * trans-array.c (gfc_conv_section_upper_bound): Remove
2847
        (gfc_conv_section_startstride): Don't set the upper bound in the
2848
        vector subscript case.
2849
        (gfc_conv_loop_setup): Don't use gfc_conv_section_upper_bound
2850
 
2851
2010-07-14  Janus Weil  
2852
 
2853
        PR fortran/44925
2854
        * gfortran.h (gfc_is_data_pointer): Remove prototype.
2855
        * dependency.c (gfc_is_data_pointer): Make it static.
2856
        * intrinsic.texi: Update documentation on C_LOC.
2857
        * resolve.c (gfc_iso_c_func_interface): Fix pointer and target checks
2858
        and add a check for polymorphic variables.
2859
 
2860
2010-07-14  Jakub Jelinek  
2861
 
2862
        * trans-expr.c (string_to_single_character): Also optimize
2863
        string literals containing a single char followed only by spaces.
2864
        (gfc_trans_string_copy): Remove redundant string_to_single_character
2865
        calls.
2866
 
2867
        * trans-decl.c (gfc_build_intrinsic_function_decls,
2868
        gfc_build_builtin_function_decls): Mark functions as
2869
        DECL_PURE_P or TREE_READONLY.
2870
 
2871
2010-07-13  Nathan Froyd  
2872
 
2873
        * trans-decl.c (build_entry_thunks): Call build_call_expr_loc_vec
2874
        instead of build_function_call_expr.
2875
        * trans-intrinsic.c (gfc_conv_intrinsic_sr_kind): Likewise.
2876
 
2877
2010-07-13  Tobias Burnus  
2878
            Daniel Franke  
2879
 
2880
        PR fortran/43665
2881
        * trans.h (gfc_build_library_function_decl_with_spec): New prototype.
2882
        * trans-decl.c (gfc_build_library_function_decl_with_spec): Removed
2883
        static.
2884
        * trans-io (gfc_build_io_library_fndecls): Add "fn spec" annotations.
2885
 
2886
2010-07-13  Daniel Franke  
2887
            Tobias Burnus  
2888
 
2889
        PR fortran/43665
2890
        * trans-decl.c (gfc_build_intrinsic_function_decls): Add
2891
        noclobber/noescape annotations to function calls.
2892
        (gfc_build_builtin_function_decls): Likewise.
2893
 
2894
2010-07-13  Janus Weil  
2895
 
2896
        PR fortran/44434
2897
        PR fortran/44565
2898
        PR fortran/43945
2899
        PR fortran/44869
2900
        * gfortran.h (gfc_find_derived_vtab): Modified prototype.
2901
        * class.c (gfc_build_class_symbol): Modified call to
2902
        'gfc_find_derived_vtab'.
2903
        (add_proc_component): Removed, moved code into 'add_proc_comp'.
2904
        (add_proc_comps): Renamed to 'add_proc_comp', removed treatment of
2905
        generics.
2906
        (add_procs_to_declared_vtab1): Removed unnecessary argument 'resolved'.
2907
        Removed treatment of generics.
2908
        (copy_vtab_proc_comps): Removed unnecessary argument 'resolved'.
2909
        Call 'add_proc_comp' instead of duplicating code.
2910
        (add_procs_to_declared_vtab): Removed unnecessary arguments 'resolved'
2911
        and 'declared'.
2912
        (add_generic_specifics,add_generics_to_declared_vtab): Removed.
2913
        (gfc_find_derived_vtab): Removed unnecessary argument 'resolved'.
2914
        Removed treatment of generics.
2915
        * iresolve.c (gfc_resolve_extends_type_of): Modified call to
2916
        'gfc_find_derived_vtab'.
2917
        * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
2918
        Removed treatment of generics.
2919
        (resolve_select_type,resolve_fl_derived): Modified call to
2920
        'gfc_find_derived_vtab'.
2921
        * trans-decl.c (gfc_get_symbol_decl): Ditto.
2922
        * trans-expr.c (gfc_conv_derived_to_class,gfc_trans_class_assign):
2923
        Ditto.
2924
        * trans-stmt.c (gfc_trans_allocate): Ditto.
2925
 
2926
2010-07-12  Jerry DeLisle  
2927
 
2928
        PR fortran/37077
2929
        * trans-io.c (build_dt): Set common.unit to flag chracter(kind=4)
2930
        internal unit.
2931
 
2932
2010-07-12  Mikael Morin  
2933
 
2934
        * expr.c (gfc_get_int_expr): Don't initialize mpfr data twice.
2935
        * resolve.c (build_default_init_expr): Ditto.
2936
 
2937
2010-07-11  Tobias Burnus  
2938
 
2939
        PR fortran/44702
2940
        * module.c (sort_iso_c_rename_list): Remove.
2941
        (import_iso_c_binding_module,use_iso_fortran_env_module):
2942
        Allow multiple imports of the same symbol.
2943
 
2944
2010-07-11  Mikael Morin  
2945
 
2946
        * arith.c (gfc_arith_done_1): Release mpfr internal caches.
2947
 
2948
2010-07-11  Janus Weil  
2949
 
2950
        PR fortran/44869
2951
        * decl.c (build_sym,attr_decl1): Only build the class container if the
2952
        symbol has sufficient attributes.
2953
        * expr.c (gfc_check_pointer_assign): Use class_pointer instead of
2954
        pointer attribute for classes.
2955
        * match.c (gfc_match_allocate,gfc_match_deallocate): Ditto.
2956
        * module.c (MOD_VERSION): Bump.
2957
        (enum ab_attribute,attr_bits): Add AB_CLASS_POINTER.
2958
        (mio_symbol_attribute): Handle class_pointer attribute.
2959
        * parse.c (parse_derived): Use class_pointer instead of pointer
2960
        attribute for classes.
2961
        * primary.c (gfc_variable_attr,gfc_expr_attr): Ditto.
2962
        * resolve.c (resolve_structure_cons,resolve_deallocate_expr,
2963
        resolve_allocate_expr,resolve_fl_derived): Ditto.
2964
        (resolve_fl_var_and_proc): Check for class_ok attribute.
2965
 
2966
2010-07-10  Mikael Morin  
2967
 
2968
        * trans-io.c (gfc_build_st_parameter): Update calls to
2969
        gfc_add_field_to_struct.
2970
        * trans-stmt.c (ADD_FIELD): Ditto.
2971
        * trans-types.c
2972
        (gfc_get_derived_type): Ditto. Don't create backend_decl for C_PTR's
2973
        C_ADDRESS field.
2974
        (gfc_add_field_to_struct_1): Set TYPE_FIELDS(context) instead of
2975
        fieldlist, remove fieldlist from argument list.
2976
        (gfc_add_field_to_struct): Update call to gfc_add_field_to_struct_1
2977
        and remove fieldlist from argument list.
2978
        (gfc_get_desc_dim_type, gfc_get_array_descriptor_base,
2979
        gfc_get_mixed_entry_union): Move setting
2980
        TYPE_FIELDS to gfc_add_field_to_struct_1 and update calls to it.
2981
        * trans-types.h (gfc_add_field_to_struct): Update prototype.
2982
 
2983
2010-07-10  Paul Thomas  
2984
 
2985
        PR fortran/44773
2986
        * trans-expr.c (arrayfunc_assign_needs_temporary): No temporary
2987
        if the lhs has never been host associated, as well as not being
2988
        use associated, a pointer or a target.
2989
        * resolve.c (resolve_variable): Mark variables that are host
2990
        associated.
2991
        * gfortran.h: Add the host_assoc bit to the symbol_attribute
2992
        structure.
2993
 
2994
2010-07-09  Janus Weil  
2995
 
2996
        * intrinsic.texi: Add documentation for SAME_TYPE_AS, EXTENDS_TYPE_OF,
2997
        STORAGE_SIZE, C_NULL_PTR and C_NULL_FUNPTR. Modify documentation of
2998
        SIZEOF and C_SIZEOF.
2999
 
3000
2010-07-08  Janus Weil  
3001
 
3002
        PR fortran/44649
3003
        * gfortran.h (gfc_isym_id): Add GFC_ISYM_C_SIZEOF,GFC_ISYM_STORAGE_SIZE.
3004
        * intrinsic.h (gfc_check_c_sizeof,gfc_check_storage_size,
3005
        gfc_resolve_storage_size): New prototypes.
3006
        * check.c (gfc_check_c_sizeof,gfc_check_storage_size): New functions.
3007
        * intrinsic.c (add_functions): Add STORAGE_SIZE.
3008
        * iresolve.c (gfc_resolve_storage_size): New function.
3009
        * trans-intrinsic.c (gfc_conv_intrinsic_sizeof): Handle polymorphic
3010
        arguments.
3011
        (gfc_conv_intrinsic_storage_size): New function.
3012
        (gfc_conv_intrinsic_function): Handle STORAGE_SIZE.
3013
 
3014
2010-07-08  Jakub Jelinek  
3015
 
3016
        PR fortran/44847
3017
        * match.c (match_exit_cycle): Error on EXIT also from collapsed
3018
        !$omp do loops.  Error on CYCLE to non-innermost collapsed
3019
        !$omp do loops.
3020
 
3021
2010-07-08  Tobias Burnus  
3022
 
3023
        PR fortran/18918
3024
        * array.c (gfc_match_array_ref): Better error message for
3025
        coarrays with too few ranks.
3026
        (match_subscript): Move one diagnostic to caller.
3027
        * gfortran.h (gfc_get_corank): Add prottype.
3028
        * expr.c (gfc_get_corank): New function.
3029
        * iresolve.c (resolve_bound): Fix rank for cobounds.
3030
        (gfc_resolve_lbound,gfc_resolve_lcobound, gfc_resolve_ubound,
3031
        gfc_resolve_ucobound, gfc_resolve_this_image): Update
3032
        resolve_bound call.
3033
 
3034
2010-07-06  Tobias Burnus  
3035
 
3036
        PR fortran/44742
3037
        * array.c (gfc_expand_constructor): Add optional diagnostic.
3038
        * gfortran.h (gfc_expand_constructor): Update prototype.
3039
        * expr.c (gfc_simplify_expr, check_init_expr,
3040
        gfc_reduce_init_expr): Update gfc_expand_constructor call.
3041
        * resolve.c (gfc_resolve_expr): Ditto.
3042
 
3043
2010-07-06  Tobias Burnus  
3044
 
3045
        * trans-decl.c: Include diagnostic-core.h besides toplev.h.
3046
        * trans-intrinsic.c: Ditto.
3047
        * trans-types.c: Ditto.
3048
        * convert.c: Include diagnostic-core.h instead of toplev.h.
3049
        * options.c: Ditto.
3050
        * trans-array.c: Ditto.
3051
        * trans-const.c: Ditto.
3052
        * trans-expr.c: Ditto.
3053
        * trans-io.c: Ditto.
3054
        * trans-openmp.c: Ditto.
3055
        * trans.c: Ditto.
3056
 
3057
2010-07-06  Thomas Koenig  
3058
 
3059
        PR fortran/PR44693
3060
        * check.c (dim_rank_check):  Also check intrinsic functions.
3061
        Adjust permissible rank for functions which reduce the rank of
3062
        their argument.  Spread is an exception, where DIM can
3063
        be one larger than the rank of array.
3064
 
3065
2010-07-05  Steven G. Kargl  
3066
 
3067
        PR fortran/44797
3068
        * fortran/io.c (resolve_tag): Check EXIST tag is a default logical.
3069
 
3070
2010-07-05  Paul Thomas  
3071
 
3072
        PR fortran/44596
3073
        * trans-types.c (gfc_get_derived_type): Derived type fields
3074
        with the vtype attribute must have TYPE_REF_CAN_ALIAS_ALL set
3075
        but build_pointer_type_for_mode must be used for this.
3076
 
3077
2010-07-05  Nathan Froyd  
3078
 
3079
        * trans.h (gfc_conv_procedure_call): Take a VEC instead of a tree.
3080
        * trans-intrinsic.c (gfc_conv_intrinsic_funcall): Adjust for new
3081
        type of gfc_conv_procedure_call.
3082
        (conv_generic_with_optional_char_arg): Likewise.
3083
        * trans-stmt.c (gfc_trans_call): Likewise.
3084
        * trans-expr.c (gfc_conv_function_expr): Likewise.
3085
        (gfc_conv_procedure_call): Use build_call_vec instead of
3086
        build_call_list.
3087
 
3088
2010-07-04  Daniel Kraft  
3089
 
3090
        * gfc-internals.texi (gfc_code): Document BLOCK and ASSOCIATE.
3091
 
3092
2010-07-04  Paul Thomas  
3093
 
3094
        PR fortran/44596
3095
        PR fortran/44745
3096
        * trans-types.c (gfc_get_derived_type): Derived type fields
3097
        with the vtype attribute must have TYPE_REF_CAN_ALIAS_ALL set.
3098
 
3099
2010-07-02  Mikael Morin  
3100
 
3101
        PR fortran/44662
3102
        * decl.c (match_procedure_in_type): Clear structure before using.
3103
        (gfc_match_generic): Ditto.
3104
 
3105
2010-07-02  Nathan Froyd  
3106
 
3107
        * trans-types.h (gfc_add_field_to_struct): Add tree ** parameter.
3108
        * trans-types.c (gfc_add_field_to_struct_1): New function, most
3109
        of which comes from...
3110
        (gfc_add_field_to_struct): ...here.  Call it.  Add new parameter.
3111
        (gfc_get_desc_dim_type): Call gfc_add_field_to_struct_1 for
3112
        building fields.
3113
        (gfc_get_array_descriptor_base): Likewise.
3114
        (gfc_get_mixed_entry_union): Likewise.
3115
        (gfc_get_derived_type): Add extra chain parameter for
3116
        gfc_add_field_to_struct.
3117
        * trans-stmt.c (gfc_trans_character_select): Likewise.
3118
        * trans-io.c (gfc_build_st_parameter): Likewise.
3119
 
3120
2010-06-29  Janus Weil  
3121
 
3122
        PR fortran/44718
3123
        * resolve.c (is_external_proc): Prevent procedure pointers from being
3124
        regarded as external procedures.
3125
 
3126
2010-06-29  Janus Weil  
3127
 
3128
        PR fortran/44696
3129
        * trans-intrinsic.c (gfc_conv_associated): Handle polymorphic variables
3130
        passed as second argument of ASSOCIATED.
3131
 
3132
2010-06-29  Paul Thomas  
3133
 
3134
        PR fortran/44582
3135
        * trans-expr.c (arrayfunc_assign_needs_temporary): New function
3136
        to determine if a function assignment can be made without a
3137
        temporary.
3138
        (gfc_trans_arrayfunc_assign): Move all the conditions that
3139
        suppress the direct function call to the above new functon and
3140
        call it.
3141
 
3142
2010-06-28  Paul Thomas  
3143
 
3144
        PR fortran/40158
3145
        * interface.c (argument_rank_mismatch): New function.
3146
        (compare_parameter): Call new function instead of generating
3147
        the error directly.
3148
 
3149
2010-06-28  Nathan Froyd  
3150
 
3151
        * trans-openmp.c (dovar_init): Define.  Define VECs containing it.
3152
        (gfc_trans_omp_do): Use a VEC to accumulate variables and their
3153
        initializers.
3154
 
3155
2010-06-28  Steven Bosscher  
3156
 
3157
        * Make-lang.in: Update dependencies.
3158
 
3159
2010-06-27  Nathan Froyd  
3160
 
3161
        * gfortran.h (gfc_code): Split backend_decl field into cycle_label
3162
        and exit_label fields.
3163
        * trans-openmp.c (gfc_trans_omp_do): Assign to new fields
3164
        individually.
3165
        * trans-stmt.c (gfc_trans_simple_do): Likewise.
3166
        (gfc_trans_do): Likewise.
3167
        (gfc_trans_do_while): Likewise.
3168
        (gfc_trans_cycle): Use cycle_label directly.
3169
        (gfc_trans_exit): Use exit_label directly.
3170
 
3171
2010-06-27  Daniel Kraft  
3172
 
3173
        * dump-parse-tree.c (show_symbol): Dump target-expression for
3174
        associate names.
3175
        (show_code_node): Make distinction between BLOCK and ASSOCIATE.
3176
        (show_namespace): Use show_level for correct indentation of
3177
        "inner namespaces" (contained procedures or BLOCK).
3178
 
3179
2010-06-27  Thomas Koenig  
3180
 
3181
        PR fortran/44678
3182
        * dump-parse-tree.c (show_code_node):  Show namespace for
3183
        EXEC_BLOCK.
3184
 
3185
2010-06-26  Tobias Burnus  
3186
 
3187
        * decl.c (gfc_match_decl_type_spec): Support
3188
        TYPE(intrinsic-type-spec).
3189
 
3190
2010-06-25  Tobias Burnus  
3191
 
3192
        * intrinsic.h (gfc_check_selected_real_kind,
3193
        gfc_simplify_selected_real_kind): Update prototypes.
3194
        * intrinsic.c (add_functions): Add radix support to
3195
        selected_real_kind.
3196
        * check.c (gfc_check_selected_real_kind): Ditto.
3197
        * simplify.c (gfc_simplify_selected_real_kind): Ditto.
3198
        * trans-decl.c (gfc_build_intrinsic_function_decls):
3199
        Change call from selected_real_kind to selected_real_kind2008.
3200
        * intrinsic.texi (SELECTED_REAL_KIND): Update for radix.
3201
        (PRECISION, RANGE, RADIX): Add cross @refs.
3202
 
3203
2010-06-25  Tobias Burnus  
3204
 
3205
        * decl.c (gfc_match_entry): Mark ENTRY as GFC_STD_F2008_OBS.
3206
        * gfortran.texi (_gfortran_set_options): Update for
3207
        GFC_STD_F2008_OBS addition.
3208
        * libgfortran.h: Add GFC_STD_F2008_OBS.
3209
        * options.c (set_default_std_flags, gfc_handle_option): Handle
3210
        GFC_STD_F2008_OBS.
3211
        io.c (check_format): Fix allow_std check.
3212
 
3213
2010-06-25  Tobias Burnus  
3214
 
3215
        * decl.c (gfc_match_entry): Allow END besides
3216
        END SUBROUTINE/END FUNCTION for contained procedures.
3217
 
3218
2010-06-25  Tobias Burnus  
3219
 
3220
        * parse.c (next_free, next_fixed): Allow ";" as first character.
3221
 
3222
2010-06-24  Tobias Burnus  
3223
 
3224
        PR fortran/44614
3225
        * decl.c (variable_decl): Fix IMPORT diagnostic for CLASS.
3226
 
3227
2010-06-22  Janus Weil  
3228
 
3229
        PR fortran/44616
3230
        * resolve.c (resolve_fl_derived): Avoid checking for abstract on class
3231
        containers.
3232
 
3233
2010-06-21  Tobias Burnus  
3234
 
3235
        PR fortran/40632
3236
        * interface.c (compare_parameter): Add gfc_is_simply_contiguous
3237
        checks.
3238
        * symbol.c (gfc_add_contiguous): New function.
3239
        (gfc_copy_attr, check_conflict): Handle contiguous attribute.
3240
        * decl.c (match_attr_spec): Ditto.
3241
        (gfc_match_contiguous): New function.
3242
        * resolve.c (resolve_fl_derived, resolve_symbol): Handle
3243
        contiguous.
3244
        * gfortran.h (symbol_attribute): Add contiguous.
3245
        (gfc_is_simply_contiguous): Add prototype.
3246
        (gfc_add_contiguous): Add prototype.
3247
        * match.h (gfc_match_contiguous): Add prototype.
3248
        * parse.c (decode_specification_statement,
3249
        decode_statement): Handle contiguous attribute.
3250
        * expr.c (gfc_is_simply_contiguous): New function.
3251
        * dump-parse-tree.c (show_attr): Handle contiguous.
3252
        * module.c (ab_attribute, attr_bits, mio_symbol_attribute):
3253
        Ditto.
3254
        * trans-expr.c (gfc_add_interface_mapping): Copy
3255
        attr.contiguous.
3256
        * trans-array.c (gfc_conv_descriptor_stride_get,
3257
        gfc_conv_array_parameter): Handle contiguous arrays.
3258
        * trans-types.c (gfc_build_array_type, gfc_build_array_type,
3259
        gfc_sym_type, gfc_get_derived_type, gfc_get_array_descr_info):
3260
        Ditto.
3261
        * trans.h (gfc_array_kind): Ditto.
3262
        * trans-decl.c (gfc_get_symbol_decl): Ditto.
3263
 
3264
2010-06-20  Joseph Myers  
3265
 
3266
        * options.c (gfc_handle_option): Don't handle N_OPTS.
3267
 
3268
2010-06-19  Janus Weil  
3269
 
3270
        PR fortran/44584
3271
        * resolve.c (resolve_fl_derived): Reverse ordering of conditions
3272
        to avoid ICE.
3273
 
3274
2010-06-18  Tobias Burnus  
3275
 
3276
        PR fortran/44556
3277
        * resolve.c (resolve_allocate_deallocate): Properly check
3278
        part-refs in stat=/errmsg= for invalid use.
3279
 
3280
2010-06-17  Janus Weil  
3281
 
3282
        PR fortran/44558
3283
        * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
3284
        Return directly in case of an error.
3285
 
3286
2010-06-16  Janus Weil  
3287
 
3288
        PR fortran/44549
3289
        * gfortran.h (gfc_get_typebound_proc): Modified Prototype.
3290
        * decl.c (match_procedure_in_type): Give a unique gfc_typebound_proc
3291
        structure to each procedure in a procedure list.
3292
        * module.c (mio_typebound_proc): Add NULL argument to
3293
        'gfc_get_typebound_proc'.
3294
        * symbol.c (gfc_get_typebound_proc): Add a new argument, which is used
3295
        to initialize the new structure.
3296
 
3297
2010-06-15  Janus Weil  
3298
 
3299
        PR fortran/43388
3300
        * gfortran.h (gfc_expr): Add new member 'mold'.
3301
        * match.c (gfc_match_allocate): Implement the MOLD tag.
3302
        * resolve.c (resolve_allocate_expr): Ditto.
3303
        * trans-stmt.c (gfc_trans_allocate): Ditto.
3304
 
3305
2010-06-15  Jakub Jelinek  
3306
 
3307
        PR fortran/44536
3308
        * trans-openmp.c (gfc_omp_predetermined_sharing): Don't return
3309
        OMP_CLAUSE_DEFAULT_SHARED for artificial vars with
3310
        GFC_DECL_SAVED_DESCRIPTOR set.
3311
        (gfc_omp_report_decl): New function.
3312
        * trans.h (gfc_omp_report_decl): New prototype.
3313
        * f95-lang.c (LANG_HOOKS_OMP_REPORT_DECL): Redefine.
3314
 
3315
2010-06-13  Daniel Franke  
3316
 
3317
        PR fortran/31588
3318
        PR fortran/43954
3319
        * gfortranspec.c (lang_specific_driver): Removed deprecation
3320
        warning for -M.
3321
        * lang.opt: Add options -M, -MM, -MD, -MMD, -MF, -MG, -MP, -MT, -MQ.
3322
        * lang-specs.h (CPP_FORWARD_OPTIONS): Add -M* options.
3323
        * cpp.h (gfc_cpp_makedep): New.
3324
        (gfc_cpp_add_dep): New.
3325
        (gfc_cpp_add_target): New.
3326
        * cpp.c (gfc_cpp_option): Add deps* members.
3327
        (gfc_cpp_makedep): New.
3328
        (gfc_cpp_add_dep): New.
3329
        (gfc_cpp_add_target): New.
3330
        (gfc_cpp_init_options): Initialize new options.
3331
        (gfc_cpp_handle_option): Handle new options.
3332
        (gfc_cpp_post_options): Map new options to libcpp-options.
3333
        (gfc_cpp_init): Handle deferred -MQ and -MT options.
3334
        (gfc_cpp_done): If requested, write dependencies to file.
3335
        * module.c (gfc_dump_module): Add a module filename as target.
3336
        * scanner.c (open_included_file): New parameter system; add the
3337
        included file as dependency.
3338
        (gfc_open_included_file): Add the included file as dependency.
3339
        (gfc_open_intrinsic_module): Likewise.
3340
        * invoke.texi: Removed deprecation warning for -M.
3341
        * gfortran.texi: Removed Makefile-dependencies project.
3342
 
3343
2010-06-12  Daniel Franke  
3344
 
3345
        * resolve.c (resolve_global_procedure): Improved checking if an
3346
        explicit interface is required.
3347
 
3348
2010-06-12  Francois-Xavier Coudert  
3349
 
3350
        * trans-decl.c (gfc_build_intrinsic_function_decls): Fix
3351
        return type.
3352
        * trans-intrinsic.c (gfc_conv_intrinsic_fdate): Fix argument type.
3353
        (gfc_conv_intrinsic_ttynam): Likewise.
3354
        (gfc_conv_intrinsic_trim): Likewise.
3355
 
3356
2010-06-12  Janus Weil  
3357
 
3358
        PR fortran/40117
3359
        * decl.c (match_procedure_in_type): Allow procedure lists (F08).
3360
 
3361
2010-06-11  Francois-Xavier Coudert  
3362
 
3363
        * trans-intrinsic.c (gfc_build_intrinsic_lib_fndecls): Fix comment.
3364
 
3365
2010-06-11  Francois-Xavier Coudert  
3366
 
3367
        * mathbuiltins.def: Add builtins that do not directly correspond
3368
        to a Fortran intrinsic, with new macro OTHER_BUILTIN.
3369
        * f95-lang.c (gfc_init_builtin_functions): Define OTHER_BUILTIN.
3370
        * trans-intrinsic.c (gfc_intrinsic_map_t): Remove
3371
        code_{r,c}{4,8,10,16} fields. Add
3372
        {,complex}{float,double,long_double}_built_in fields.
3373
        (gfc_intrinsic_map): Adjust definitions of DEFINE_MATH_BUILTIN,
3374
        DEFINE_MATH_BUILTIN_C and LIB_FUNCTION accordingly. Add
3375
        definition of OTHER_BUILTIN.
3376
        (real_compnt_info): Remove unused struct.
3377
        (builtin_decl_for_precision, builtin_decl_for_float_kind): New
3378
        functions.
3379
        (build_round_expr): Call builtin_decl_for_precision instead of
3380
        series of if-else.
3381
        (gfc_conv_intrinsic_aint): Call builtin_decl_for_float_kind
3382
        instead of a switch.
3383
        (gfc_build_intrinsic_lib_fndecls): Match
3384
        {real,complex}{4,8,10,16}decl into the C-style built_in_decls.
3385
        (gfc_get_intrinsic_lib_fndecl): Do not hardcode floating-point
3386
        kinds.
3387
        (gfc_conv_intrinsic_lib_function): Go through all the extended
3388
        gfc_intrinsic_map.
3389
        (gfc_trans_same_strlen_check): Call builtin_decl_for_float_kind
3390
        instead of a switch.
3391
        (gfc_conv_intrinsic_abs): Likewise.
3392
        (gfc_conv_intrinsic_mod): Likewise.
3393
        (gfc_conv_intrinsic_sign): Likewise.
3394
        (gfc_conv_intrinsic_fraction): Likewise.
3395
        (gfc_conv_intrinsic_nearest): Likewise.
3396
        (gfc_conv_intrinsic_spacing): Likewise.
3397
        (gfc_conv_intrinsic_rrspacing): Likewise.
3398
        (gfc_conv_intrinsic_scale): Likewise.
3399
        (gfc_conv_intrinsic_set_exponent): Likewise.
3400
 
3401
2010-06-11  Paul Thomas  
3402
 
3403
        PR fortran/42051
3404
        PR fortran/43896
3405
        * trans-expr.c (gfc_conv_derived_to_class): Handle array-valued
3406
        functions with CLASS formal arguments.
3407
 
3408
2010-06-10  Janus Weil  
3409
 
3410
        PR fortran/44207
3411
        * resolve.c (conformable_arrays): Handle allocatable components.
3412
 
3413
2010-06-10  Francois-Xavier Coudert  
3414
 
3415
        PR fortran/38273
3416
        * gfortran.texi: Document that Cray pointers cannot be function
3417
        results.
3418
 
3419
2010-06-10  Francois-Xavier Coudert  
3420
 
3421
        PR fortran/36234
3422
        * gfortran.texi: Document lack of support for syntax
3423
        "complex FUNCTION name*16()", and existence of alternative
3424
        legacy syntax "complex*16 FUNCTION name()".
3425
 
3426
2010-06-10  Francois-Xavier Coudert  
3427
 
3428
        PR fortran/43032
3429
        * intrinsic.texi (FLUSH): Note the difference between FLUSH and
3430
        POSIX's fsync(), and how to call the latter from Fortran code.
3431
 
3432
2010-06-10  Daniel Franke  
3433
 
3434
        PR fortran/44457
3435
        * interface.c (compare_actual_formal): Reject actual arguments with
3436
        array subscript passed to ASYNCHRONOUS dummys.
3437
 
3438
2010-06-10  Daniel Kraft  
3439
 
3440
        PR fortran/38936
3441
        * gfortran.h (enum gfc_statement): Add ST_ASSOCIATE, ST_END_ASSOCIATE.
3442
        (struct gfc_symbol): New field `assoc'.
3443
        (struct gfc_association_list): New struct.
3444
        (struct gfc_code): New struct `block' in union, move `ns' there
3445
        and add association list.
3446
        (gfc_free_association_list): New method.
3447
        (gfc_has_vector_subscript): Made public;
3448
        * match.h (gfc_match_associate): New method.
3449
        * parse.h (enum gfc_compile_state): Add COMP_ASSOCIATE.
3450
        * decl.c (gfc_match_end): Handle ST_END_ASSOCIATE.
3451
        * interface.c (gfc_has_vector_subscript): Made public.
3452
        (compare_actual_formal): Rename `has_vector_subscript' accordingly.
3453
        * match.c (gfc_match_associate): New method.
3454
        (gfc_match_select_type): Change reference to gfc_code's `ns' field.
3455
        * primary.c (match_variable): Don't allow names associated to expr here.
3456
        * parse.c (decode_statement): Try matching ASSOCIATE statement.
3457
        (case_exec_markers, case_end): Add ASSOCIATE statement.
3458
        (gfc_ascii_statement): Hande ST_ASSOCIATE and ST_END_ASSOCIATE.
3459
        (parse_associate): New method.
3460
        (parse_executable): Handle ST_ASSOCIATE.
3461
        (parse_block_construct): Change reference to gfc_code's `ns' field.
3462
        * resolve.c (resolve_select_type): Ditto.
3463
        (resolve_code): Ditto.
3464
        (resolve_block_construct): Ditto and add comment.
3465
        (resolve_select_type): Set association list in generated BLOCK to NULL.
3466
        (resolve_symbol): Resolve associate names.
3467
        * st.c (gfc_free_statement): Change reference to gfc_code's `ns' field
3468
        and free association list.
3469
        (gfc_free_association_list): New method.
3470
        * symbol.c (gfc_new_symbol): NULL new field `assoc'.
3471
        * trans-stmt.c (gfc_trans_block_construct): Change reference to
3472
        gfc_code's `ns' field.
3473
 
3474
2010-06-10  Kai Tietz  
3475
 
3476
        * error.c (error_print): Pre-initialize loc by NULL.
3477
        * openmp.c (resolve_omp_clauses): Add explicit
3478
        braces to avoid ambigous else.
3479
        * array.c (match_subscript): Pre-initialize m to MATCH_ERROR.
3480
 
3481
2010-06-10  Gerald Pfeifer  
3482
 
3483
        * gfc-internals.texi: Move to GFDL 1.3.
3484
        * gfortran.texi: Ditto.
3485
        * intrinsic.texi: Ditto.
3486
        * invoke.texi: Ditto.
3487
 
3488
2010-06-09  Daniel Franke  
3489
 
3490
        PR fortran/44347
3491
        * check.c (gfc_check_selected_real_kind): Verify that the
3492
        actual arguments are scalar.
3493
 
3494
2010-06-09  Daniel Franke  
3495
 
3496
        PR fortran/44359
3497
        * intrinsic.c (gfc_convert_type_warn): Further improve -Wconversion.
3498
 
3499
2010-06-09  Janus Weil  
3500
 
3501
        PR fortran/44430
3502
        * dump-parse-tree.c (show_symbol): Avoid infinite loop.
3503
 
3504
2010-06-09  Steven G. Kargl  
3505
 
3506
        * fortran/symbol.c (check_conflict):  Remove an invalid conflict check.
3507
 
3508
2010-06-09  Steven G. Kargl  
3509
 
3510
        * fortran/intrinsic.c (add_functions): Change gfc_check_btest,
3511
        gfc_check_ibclr, and gfc_check_ibset to gfc_check_bitfcn.
3512
        * fortran/intrinsic.h: Remove prototypes for gfc_check_btest,
3513
        gfc_check_ibclr, and gfc_check_ibset.  Add prototype for
3514
        gfc_check_bitfcn.
3515
        * fortran/check.c (nonnegative_check, less_than_bitsize1,
3516
        less_than_bitsize2): New functions.
3517
        (gfc_check_btest): Renamed to gfc_check_bitfcn.  Use
3518
        nonnegative_check and less_than_bitsize1.
3519
        (gfc_check_ibclr, gfc_check_ibset): Removed.
3520
        (gfc_check_ibits,gfc_check_mvbits): Use nonnegative_check and
3521
        less_than_bitsize1.
3522
 
3523
2010-06-09  Janus Weil  
3524
 
3525
        PR fortran/44211
3526
        * resolve.c (resolve_typebound_function,resolve_typebound_subroutine):
3527
        Resolve references.
3528
 
3529
2010-06-09  Kai Tietz  
3530
 
3531
        * resolve.c (resolve_deallocate_expr): Avoid warning
3532
        about possible use of iunitialized sym.
3533
        (resolve_allocate_expr): Pre-initialize sym by NULL.
3534
 
3535
2010-06-09  Francois-Xavier Coudert  
3536
 
3537
        PR fortran/43040
3538
        * f95-lang.c (gfc_init_builtin_functions): Remove comment.
3539
 
3540
2010-06-08  Laurynas Biveinis  
3541
 
3542
        * trans-types.c (gfc_get_nodesc_array_type): Use typed GC
3543
        allocation.
3544
        (gfc_get_array_type_bounds): Likewise.
3545
 
3546
        * trans-decl.c (gfc_allocate_lang_decl): Likewise.
3547
        (gfc_find_module): Likewise.
3548
 
3549
        * f95-lang.c (pushlevel): Likewise.
3550
 
3551
        * trans.h (struct lang_type): Add variable_size GTY option.
3552
        (struct lang_decl): Likewise.
3553
 
3554
2010-06-08  Tobias Burnus  
3555
 
3556
        PR fortran/44446
3557
        * symbol.c (check_conflict): Move protected--external/procedure check ...
3558
        * resolve.c (resolve_select_type): ... to the resolution stage.
3559
 
3560
2010-06-07  Tobias Burnus  
3561
 
3562
        * options.c (gfc_handle_option): Fix -fno-recursive.
3563
 
3564
2010-06-07  Tobias Burnus  
3565
 
3566
        * gfc-internals.texi (copyrights-gfortran): Fix copyright year format.
3567
        * gfortran.texi (copyrights-gfortran): Ditto.
3568
 
3569
2010-06-07  Joseph Myers  
3570
 
3571
        * lang.opt (fshort-enums): Define using Var and VarExists.
3572
        * options.c (gfc_handle_option): Don't set flag_short_enums here.
3573
 
3574
2010-06-05  Paul Thomas  
3575
            Janus Weil  
3576
 
3577
        PR fortran/43945
3578
        * resolve.c (get_declared_from_expr): Move to before
3579
        resolve_typebound_generic_call.  Make new_ref and class_ref
3580
        ignorable if set to NULL.
3581
        (resolve_typebound_generic_call): Once we have resolved the
3582
        generic call, check that the specific instance is that which
3583
        is bound to the declared type.
3584
        (resolve_typebound_function,resolve_typebound_subroutine): Avoid
3585
        freeing 'class_ref->next' twice.
3586
 
3587
2010-06-05  Paul Thomas  
3588
 
3589
        PR fortran/43895
3590
        * trans-array.c (structure_alloc_comps): Dereference scalar
3591
        'decl' if it is a REFERENCE_TYPE. Tidy expressions containing
3592
        TREE_TYPE (decl).
3593
 
3594
2010-06-04  Joseph Myers  
3595
 
3596
        * gfortranspec.c (append_arg, lang_specific_driver): Use
3597
        GCC-specific formats in diagnostics.
3598
 
3599
2010-06-02  Tobias Burnus  
3600
 
3601
        PR fortran/44360
3602
        * parse.c (gfc_fixup_sibling_symbols): Do not "fix" use-associated
3603
        symbols.
3604
 
3605
2010-06-01  Jerry DeLisle  
3606
 
3607
        PR fortran/44371
3608
        * match.c (gfc_match_stopcode): Move gfc_match_eos call inside
3609
        condition block.
3610
 
3611
2010-05-31  Steven G. Kargl  
3612
 
3613
        * fortran/gfortran.texi:  Fix typos in description of variable-format-
3614
        expressions.
3615
 
3616
2010-05-31  Thomas Koenig  
3617
 
3618
        PR fortran/36928
3619
        * dependency.c (gfc_check_section_vs_section):  Check
3620
        for interleaving array assignments without conflicts.
3621
 
3622
2010-05-30  Janus Weil  
3623
 
3624
        * gcc/fortran/gfortran.h (CLASS_DATA): New macro for accessing the
3625
        $data component of a class container.
3626
        * gcc/fortran/decl.c (attr_decl1): Use macro CLASS_DATA.
3627
        * gcc/fortran/expr.c (gfc_check_pointer_assign,gfc_check_assign_symbol,
3628
        gfc_has_ultimate_allocatable,gfc_has_ultimate_pointer): Ditto.
3629
        * gcc/fortran/interface.c (matching_typebound_op): Ditto.
3630
        * gcc/fortran/match.c (gfc_match_allocate, gfc_match_deallocate): Ditto.
3631
        * gcc/fortran/parse.c (parse_derived): Ditto.
3632
        * gcc/fortran/primary.c (gfc_match_varspec, gfc_variable_attr,
3633
        gfc_expr_attr): Ditto.
3634
        * gcc/fortran/resolve.c (resolve_structure_cons, find_array_spec,
3635
        resolve_deallocate_expr, resolve_allocate_expr, resolve_select_type,
3636
        resolve_fl_var_and_proc, resolve_typebound_procedure,
3637
        resolve_fl_derived): Ditto.
3638
        * gcc/fortran/symbol.c (gfc_type_compatible): Restructured.
3639
        * gcc/fortran/trans-array.c (structure_alloc_comps): Use macro
3640
        CLASS_DATA.
3641
        * gcc/fortran/trans-decl.c (gfc_get_symbol_decl,
3642
        gfc_trans_deferred_vars): Ditto.
3643
        * gcc/fortran/trans-stmt.c (gfc_trans_allocate): Ditto.
3644
 
3645
2010-05-28  Tobias Burnus  
3646
 
3647
        * options.c (gfc_handle_option): Fix handling of -fno-whole-file.
3648
 
3649
2010-05-28  Joseph Myers  
3650
 
3651
        * gfortranspec.c (append_arg, lang_specific_driver): Use
3652
        fatal_error instead of fatal.  Use warning instead of fprintf for
3653
        warnings.
3654
 
3655
2010-05-28  Joseph Myers  
3656
 
3657
        * cpp.c (gfc_cpp_init_0): Use xstrerror instead of strerror.
3658
        * module.c (write_char, gfc_dump_module, gfc_use_module): Use
3659
        xstrerror instead of strerror.
3660
 
3661
2010-05-26  Joseph Myers  
3662
 
3663
        * cpp.c (cb_cpp_error): Save and restore
3664
        global_dc->warn_system_headers, not variable warn_system_headers.
3665
 
3666
2010-05-26  Steven Bosscher  
3667
 
3668
        * fortran/f95-lang.c: Do not include libfuncs.h, expr.h, and except.h.
3669
 
3670
2010-05-26  Steven Bosscher  
3671
 
3672
        * trans-common.c: Do not include rtl.h, include output.h instead.
3673
        * trans-decl.c: Likewise.
3674
 
3675
2010-05-26  Paul Thomas  
3676
 
3677
        PR fortran/40011
3678
        * resolve.c (resolve_global_procedure): Resolve the gsymbol's
3679
        namespace before trying to reorder the gsymbols.
3680
 
3681
2010-05-25  Daniel Franke  
3682
 
3683
        PR fortran/30668
3684
        PR fortran/31346
3685
        PR fortran/34260
3686
        * resolve.c (resolve_global_procedure): Add check for global
3687
        procedures with implicit interfaces and assumed-shape or optional
3688
        dummy arguments. Verify that function return type, kind and string
3689
        lengths match.
3690
 
3691
2010-05-21  Tobias Burnus  
3692
 
3693
        * gfortran.h: Do not include system.h.
3694
        * bbt.c: Include system.h.
3695
        * data.c: Ditto.
3696
        * dependency.c: Ditto.
3697
        * dump-parse-tree.c: Ditto.
3698
        * arith.h: Do not include gfortran.h.
3699
        * constructor.h: Do not include gfortran.h and splay-tree.h.
3700
        * match.h: Do not include gfortran.h.
3701
        * parse.h: Ditto.
3702
        * target-memory.h: Ditto.
3703
        * openmp.c: Do not include toplev.h and target.h.
3704
        * trans-stmt.c: Ditto not include toplev.h.
3705
        * primary.c: Ditto.
3706
        * trans-common.c: Tell why toplev.h is needed. And
3707
        do not include target.h.
3708
        * trans-expr.c: Tell why toplev.h is needed.
3709
        * trans-array.c: Ditto.
3710
        * trans-openmp.c: Ditto.
3711
        * trans-const.c: Ditto.
3712
        * trans.c: Ditto.
3713
        * trans-types.c: Ditto.
3714
        * trans-io.c: Ditto.
3715
        * trans-decl.c: Ditto.
3716
        * scanner.c: Ditto.
3717
        * convert.c: Ditto.
3718
        * trans-intrinsic.c: Ditto.
3719
        * options.c: Ditto.
3720
 
3721
2010-05-22 Jerry DeLisle 
3722
 
3723
        PR fortran/43851
3724
        * match.c (gfc_match_stopcode): Use gfc_match_init_expr. Go to cleanup
3725
        before returning MATCH_ERROR. Add check for scalar. Add check for
3726
        default integer kind.
3727
 
3728
2010-05-22  Janus Weil  
3729
 
3730
        PR fortran/44212
3731
        * match.c (gfc_match_select_type): On error jump back out of the local
3732
        namespace.
3733
        * parse.c (parse_derived): Defer creation of vtab symbols to resolution
3734
        stage, more precisely to ...
3735
        * resolve.c (resolve_fl_derived): ... this place.
3736
 
3737
2010-05-22  Janus Weil  
3738
 
3739
        PR fortran/44213
3740
        * resolve.c (ensure_not_abstract): Allow abstract types with
3741
        non-abstract ancestors.
3742
 
3743
2010-05-21  Steven Bosscher  
3744
 
3745
        * trans-const.c: Include realmpfr.h.
3746
        * Make-lang.in: Update dependencies.
3747
 
3748
2010-05-21  Steven Bosscher  
3749
 
3750
        * trans-const.c, trans-types.c, trans-intrinsic.c:
3751
        Clean up redundant includes.
3752
 
3753
2010-05-20  Daniel Franke  
3754
 
3755
        PR fortran/38407
3756
        * lang.opt (Wunused-dummy-argument): New option.
3757
        * gfortran.h (gfc_option_t): Add warn_unused_dummy_argument.
3758
        * options.c (gfc_init_options): Disable warn_unused_dummy_argument.
3759
        (set_Wall): Enable warn_unused_dummy_argument.
3760
        (gfc_handle_option): Set warn_unused_dummy_argument according to
3761
        command line.
3762
        * trans-decl.c (generate_local_decl): Separate warnings about
3763
        unused variables and unused dummy arguments.
3764
        * invoke.texi: Documented new option.
3765
 
3766
2010-05-20  Steven Bosscher  
3767
 
3768
        * trans-expr.c: Do not include convert.h, ggc.h, real.h, and gimple.h.
3769
        (gfc_conv_string_tmp): Do not assert type comparibilty.
3770
        *  trans-array.c: Do not include gimple.h, ggc.h, and real.h.
3771
        (gfc_conv_expr_descriptor): Remove assert.
3772
        * trans-common.c: Clarify why rtl.h and tm.h are included.
3773
        * trans-openmp.c: Do not include ggc.h and real.h.
3774
        Explain why gimple.h is included.
3775
        * trans-const.c: Do not include ggc.h.
3776
        * trans-stmt.c: Do not include gimple.h, ggc.h, and real.h.
3777
        * trans.c: Do not include ggc.h and real.h.
3778
        Explain why gimple.h is included.
3779
        * trans-types.c: Do not include tm.h.  Explain why langhooks.h
3780
        and dwarf2out.h are included.
3781
        * trans-io.c: Do not include gimple.h and real.h.
3782
        * trans-decl.c: Explain why gimple.h, tm.h, and rtl.h are included.
3783
        * trans-intrinsic.c: Do not include gimple.h.  Explain why tm.h
3784
        is included.
3785
 
3786
2010-05-20  Tobias Burnus  
3787
 
3788
        * options.c (gfc_init_options,gfc_post_options): Enable
3789
        flag_associative_math by default.
3790
 
3791
2010-05-19 Jerry DeLisle 
3792
 
3793
        PR fortran/43851
3794
        * trans-stmt.c (gfc_trans_stop): Add generation of call to
3795
        gfortran_error_stop_numeric. Fix up some whitespace. Use stop_string for
3796
        blank STOP, handling a null expression. (gfc_trans_pause): Use
3797
        pause_string for blank PAUSE.
3798
        * trans.h: Add external function declaration for error_stop_numeric.
3799
        * trans-decl.c (gfc_build_builtin_function_decls): Add the building of
3800
        the declaration for the library call. Adjust whitespaces.
3801
        * match.c (gfc_match_stopcode): Remove use of the actual stop code to
3802
        signal no stop code. Match the expression following the stop and pass
3803
        that to the translators. Remove the old use of digit matching.  Add
3804
        checks that the stop_code expression is INTEGER or CHARACTER, constant,
3805
        and if CHARACTER, default character KIND.
3806
 
3807
2010-05-19  Daniel Franke  
3808
 
3809
        PR fortran/44055
3810
        * lang.opt (Wconversion-extra): New option.
3811
        * gfortran.h (gfc_option_t): Add warn_conversion_extra.
3812
        * options.c (gfc_init_options): Disable -Wconversion-extra by default.
3813
        (set_Wall): Enable -Wconversion.
3814
        (gfc_handle_option): Set warn_conversion_extra.
3815
        * intrinsic.c (gfc_convert_type_warn): Ignore kind conditions
3816
        introduced for -Wconversion if -Wconversion-extra is present.
3817
        * invoke.texi: Add -Wconversion to -Wall; document new behaviour of
3818
        -Wconversion; document -Wconversion-extra.
3819
 
3820
2010-05-19  Daniel Franke  
3821
 
3822
        PR fortran/42360
3823
        * gfortran.h (gfc_has_default_initializer): New.
3824
        * expr.c (gfc_has_default_initializer): New.
3825
        * resolve.c (has_default_initializer): Removed, use
3826
        gfc_has_default_initializer() instead. Updated all callers.
3827
        * trans-array.c (has_default_initializer): Removed, use
3828
        gfc_has_default_initializer() instead. Updated all callers.
3829
        * trans-decl.c (generate_local_decl): Do not check the
3830
        first component only to check for initializers, but use
3831
        gfc_has_default_initializer() instead.
3832
 
3833
2010-05-19  Daniel Franke  
3834
 
3835
        PR fortran/38404
3836
        * primary.c (match_string_constant): Move start_locus just inside
3837
        the string.
3838
        * data.c (create_character_intializer): Clarified truncation warning.
3839
 
3840
2010-05-19  Daniel Franke  
3841
 
3842
        PR fortran/34505
3843
        * intrinsic.h (gfc_check_float): New prototype.
3844
        (gfc_check_sngl): New prototype.
3845
        * check.c (gfc_check_float): New.
3846
        (gfc_check_sngl): New.
3847
        * intrinsic.c (add_functions): Moved DFLOAT from aliasing DBLE
3848
        to be a specific for REAL. Added check routines for FLOAT, DFLOAT
3849
        and SNGL.
3850
        * intrinsic.texi: Removed individual nodes of FLOAT, DFLOAT and SNGL,
3851
        added them to the list of specifics of REAL instead.
3852
 
3853
2010-05-17  Janus Weil  
3854
 
3855
        PR fortran/43990
3856
        * trans-expr.c (gfc_conv_structure): Remove unneeded and buggy code.
3857
        This is now handled via 'gfc_class_null_initializer'.
3858
 
3859
2010-05-17  Janus Weil  
3860
 
3861
        * class.c (gfc_add_component_ref,gfc_class_null_initializer,
3862
        gfc_build_class_symbol,add_proc_component,add_proc_comps,
3863
        add_procs_to_declared_vtab1,copy_vtab_proc_comps,
3864
        add_procs_to_declared_vtab,add_generic_specifics,
3865
        add_generics_to_declared_vtab,gfc_find_derived_vtab,
3866
        find_typebound_proc_uop,gfc_find_typebound_proc,
3867
        gfc_find_typebound_user_op,gfc_find_typebound_intrinsic_op,
3868
        gfc_get_tbp_symtree): Moved here from other places.
3869
        * expr.c (gfc_add_component_ref,gfc_class_null_initializer): Move to
3870
        class.c.
3871
        * gfortran.h (gfc_build_class_symbol,gfc_find_derived_vtab,
3872
        gfc_find_typebound_proc,gfc_find_typebound_user_op,
3873
        gfc_find_typebound_intrinsic_op,gfc_get_tbp_symtree,
3874
        gfc_add_component_ref, gfc_class_null_initializer): Moved to class.c.
3875
        * Make-lang.in: Add class.o.
3876
        * symbol.c (gfc_build_class_symbol,add_proc_component,add_proc_comps,
3877
        add_procs_to_declared_vtab1,copy_vtab_proc_comps,
3878
        add_procs_to_declared_vtab,add_generic_specifics,
3879
        add_generics_to_declared_vtab,gfc_find_derived_vtab,
3880
        find_typebound_proc_uop,gfc_find_typebound_proc,
3881
        gfc_find_typebound_user_op,gfc_find_typebound_intrinsic_op,
3882
        gfc_get_tbp_symtree): Move to class.c.
3883
 
3884
2010-05-17  Nathan Froyd  
3885
 
3886
        * trans-types.c (gfc_init_types): Use build_function_type_list.
3887
        (gfc_get_ppc_type): Likewise.
3888
        * trans-decl.c (gfc_generate_constructors): Likewise.
3889
        * f95-lang.c (build_builtin_fntypes): Likewise.
3890
        (gfc_init_builtin_functions): Likewise.
3891
        (DEF_FUNCTION_TYPE_0): Likewise.
3892
        (DEF_FUNCTION_TYPE_1): Likewise.
3893
        (DEF_FUNCTION_TYPE_2): Likewise.
3894
        (DEF_FUNCTION_TYPE_3): Likewise.
3895
        (DEF_FUNCTION_TYPE_4): Likewise.
3896
        (DEF_FUNCTION_TYPE_5): Likewise.
3897
        (DEF_FUNCTION_TYPE_6): Likewise.
3898
        (DEF_FUNCTION_TYPE_7): Likewise.  Use ARG7.
3899
        (DEF_FUNCTION_TYPE_VAR_0): Use build_varags_function_type_list.
3900
 
3901
2010-05-17  Nathan Froyd  
3902
 
3903
        * trans-array.c (gfc_trans_array_constructor_value): Use
3904
        build_constructor instead of build_constructor_from_list.
3905
        (gfc_build_constant_array_constructor): Likewise.
3906
        * trans-decl.c (create_main_function): Likewise.
3907
        * trans-stmt.c (gfc_trans_character_select): Likewise.
3908
 
3909
2010-05-17  Janus Weil  
3910
 
3911
        PR fortran/44044
3912
        * resolve.c (resolve_fl_var_and_proc): Move error messages here from ...
3913
        (resolve_fl_variable_derived): ... this place.
3914
        (resolve_symbol): Make sure function symbols (and their result
3915
        variables) are not resolved twice.
3916
 
3917
2010-05-16  Daniel Franke  
3918
 
3919
        PR fortran/35779
3920
        * array.c (match_array_list): Revert change from 2010-05-13.
3921
 
3922
2010-05-16  Richard Guenther  
3923
 
3924
        * trans-decl.c (module_htab_decls_hash): Revert last change.
3925
 
3926
2010-05-16  Richard Guenther  
3927
 
3928
        * trans-decl.c (module_htab_decls_hash): Use IDENTIFIER_HASH_VALUE.
3929
 
3930
2010-05-16  Manuel López-Ibáñez  
3931
 
3932
        * options.c (set_Wall): Remove special logic for Wuninitialized
3933
        without -O.
3934
 
3935
2010-05-15  Janus Weil  
3936
 
3937
        PR fortran/44154
3938
        PR fortran/42647
3939
        * trans-decl.c (gfc_trans_deferred_vars): Modify ordering of
3940
        if branches.
3941
 
3942
2010-05-15  Janus Weil  
3943
 
3944
        PR fortran/43207
3945
        PR fortran/43969
3946
        * gfortran.h (gfc_class_null_initializer): New prototype.
3947
        * expr.c (gfc_class_null_initializer): New function to build a NULL
3948
        initializer for CLASS pointers.
3949
        * symbol.c (gfc_build_class_symbol): Modify internal naming of class
3950
        containers. Remove default NULL initialization of $data component.
3951
        * trans.c (gfc_allocate_array_with_status): Fix wording of an error
3952
        message.
3953
        * trans-expr.c (gfc_conv_initializer,gfc_trans_subcomponent_assign):
3954
        Use new function 'gfc_class_null_initializer'.
3955
        * trans-intrinsic.c (gfc_conv_allocated): Handle allocatable scalar
3956
        class variables.
3957
 
3958
2010-05-14  Steven G. Kargl  
3959
 
3960
        PR fortran/44135
3961
        * fortran/interface.c (get_sym_storage_size): Use signed instead of
3962
        unsigned mpz_get_?i routines.
3963
 
3964
2010-05-14  Jakub Jelinek  
3965
 
3966
        * trans.c (trans_code): Set backend locus early.
3967
        * trans-decl.c (gfc_get_fake_result_decl): Use source location
3968
        of the function instead of current input_location.
3969
 
3970
2010-05-13  Daniel Franke  
3971
 
3972
        PR fortran/35779
3973
        * intrinsic.c (gfc_init_expr): Renamed to gfc_init_expr_flag.
3974
        Updated all usages.
3975
        * expr.c (init_flag): Removed; use gfc_init_expr_flag everywhere.
3976
        * array.c (match_array_list): Pass on gfc_init_expr_flag when matching
3977
        iterators.
3978
 
3979
2010-05-13  Jakub Jelinek  
3980
 
3981
        PR fortran/44036
3982
        * openmp.c (resolve_omp_clauses): Allow procedure pointers in clause
3983
        variable lists.
3984
        * trans-openmp.c (gfc_omp_privatize_by_reference): Don't privatize
3985
        by reference dummy procedures or non-dummy procedure pointers.
3986
        (gfc_omp_predetermined_sharing): Return
3987
        OMP_CLAUSE_DEFAULT_FIRSTPRIVATE for dummy procedures.
3988
 
3989
2010-05-11  Daniel Franke  
3990
 
3991
        PR fortran/43711
3992
        * openmp.c (gfc_match_omp_taskwait): Report unexpected characters
3993
        after OMP statement.
3994
        (gfc_match_omp_critical): Likewise.
3995
        (gfc_match_omp_flush): Likewise.
3996
        (gfc_match_omp_workshare): Likewise.
3997
        (gfc_match_omp_master): Likewise.
3998
        (gfc_match_omp_ordered): Likewise.
3999
        (gfc_match_omp_atomic): Likewise.
4000
        (gfc_match_omp_barrier): Likewise.
4001
        (gfc_match_omp_end_nowait): Likewise.
4002
 
4003
2010-05-11  Daniel Franke  
4004
 
4005
        PR fortran/31820
4006
        * resolve.c (validate_case_label_expr): Removed FIXME.
4007
        (resolve_select): Raise default warning on case labels out of range
4008
        of the case expression.
4009
 
4010
2010-05-10  Daniel Franke  
4011
 
4012
        PR fortran/27866
4013
        PR fortran/35003
4014
        PR fortran/42809
4015
        * intrinsic.c (gfc_convert_type_warn): Be more discriminative
4016
        about conversion warnings.
4017
 
4018
2010-05-10  Janus Weil  
4019
 
4020
        PR fortran/44044
4021
        * match.c (gfc_match_select_type): Move error message to
4022
        resolve_select_type.
4023
        * resolve.c (resolve_select_type): Error message moved here from
4024
        gfc_match_select_type. Correctly set type of temporary.
4025
 
4026
2010-05-10  Richard Guenther  
4027
 
4028
        * trans-decl.c (gfc_build_library_function_decl): Split out
4029
        worker to ...
4030
        (build_library_function_decl_1): ... this new function.
4031
        Set a fnspec attribute if a specification was provided.
4032
        (gfc_build_library_function_decl_with_spec): New function.
4033
        (gfc_build_intrinsic_function_decls): Annotate internal_pack
4034
        and internal_unpack.
4035
 
4036
2010-05-07  Daniel Franke  
4037
 
4038
        PR fortran/40728
4039
        * intrinc.c (gfc_is_intrinsic): Do not prematurely mark symbol
4040
        as external.
4041
 
4042
2010-05-07  Jason Merrill  
4043
 
4044
        * trans-expr.c (gfc_conv_procedure_call): Rename nullptr to null_ptr
4045
        to avoid -Wc++-compat warning.
4046
 
4047
2010-05-06  Manuel López-Ibáñez  
4048
 
4049
        PR 40989
4050
        * options.c (gfc_handle_option): Add argument kind.
4051
        * gfortran.h (gfc_handle_option): Update declaration.
4052
 
4053
2010-05-06  Tobias Burnus  
4054
 
4055
        PR fortran/43985
4056
        * trans-types.c (gfc_sym_type): Mark Cray pointees as
4057
        GFC_POINTER_TYPE_P.
4058
 
4059
2010-05-05  Daniel Franke  
4060
 
4061
        PR fortran/32331
4062
        * resolve.c (traverse_data_list): Rephrase error message for
4063
        non-constant bounds in data-implied-do.
4064
 
4065
2010-05-05  Daniel Franke  
4066
 
4067
        PR fortran/24978
4068
        * gfortran.h: Removed repeat count from constructor, removed
4069
        all usages.
4070
        * data.h (gfc_assign_data_value_range): Changed return value from
4071
        void to gfc_try.
4072
        * data.c (gfc_assign_data_value): Add location to constructor element.
4073
        (gfc_assign_data_value_range): Call gfc_assign_data_value()
4074
        for each element in range. Return early if an error was generated.
4075
        * resolve.c (check_data_variable): Stop early if range assignment
4076
        generated an error.
4077
 
4078
2010-05-05  Janus Weil  
4079
 
4080
        PR fortran/43696
4081
        * resolve.c (resolve_fl_derived): Some fixes for class variables.
4082
        * symbol.c (gfc_build_class_symbol): Add separate class container for
4083
        class pointers.
4084
 
4085
2010-05-03  Steven G. Kargl  
4086
 
4087
        PR fortran/43592
4088
        * fortran/parse.c (parse_interface): Do not dereference a NULL pointer.
4089
 
4090
2010-05-02  Tobias Burnus  
4091
 
4092
        PR fortran/18918
4093
        * intrinsic.c (add_functions): Fix GFC_STD and add gfc_resolve_ calls
4094
        for lcobound, ucobound, image_index and this_image.
4095
        * intrinsic.h (gfc_resolve_lcobound, gfc_resolve_this_image,
4096
        gfc_resolve_image_index, gfc_resolve_ucobound): New prototypes.
4097
        * iresolve.c (gfc_resolve_lcobound, gfc_resolve_this_image,
4098
        gfc_resolve_image_index, gfc_resolve_ucobound, resolve_bound): New
4099
        functions.
4100
        (gfc_resolve_lbound, gfc_resolve_ubound): Use resolve_bound.
4101
 
4102
2010-04-30  Tobias Burnus  
4103
 
4104
        PR fortran/18918
4105
        PR fortran/43931
4106
        *  trans-types.c (gfc_get_array_descriptor_base): Fix index
4107
        calculation for array descriptor types.
4108
 
4109
2010-04-29  Janus Weil  
4110
 
4111
        PR fortran/43896
4112
        * symbol.c (add_proc_component,copy_vtab_proc_comps): Remove
4113
        initializers for PPC members of the vtabs.
4114
 
4115
2010-04-29  Janus Weil  
4116
 
4117
        PR fortran/42274
4118
        * symbol.c (add_proc_component,add_proc_comps): Correctly set the 'ppc'
4119
        attribute for all PPC members of the vtypes.
4120
        (copy_vtab_proc_comps): Copy the correct interface.
4121
        * trans.h (gfc_trans_assign_vtab_procs): Modified prototype.
4122
        * trans-expr.c (gfc_trans_assign_vtab_procs): Pass the derived type as
4123
        a dummy argument and make sure all PPC members of the vtab are
4124
        initialized correctly.
4125
        (gfc_conv_derived_to_class,gfc_trans_class_assign): Additional argument
4126
        in call to gfc_trans_assign_vtab_procs.
4127
        * trans-stmt.c (gfc_trans_allocate): Ditto.
4128
 
4129
2010-04-29  Paul Thomas  
4130
 
4131
        PR fortran/43326
4132
        * resolve.c (resolve_typebound_function): Renamed
4133
        resolve_class_compcall.Do all the detection of class references
4134
        here.
4135
        (resolve_typebound_subroutine): resolve_class_typebound_call
4136
        renamed. Otherwise same as resolve_typebound_function.
4137
        (gfc_resolve_expr): Call resolve_typebound_function.
4138
        (resolve_code): Call resolve_typebound_subroutine.
4139
 
4140
2010-04-29  Janus Weil  
4141
 
4142
        PR fortran/43492
4143
        * resolve.c (resolve_typebound_generic_call): For CLASS methods
4144
        pass back the specific symtree name, rather than the target
4145
        name.
4146
 
4147
2010-04-29  Paul Thomas  
4148
 
4149
        PR fortran/42353
4150
        * resolve.c (resolve_structure_cons): Make the initializer of
4151
        the vtab component 'extends' the same type as the component.
4152
 
4153
2010-04-29  Jerry DeLisle  
4154
 
4155
        PR fortran/42680
4156
        * interface.c (check_interface1): Pass symbol name rather than NULL to
4157
        gfc_compare_interfaces.(gfc_compare_interfaces): Add assert to
4158
        trap MULL. (gfc_compare_derived_types): Revert previous change
4159
        incorporated incorrectly during merge from trunk, r155778.
4160
        * resolve.c (check_generic_tbp_ambiguity): Pass symbol name rather
4161
        than NULL to gfc_compare_interfaces.
4162
        * symbol.c (add_generic_specifics): Likewise.
4163
 
4164
2010-02-29  Janus Weil  
4165
 
4166
        PR fortran/42353
4167
        * interface.c (gfc_compare_derived_types): Add condition for vtype.
4168
        * symbol.c (gfc_find_derived_vtab): Sey access to private.
4169
        (gfc_find_derived_vtab): Likewise.
4170
        * module.c (ab_attribute): Add enumerator AB_VTAB.
4171
        (mio_symbol_attribute): Use new attribute, AB_VTAB.
4172
        (check_for_ambiguous): Likewise.
4173
 
4174
2010-04-29  Paul Thomas  
4175
            Janus Weil  
4176
 
4177
        PR fortran/41829
4178
        * trans-expr.c (select_class_proc): Remove function.
4179
        (conv_function_val): Delete reference to previous.
4180
        (gfc_conv_derived_to_class): Add second argument to the call to
4181
        gfc_find_derived_vtab.
4182
        (gfc_conv_structure): Exclude proc_pointer components when
4183
        accessing $data field of class objects.
4184
        (gfc_trans_assign_vtab_procs): New function.
4185
        (gfc_trans_class_assign): Add second argument to the call to
4186
        gfc_find_derived_vtab.
4187
        * symbol.c (gfc_build_class_symbol): Add delayed_vtab arg and
4188
        implement holding off searching for the vptr derived type.
4189
        (add_proc_component): New function.
4190
        (add_proc_comps): New function.
4191
        (add_procs_to_declared_vtab1): New function.
4192
        (copy_vtab_proc_comps): New function.
4193
        (add_procs_to_declared_vtab): New function.
4194
        (void add_generic_specifics): New function.
4195
        (add_generics_to_declared_vtab): New function.
4196
        (gfc_find_derived_vtab): Add second argument to the call to
4197
        gfc_find_derived_vtab. Add the calls to
4198
        add_procs_to_declared_vtab and add_generics_to_declared_vtab.
4199
        * decl.c (build_sym, build_struct): Use new arg in calls to
4200
        gfc_build_class_symbol.
4201
        * gfortran.h : Add vtype bitfield to symbol_attr. Remove the
4202
        definition of struct gfc_class_esym_list. Modify prototypes
4203
        of gfc_build_class_symbol and gfc_find_derived_vtab.
4204
        * trans-stmt.c (gfc_trans_allocate): Add second argument to the
4205
        call to gfc_find_derived_vtab.
4206
        * module.c : Add the vtype attribute.
4207
        * trans.h : Add prototype for gfc_trans_assign_vtab_procs.
4208
        * resolve.c (resolve_typebound_generic_call): Add second arg
4209
        to pass along the generic name for class methods.
4210
        (resolve_typebound_call): The same.
4211
        (resolve_compcall): Use the second arg to carry the generic
4212
        name from the above. Remove the reference to class_esym.
4213
        (check_members, check_class_members, resolve_class_esym,
4214
        hash_value_expr): Remove functions.
4215
        (resolve_class_compcall, resolve_class_typebound_call): Modify
4216
        to use vtable rather than member by member calls.
4217
        (gfc_resolve_expr): Modify second arg in call to
4218
        resolve_compcall.
4219
        (resolve_select_type): Add second arg in call to
4220
        gfc_find_derived_vtab.
4221
        (resolve_code): Add second arg in call resolve_typebound_call.
4222
        (resolve_fl_derived): Exclude vtypes from check for late
4223
        procedure definitions. Likewise for checking of explicit
4224
        interface and checking of pass arg.
4225
        * iresolve.c (gfc_resolve_extends_type_of): Add second arg in
4226
        calls to gfc_find_derived_vtab.
4227
        * match.c (select_type_set_tmp): Use new arg in call to
4228
        gfc_build_class_symbol.
4229
        * trans-decl.c (gfc_get_symbol_decl): Complete vtable if
4230
        necessary.
4231
        * parse.c (endType): Finish incomplete classes.
4232
 
4233
2010-04-28  Tobias Burnus  
4234
 
4235
        PR fortran/18918
4236
        PR fortran/43919
4237
        * simplify.c (simplify_cobound): Handle scalar coarrays.
4238
 
4239
2010-04-27  Tobias Burnus  
4240
 
4241
        * gfc-internals.texi: Update copyright year.
4242
        * gfortran.texi: Ditto.
4243
        * invoke.texi: Ditto.
4244
 
4245
2010-04-27  Tobias Burnus  
4246
 
4247
        PR fortran/18918
4248
        * resolve.c (resolve_allocate_expr): Allow array coarrays.
4249
        * trans-types.h (gfc_get_array_type_bounds): Update prototype.
4250
        * trans-types.c (gfc_get_array_type_bounds,
4251
        gfc_get_array_descriptor_base): Add corank argument.
4252
        * trans-array.c (gfc_array_init_size): Handle corank.
4253
        (gfc_trans_create_temp_array, gfc_array_allocate,
4254
        gfc_conv_expr_descriptor): Add corank argument to call.
4255
        * trans-stmt.c (gfc_trans_pointer_assign_need_temp): Ditto.
4256
 
4257
2010-04-24  Steven G. Kargl  
4258
 
4259
        PR fortran/30073
4260
        PR fortran/43793
4261
        * trans-array.c (gfc_trans_array_bound_check): Use TREE_CODE instead
4262
        of mucking with a tree directly.
4263
 
4264
2010-04-24  Jerry DeLisle  
4265
 
4266
        PR fortran/43832
4267
        * io.c (gfc_match_open): Remove branch to syntax error. Add call to
4268
        gfc_error with new error message.
4269
 
4270
2010-04-24  Paul Thomas  
4271
 
4272
        PR fortran/43841
4273
        PR fortran/43843
4274
        * trans-expr.c (gfc_conv_expr): Supply an address expression for
4275
        GFC_SS_REFERENCE.
4276
        (gfc_conv_expr_reference): Call gfc_conv_expr and return for
4277
        GFC_SS_REFERENCE.
4278
        * trans-array.c (gfc_add_loop_ss_code): Store the value rather
4279
        than the address of a GFC_SS_REFERENCE.
4280
        * trans.h : Change comment on GFC_SS_REFERENCE.
4281
 
4282
2010-04-22  Richard Guenther  
4283
 
4284
        PR fortran/43829
4285
        * resolve.c (gfc_resolve_index): Wrap around ...
4286
        (gfc_resolve_index_1): ... this.  Add parameter to allow
4287
        any integer kind index type.
4288
        (resolve_array_ref): Allow any integer kind for the start
4289
        index of an array ref.
4290
 
4291
2010-04-21  Jakub Jelinek  
4292
 
4293
        PR fortran/43836
4294
        * f95-lang.c (gfc_define_builtin): Set TREE_NOTHROW on
4295
        the decl.
4296
 
4297
2010-04-20  Harald Anlauf  
4298
 
4299
        * intrinsic.c (sort_actual): Remove 'is' in error message.
4300
 
4301
2010-04-20  Paul Thomas  
4302
 
4303
        PR fortran/43227
4304
        * resolve.c (resolve_fl_derived): If a component character
4305
        length has not been resolved, do so now.
4306
        (resolve_symbol): The same as above for a symbol character
4307
        length.
4308
        * trans-decl.c (gfc_create_module_variable): A 'length' decl is
4309
        not needed for a character valued, procedure pointer.
4310
 
4311
        PR fortran/43266
4312
        * resolve.c (ensure_not_abstract_walker): If 'overriding' is
4313
        not found, return FAILURE rather than ICEing.
4314
 
4315
2010-04-19  Jakub Jelinek  
4316
 
4317
        PR fortran/43339
4318
        * openmp.c (gfc_resolve_do_iterator): Only make iteration vars for
4319
        sequential loops private in the innermost containing task region.
4320
 
4321
2010-04-18  Eric Botcazou  
4322
 
4323
        * f95-lang.c (gfc_init_decl_processing): Remove second argument in call
4324
        to build_common_tree_nodes.
4325
 
4326
2010-04-17  Steven G. Kargl  
4327
 
4328
        PR fortran/31538
4329
        * fortran/trans-array.c (gfc_conv_ss_startstride): Remove the use of
4330
        gfc_msg_bounds by using 'Array bound mismatch' directly.
4331
        (gfc_trans_dummy_array_bias):  Remove the use of gfc_msg_bounds.  Reword
4332
        error message to include the mismatch in the extent of array bound.
4333
        * fortran/trans.c: Remove gfc_msg_bounds.  It is only used in one place.
4334
        * fortran/trans.h: Remove extern definition of gfc_msg_bounds.
4335
 
4336
2010-04-17  Jerry DeLisle  
4337
 
4338
        * gfortran.texi: Update information on temporary file locations.
4339
 
4340
2010-04-16  Jakub Jelinek  
4341
 
4342
        * trans-decl.c (gfc_build_qualified_array): Ensure
4343
        ubound.N and lbound.N artificial variable names don't appear
4344
        in debug info.
4345
 
4346
2010-04-15  Steven G. Kargl  
4347
 
4348
        PR fortran/30073
4349
        * trans-array.c (gfc_trans_array_bound_check): Eliminate a redundant
4350
        block of code.  Set name to the variable associated with the descriptor.
4351
 
4352
2010-04-15  Jakub Jelinek  
4353
 
4354
        * trans-decl.c (gfc_build_qualified_array): Clear DECL_IGNORED_P
4355
        on VAR_DECL LBOUND and/or UBOUND, even for -O1.
4356
 
4357
2010-04-14  Steven G. Kargl  
4358
 
4359
        * intrinsic.texi: Add the missing specific name of intrinsic
4360
        procedure where the specific name is identical to the generic name.
4361
        Fix inconsistent or mismatch in the argument names in intrinsic
4362
        procedure descriptions.  Add the SCALAR allocatable description to
4363
        ALLOCATED.
4364
 
4365
2010-04-14  Tobias Burnus  
4366
 
4367
        PR fortran/18918
4368
        * array.c (gfc_find_array_ref): Handle codimensions.
4369
        (gfc_match_array_spec,gfc_match_array_ref): Use gfc_fatal_error.
4370
        * check.c (is_coarray, dim_corank_check, gfc_check_lcobound,
4371
        gfc_check_image_index, gfc_check_this_image, gfc_check_ucobound):
4372
        New functions.
4373
        * gfortran.h (gfc_isym_id): Add GFC_ISYM_IMAGE_INDEX,
4374
        GFC_ISYM_LCOBOUND, GFC_ISYM_THIS_IMAGE,
4375
        GFC_ISYM_UCOBOUND.
4376
        * intrinsic.h (add_functions): Add this_image, image_index,
4377
        lcobound and ucobound intrinsics.
4378
        * intrinsic.c (gfc_check_lcobound,gfc_check_ucobound,
4379
        gfc_check_image_index, gfc_check_this_image,
4380
        gfc_simplify_image_index, gfc_simplify_lcobound,
4381
        gfc_simplify_this_image, gfc_simplify_ucobound):
4382
        New function prototypes.
4383
        * intrinsic.texi (IMAGE_INDEX, LCOBOUND, THIS_IMAGE
4384
        IMAGE_INDEX): Document new intrinsic functions.
4385
        * match.c (gfc_match_critical, sync_statement): Make -fcoarray=none
4386
        error fatal.
4387
        * simplify.c (simplify_bound_dim): Handle coarrays.
4388
        (simplify_bound): Update simplify_bound_dim call.
4389
        (gfc_simplify_num_images): Add -fcoarray=none check.
4390
        (simplify_cobound, gfc_simplify_lcobound, gfc_simplify_ucobound,
4391
        gfc_simplify_ucobound, gfc_simplify_ucobound): New functions.
4392
 
4393
2010-04-14  Jerry DeLisle  
4394
 
4395
        PR fortran/43747
4396
        * constructor.c: Fix typo in comment.
4397
        * expr.c (find_array_section): Add check for max array limit.
4398
 
4399
2010-04-13  Iain Sandoe  
4400
 
4401
        PR bootstrap/31400
4402
        * gfortranspec.c (lookup_option): Check for -static and return
4403
        OPTION_static.
4404
        (lang_specific_driver): Break when OPTION_static is discovered.
4405
 
4406
2010-04-12  Jerry DeLisle  
4407
 
4408
        * array.c (extract_element): Restore function from trunk.
4409
        (gfc_get_array_element): Restore function from trunk.
4410
        (gfc_expand_constructor): Restore check against
4411
        flag_max_array_constructor.
4412
        * constructor.c (node_copy_and_append): Delete unused.
4413
        * gfortran.h: Delete comment and extra include.
4414
        * constructor.h: Bump copyright and clean up TODO comments.
4415
        * resolve.c: Whitespace.
4416
 
4417
2010-04-12  Daniel Franke  
4418
 
4419
        * simplify.c (compute_dot_product): Replaced usage of ADVANCE macro
4420
        with direct access access to elements. Adjusted prototype, fixed all
4421
        callers.
4422
        (gfc_simplify_dot_product): Removed duplicate check for zero-sized
4423
        array.
4424
        (gfc_simplify_matmul): Removed usage of ADVANCE macro.
4425
        (gfc_simplify_spread): Removed workaround, directly insert elements
4426
        at a given array position.
4427
        (gfc_simplify_transpose): Likewise.
4428
        (gfc_simplify_pack): Replaced usage of ADVANCE macro with corresponding
4429
        function calls.
4430
        (gfc_simplify_unpack): Likewise.
4431
 
4432
2010-04-12  Daniel Franke  
4433
 
4434
        * simplify.c (only_convert_cmplx_boz): Renamed to ...
4435
        (convert_boz): ... this and moved to start of file.
4436
        (gfc_simplify_abs): Whitespace fix.
4437
        (gfc_simplify_acos): Whitespace fix.
4438
        (gfc_simplify_acosh): Whitespace fix.
4439
        (gfc_simplify_aint): Whitespace fix.
4440
        (gfc_simplify_dint): Whitespace fix.
4441
        (gfc_simplify_anint): Whitespace fix.
4442
        (gfc_simplify_and): Replaced if-gate by more common switch-over-type.
4443
        (gfc_simplify_dnint): Whitespace fix.
4444
        (gfc_simplify_asin): Whitespace fix.
4445
        (gfc_simplify_asinh): Moved creation of result-expr out of switch.
4446
        (gfc_simplify_atan): Likewise.
4447
        (gfc_simplify_atanh): Whitespace fix.
4448
        (gfc_simplify_atan2): Whitespace fix.
4449
        (gfc_simplify_bessel_j0): Removed ATTRIBUTE_UNUSED.
4450
        (gfc_simplify_bessel_j1): Likewise.
4451
        (gfc_simplify_bessel_jn): Likewise.
4452
        (gfc_simplify_bessel_y0): Likewise.
4453
        (gfc_simplify_bessel_y1): Likewise.
4454
        (gfc_simplify_bessel_yn): Likewise.
4455
        (gfc_simplify_ceiling): Reorderd statements.
4456
        (simplify_cmplx): Use convert_boz(), check for constant arguments.
4457
        Whitespace fix.
4458
        (gfc_simplify_cmplx): Use correct default kind. Removed check for
4459
        constant arguments.
4460
        (gfc_simplify_complex): Replaced if-gate. Removed check for
4461
        constant arguments.
4462
        (gfc_simplify_conjg): Whitespace fix.
4463
        (gfc_simplify_cos): Whitespace fix.
4464
        (gfc_simplify_cosh): Replaced if-gate by more common switch-over-type.
4465
        (gfc_simplify_dcmplx): Removed check for constant arguments.
4466
        (gfc_simplify_dble): Use convert_boz() and gfc_convert_constant().
4467
        (gfc_simplify_digits): Whitespace fix.
4468
        (gfc_simplify_dim): Whitespace fix.
4469
        (gfc_simplify_dprod): Reordered statements.
4470
        (gfc_simplify_erf): Whitespace fix.
4471
        (gfc_simplify_erfc): Whitespace fix.
4472
        (gfc_simplify_epsilon): Whitespace fix.
4473
        (gfc_simplify_exp): Whitespace fix.
4474
        (gfc_simplify_exponent): Use convert_boz().
4475
        (gfc_simplify_floor): Reorderd statements.
4476
        (gfc_simplify_gamma): Whitespace fix.
4477
        (gfc_simplify_huge): Whitespace fix.
4478
        (gfc_simplify_iand): Whitespace fix.
4479
        (gfc_simplify_ieor): Whitespace fix.
4480
        (simplify_intconv): Use gfc_convert_constant().
4481
        (gfc_simplify_int): Use simplify_intconv().
4482
        (gfc_simplify_int2): Reorderd statements.
4483
        (gfc_simplify_idint): Reorderd statements.
4484
        (gfc_simplify_ior): Whitespace fix.
4485
        (gfc_simplify_ishftc): Removed duplicate type check.
4486
        (gfc_simplify_len): Use range_check() instead of manual range check.
4487
        (gfc_simplify_lgamma): Removed ATTRIBUTE_UNUSED. Whitespace fix.
4488
        (gfc_simplify_log): Whitespace fix.
4489
        (gfc_simplify_log10): Whitespace fix.
4490
        (gfc_simplify_minval): Whitespace fix.
4491
        (gfc_simplify_maxval): Whitespace fix.
4492
        (gfc_simplify_mod): Whitespace fix.
4493
        (gfc_simplify_modulo): Whitespace fix.
4494
        (simplify_nint): Reorderd statements.
4495
        (gfc_simplify_not): Whitespace fix.
4496
        (gfc_simplify_or): Replaced if-gate by more common switch-over-type.
4497
        (gfc_simplify_radix): Removed unused result-variable. Whitespace fix.
4498
        (gfc_simplify_range): Removed unused result-variable. Whitespace fix.
4499
        (gfc_simplify_real): Use convert_boz() and gfc_convert_constant().
4500
        (gfc_simplify_realpart): Whitespace fix.
4501
        (gfc_simplify_selected_char_kind): Removed unused result-variable.
4502
        (gfc_simplify_selected_int_kind): Removed unused result-variable.
4503
        (gfc_simplify_selected_real_kind): Removed unused result-variable.
4504
        (gfc_simplify_sign): Whitespace fix.
4505
        (gfc_simplify_sin): Whitespace fix.
4506
        (gfc_simplify_sinh): Replaced if-gate by more common switch-over-type.
4507
        (gfc_simplify_sqrt): Avoided goto by inlining check. Whitespace fix.
4508
        (gfc_simplify_tan): Replaced if-gate by more common switch-over-type.
4509
        (gfc_simplify_tanh): Replaced if-gate by more common switch-over-type.
4510
        (gfc_simplify_xor): Replaced if-gate by more common switch-over-type.
4511
 
4512
2010-04-12  Daniel Franke  
4513
 
4514
        * gfortran.h (gfc_start_constructor): Removed.
4515
        (gfc_get_array_element): Removed.
4516
        * array.c (gfc_start_constructor): Removed, use gfc_get_array_expr
4517
        instead. Fixed all callers.
4518
        (extract_element): Removed.
4519
        (gfc_expand_constructor): Temporarily removed check for
4520
        max-array-constructor. Will be re-introduced later if still required.
4521
        (gfc_get_array_element): Removed, use gfc_constructor_lookup_expr
4522
        instead. Fixed all callers.
4523
        * expr.c (find_array_section): Replaced manual lookup of elements
4524
        by gfc_constructor_lookup.
4525
 
4526
2010-04-12  Daniel Franke  
4527
 
4528
        * gfortran.h (gfc_get_null_expr): New prototype.
4529
        (gfc_get_operator_expr): New prototype.
4530
        (gfc_get_character_expr): New prototype.
4531
        (gfc_get_iokind_expr): New prototype.
4532
        * expr.c (gfc_get_null_expr): New.
4533
        (gfc_get_character_expr): New.
4534
        (gfc_get_iokind_expr): New.
4535
        (gfc_get_operator_expr): Moved here from matchexp.c (build_node).
4536
        * matchexp.c (build_node): Renamed and moved to
4537
        expr.c (gfc_get_operator_expr). Reordered arguments to match
4538
        other functions. Fixed all callers.
4539
        (gfc_get_parentheses): Use specific function to build expr.
4540
        * array.c (gfc_match_array_constructor): Likewise.
4541
        * arith.c (eval_intrinsic): Likewise.
4542
        (gfc_hollerith2int): Likewise.
4543
        (gfc_hollerith2real): Likewise.
4544
        (gfc_hollerith2complex): Likewise.
4545
        (gfc_hollerith2logical): Likewise.
4546
        * data.c (create_character_intializer): Likewise.
4547
        * decl.c (gfc_match_null): Likewise.
4548
        (enum_initializer): Likewise.
4549
        * io.c (gfc_match_format): Likewise.
4550
        (match_io): Likewise.
4551
        * match.c (gfc_match_nullify): Likewise.
4552
        * primary.c (match_string_constant): Likewise.
4553
        (match_logical_constant): Likewise.
4554
        (build_actual_constructor): Likewise.
4555
        * resolve.c (build_default_init_expr): Likewise.
4556
        * symbol.c (generate_isocbinding_symbol): Likewise.
4557
        (gfc_build_class_symbol): Likewise.
4558
        (gfc_find_derived_vtab): Likewise.
4559
        * simplify.c (simplify_achar_char): Likewise.
4560
        (gfc_simplify_adjustl): Likewise.
4561
        (gfc_simplify_adjustr): Likewise.
4562
        (gfc_simplify_and): Likewise.
4563
        (gfc_simplify_bit_size): Likewise.
4564
        (gfc_simplify_is_iostat_end): Likewise.
4565
        (gfc_simplify_is_iostat_eor): Likewise.
4566
        (gfc_simplify_isnan): Likewise.
4567
        (simplify_bound): Likewise.
4568
        (gfc_simplify_leadz): Likewise.
4569
        (gfc_simplify_len_trim): Likewise.
4570
        (gfc_simplify_logical): Likewise.
4571
        (gfc_simplify_maxexponent): Likewise.
4572
        (gfc_simplify_minexponent): Likewise.
4573
        (gfc_simplify_new_line): Likewise.
4574
        (gfc_simplify_null): Likewise.
4575
        (gfc_simplify_or): Likewise.
4576
        (gfc_simplify_precision): Likewise.
4577
        (gfc_simplify_repeat): Likewise.
4578
        (gfc_simplify_scan): Likewise.
4579
        (gfc_simplify_size): Likewise.
4580
        (gfc_simplify_trailz): Likewise.
4581
        (gfc_simplify_trim): Likewise.
4582
        (gfc_simplify_verify): Likewise.
4583
        (gfc_simplify_xor): Likewise.
4584
        * trans-io.c (build_dt): Likewise.
4585
        (gfc_new_nml_name_expr): Removed.
4586
 
4587
2010-04-12  Daniel Franke  
4588
 
4589
        * arith.h (gfc_constant_result): Removed prototype.
4590
        * constructor.h (gfc_build_array_expr): Removed prototype.
4591
        (gfc_build_structure_constructor_expr): Removed prototype.
4592
        * gfortran.h (gfc_int_expr): Removed prototype.
4593
        (gfc_logical_expr): Removed prototype.
4594
        (gfc_get_array_expr): New prototype.
4595
        (gfc_get_structure_constructor_expr): New prototype.
4596
        (gfc_get_constant_expr): New prototype.
4597
        (gfc_get_int_expr): New prototype.
4598
        (gfc_get_logical_expr): New prototype.
4599
        * arith.c (gfc_constant_result): Moved and renamed to
4600
        expr.c (gfc_get_constant_expr). Fixed all callers.
4601
        * constructor.c (gfc_build_array_expr): Moved and renamed to
4602
        expr.c (gfc_get_array_expr). Split gfc_typespec argument to type
4603
        and kind. Fixed all callers.
4604
        (gfc_build_structure_constructor_expr): Moved and renamed to
4605
        expr.c (gfc_get_structure_constructor_expr). Split gfc_typespec argument
4606
        to type and kind. Fixed all callers.
4607
        * expr.c (gfc_logical_expr): Renamed to ...
4608
        (gfc_get_logical_expr): ... this. Added kind argument. Fixed all callers.
4609
        (gfc_int_expr): Renamed to ...
4610
        (gfc_get_int_expr): ... this. Added kind and where arguments. Fixed all
4611
        callers.
4612
        (gfc_get_constant_expr): New.
4613
        (gfc_get_array_expr): New.
4614
        (gfc_get_structure_constructor_expr): New.
4615
        * simplify.c (int_expr_with_kind): Removed, callers use gfc_get_int_expr
4616
        instead.
4617
 
4618
2010-04-12  Daniel Franke  
4619
 
4620
        * constructor.h: New.
4621
        * constructor.c: New.
4622
        * Make-lang.in: Add new files to F95_PARSER_OBJS.
4623
        * arith.c (reducy_unary): Use constructor API.
4624
        (reduce_binary_ac): Likewise.
4625
        (reduce_binary_ca): Likewise.
4626
        (reduce_binary_aa): Likewise.
4627
        * check.c (gfc_check_pack): Likewise.
4628
        (gfc_check_reshape): Likewise.
4629
        (gfc_check_unpack): Likewise.
4630
        * decl.c (add_init_expr_to_sym): Likewise.
4631
        (build_struct): Likewise.
4632
        * dependency.c (gfc_check_dependency): Likewise.
4633
        (contains_forall_index_p): Likewise.
4634
        * dump-parse-tree.c (show_constructor): Likewise.
4635
        * expr.c (free_expr0): Likewise.
4636
        (gfc_copy_expr): Likewise.
4637
        (gfc_is_constant_expr): Likewise.
4638
        (simplify_constructor): Likewise.
4639
        (find_array_element): Likewise.
4640
        (find_component_ref): Likewise.
4641
        (find_array_section): Likewise.
4642
        (find_substring_ref): Likewise.
4643
        (simplify_const_ref): Likewise.
4644
        (scalarize_intrinsic_call): Likewise.
4645
        (check_alloc_comp_init): Likewise.
4646
        (gfc_default_initializer): Likewise.
4647
        (gfc_traverse_expr): Likewise.
4648
        * iresolve.c (check_charlen_present): Likewise.
4649
        (gfc_resolve_reshape): Likewise.
4650
        (gfc_resolve_transfer): Likewise.
4651
        * module.c (mio_constructor): Likewise.
4652
        * primary.c (build_actual_constructor): Likewise.
4653
        (gfc_match_structure_constructor): Likewise.
4654
        * resolve.c (resolve_structure_cons): Likewise.
4655
        * simplify.c (is_constant_array_expr): Likewise.
4656
        (init_result_expr): Likewise.
4657
        (transformational_result): Likewise.
4658
        (simplify_transformation_to_scalar): Likewise.
4659
        (simplify_transformation_to_array): Likewise.
4660
        (gfc_simplify_dot_product): Likewise.
4661
        (simplify_bound): Likewise.
4662
        (simplify_matmul): Likewise.
4663
        (simplify_minval_maxval): Likewise.
4664
        (gfc_simplify_pack): Likewise.
4665
        (gfc_simplify_reshape): Likewise.
4666
        (gfc_simplify_shape): Likewise.
4667
        (gfc_simplify_spread): Likewise.
4668
        (gfc_simplify_transpose): Likewise.
4669
        (gfc_simplify_unpack): Likewise.q
4670
        (gfc_convert_constant): Likewise.
4671
        (gfc_convert_char_constant): Likewise.
4672
        * target-memory.c (size_array): Likewise.
4673
        (encode_array): Likewise.
4674
        (encode_derived): Likewise.
4675
        (interpret_array): Likewise.
4676
        (gfc_interpret_derived): Likewise.
4677
        (expr_to_char): Likewise.
4678
        (gfc_merge_initializers): Likewise.
4679
        * trans-array.c (gfc_get_array_constructor_size): Likewise.
4680
        (gfc_trans_array_constructor_value): Likewise.
4681
        (get_array_ctor_strlen): Likewise.
4682
        (gfc_constant_array_constructor_p): Likewise.
4683
        (gfc_build_constant_array_constructor): Likewise.
4684
        (gfc_trans_array_constructor): Likewise.
4685
        (gfc_conv_array_initializer): Likewise.
4686
        * trans-decl.c (check_constant_initializer): Likewise.
4687
        * trans-expr.c (flatten_array_ctors_without_strlen): Likewise.
4688
        (gfc_apply_interface_mapping_to_cons): Likewise.
4689
        (gfc_trans_structure_assign): Likewise.
4690
        (gfc_conv_structure): Likewise.
4691
        * array.c (check_duplicate_iterator): Likewise.
4692
        (match_array_list): Likewise.
4693
        (match_array_cons_element): Likewise.
4694
        (gfc_match_array_constructor): Likewise.
4695
        (check_constructor_type): Likewise.
4696
        (check_constructor): Likewise.
4697
        (expand): Likewise.
4698
        (expand_constructor): Likewise.
4699
        (extract_element): Likewise.
4700
        (gfc_expanded_ac): Likewise.
4701
        (resolve_array_list): Likewise.
4702
        (gfc_resolve_character_array_constructor): Likewise.
4703
        (copy_iterator): Renamed to ...
4704
        (gfc_copy_iterator): ... this.
4705
        (gfc_append_constructor): Removed.
4706
        (gfc_insert_constructor): Removed unused function.
4707
        (gfc_get_constructor): Removed.
4708
        (gfc_free_constructor): Removed.
4709
        (qgfc_copy_constructor): Removed.
4710
        * gfortran.h (struct gfc_expr): Removed member 'con_by_offset'.
4711
        Removed all references. Replaced constructor list by splay-tree.
4712
        (struct gfc_constructor): Removed member 'next', moved 'offset' from
4713
        the inner struct, added member 'base'.
4714
        (gfc_append_constructor): Removed prototype.
4715
        (gfc_insert_constructor): Removed prototype.
4716
        (gfc_get_constructor): Removed prototype.
4717
        (gfc_free_constructor): Removed prototype.
4718
        (qgfc_copy_constructor): Removed prototype.
4719
        (gfc_copy_iterator): New prototype.
4720
        * trans-array.h (gfc_constant_array_constructor_p): Adjusted prototype.
4721
 
4722
2010-04-10  Tobias Burnus  
4723
 
4724
        PR fortran/43591
4725
        * expr.c (gfc_is_constant_expr, gfc_traverse_expr): Handle
4726
        proc-pointers and type-bound procedures.
4727
        (gfc_specification_expr): Check proc-pointers for pureness.
4728
 
4729
2010-04-09  Iain Sandoe  
4730
 
4731
        PR bootstrap/43684
4732
        * gfortranspec.c (lang_specific_driver): Do not expose vars
4733
        only used by HAVE_LD_STATIC_DYNAMIC targets unless compiling
4734
        for such.
4735
 
4736
2010-04-09  Tobias Burnus  
4737
 
4738
        PR fortran/18918
4739
        * decl.c (variable_decl, match_attr_spec): Fix setting the array
4740
        spec.
4741
        * array.c (match_subscript,gfc_match_array_ref): Add coarray support.
4742
        * data.c (gfc_assign_data_value): Ditto.
4743
        * expr.c (gfc_check_pointer_assign): Add check for coarray constraint.
4744
        (gfc_traverse_expr): Traverse also through codimension expressions.
4745
        (gfc_is_coindexed, gfc_has_ultimate_allocatable,
4746
        gfc_has_ultimate_pointer): New functions.
4747
        * gfortran.h (gfc_array_ref_dimen_type): Add DIMEN_STAR for coarrays.
4748
        (gfc_array_ref): Add codimen.
4749
        (gfc_array_ref): Add in_allocate.
4750
        (gfc_is_coindexed, gfc_has_ultimate_allocatable,
4751
        gfc_has_ultimate_pointer): Add prototypes.
4752
        * interface.c (compare_parameter, compare_actual_formal,
4753
        check_intents): Add coarray constraints.
4754
        * match.c (gfc_match_iterator): Add coarray constraint.
4755
        * match.h (gfc_match_array_ref): Update interface.
4756
        * primary.c (gfc_match_varspec): Handle codimensions.
4757
        * resolve.c (coarray_alloc, inquiry_argument): New static variables.
4758
        (check_class_members): Return gfc_try instead for error recovery.
4759
        (resolve_typebound_function,resolve_typebound_subroutine,
4760
        check_members): Handle return value of check_class_members.
4761
        (resolve_structure_cons, resolve_actual_arglist, resolve_function,
4762
        check_dimension, compare_spec_to_ref, resolve_array_ref,
4763
        resolve_ref, resolve_variable, gfc_resolve_expr, conformable_arrays,
4764
        resolve_allocate_expr, resolve_ordinary_assign): Add coarray
4765
        support.
4766
        * trans-array.c (gfc_conv_array_ref, gfc_walk_variable_expr):
4767
        Skip over coarray refs.
4768
        (gfc_array_allocate) Add support for references containing coindexes.
4769
        * trans-expr.c (gfc_add_interface_mapping): Copy coarray attribute.
4770
        (gfc_map_intrinsic_function): Ignore codimensions.
4771
 
4772
2010-04-08  Bud Davis  
4773
 
4774
        PR fortran/28039
4775
        * io.c (check_format_string):  Added check for additional non
4776
        blank characters after the format string was successfully
4777
        parsed.
4778
        * io.c (check_format): Changed the error messages for positive
4779
        int required and period required to drop through the error logic
4780
        and report with gfc_error instead of gfc_error_now.  Corrected
4781
        format postion for hollerith strings.
4782
 
4783
2010-04-08  Tobias Burnus  
4784
 
4785
        * module.c (use_iso_fortran_env_module): Fix standard check.
4786
 
4787
2010-04-07  Jakub Jelinek  
4788
 
4789
        * parse.c (parse_derived, parse_enum): Avoid set but not used
4790
        warning.
4791
 
4792
2010-04-07  Janne Blomqvist  
4793
 
4794
        PR fortran/40539
4795
        * gfortran.texi: Add section about representation of
4796
        LOGICAL variables.
4797
 
4798
2010-04-07  Simon Baldwin  
4799
 
4800
        * cpp.c (cb_cpp_error): Add warning reason argument, set a value
4801
        for diagnostic_override_option_index if CPP_W_WARNING_DIRECTIVE.
4802
 
4803
2010-04-07  Richard Guenther  
4804
 
4805
        * options.c (gfc_init_options): Do not set.
4806
 
4807
2010-04-06  Tobias Burnus  
4808
 
4809
        PR fortran/18918
4810
        * array.c (gfc_match_array_spec): Add error for -fcoarray=none.
4811
        * match.c (gfc_match_critical, sync_statement): Ditto.
4812
        * gfortran.h (gfc_fcoarray): New enum.
4813
        (gfc_option_t): Use it.
4814
        * lang.opt (fcoarray): Add new flag.
4815
        * invoke.texi (fcoarray): Document it.
4816
        * options.c (gfc_init_options,gfc_handle_option): Handle -fcoarray=.
4817
        (gfc_handle_coarray_option): New function.
4818
 
4819
2010-04-06  Tobias Burnus  
4820
 
4821
        PR fortran/18918
4822
        * gfortran.h (gfc_array_spec): Add cotype.
4823
        * array.c (gfc_match_array_spec,gfc_set_array_spec): Use it
4824
        and defer error diagnostic.
4825
        * resolve.c (resolve_fl_derived): Add missing check.
4826
        (resolve_symbol): Add cotype/type check.
4827
        * parse.c (parse_derived): Fix setting of coarray_comp.
4828
 
4829
2010-04-06  Tobias Burnus  
4830
 
4831
        PR fortran/18918
4832
        * array.c (gfc_free_array_spec,gfc_resolve_array_spec,
4833
        match_array_element_spec,gfc_copy_array_spec,
4834
        gfc_compare_array_spec): Include corank.
4835
        (match_array_element_spec,gfc_set_array_spec): Support codimension.
4836
        * decl.c (build_sym,build_struct,variable_decl,
4837
        match_attr_spec,attr_decl1,cray_pointer_decl,
4838
        gfc_match_volatile): Add codimension.
4839
        (gfc_match_codimension): New function.
4840
        * dump-parse-tree.c (show_array_spec,show_attr): Support codimension.
4841
        * gfortran.h (symbol_attribute,gfc_array_spec): Ditto.
4842
        (gfc_add_codimension): New function prototype.
4843
        * match.h (gfc_match_codimension): New function prototype.
4844
        (gfc_match_array_spec): Update prototype
4845
        * match.c (gfc_match_common): Update gfc_match_array_spec call.
4846
        * module.c (MOD_VERSION): Bump.
4847
        (mio_symbol_attribute): Support coarray attributes.
4848
        (mio_array_spec): Add corank support.
4849
        * parse.c (decode_specification_statement,decode_statement,
4850
        parse_derived): Add coarray support.
4851
        * resolve.c (resolve_formal_arglist, was_declared,
4852
        is_non_constant_shape_array, resolve_fl_variable,
4853
        resolve_fl_derived, resolve_symbol): Add coarray support.
4854
        * symbol.c (check_conflict, gfc_add_volatile, gfc_copy_attr,
4855
        gfc_build_class_symbol): Add coarray support.
4856
        (gfc_add_codimension): New function.
4857
 
4858
2010-04-06  Tobias Burnus  
4859
 
4860
        PR fortran/18918
4861
        * iso-fortran-env.def: Add the integer parameters atomic_int_kind,
4862
        atomic_logical_kind, iostat_inquire_internal_unit, stat_locked,
4863
        stat_locked_other_image, stat_stopped_image and stat_unlocked of
4864
        Fortran 2008.
4865
        * intrinsic.texi (iso_fortran_env): Ditto.
4866
        * libgfortran.h (libgfortran_stat_codes): New enum.
4867
        * module.c (use_iso_fortran_env_module): Honour -std= when loading
4868
        constants from the intrinsic module.
4869
 
4870
2010-04-06  Tobias Burnus  
4871
 
4872
        PR fortran/39997
4873
        * intrinsic.c (add_functions): Add num_images.
4874
        * decl.c (gfc_match_end): Handle END CRITICAL.
4875
        * intrinsic.h (gfc_simplify_num_images): Add prototype.
4876
        * dump-parse-tree.c (show_code_node): Dump CRITICAL, ERROR STOP,
4877
        and SYNC.
4878
        * gfortran.h (gfc_statement): Add enum items for those.
4879
        (gfc_exec_op) Ditto.
4880
        (gfc_isym_id): Add num_images.
4881
        * trans-stmt.c (gfc_trans_stop): Handle ERROR STOP.
4882
        (gfc_trans_sync,gfc_trans_critical): New functions.
4883
        * trans-stmt.h (gfc_trans_stop,gfc_trans_sync,
4884
        gfc_trans_critical): Add/update prototypes.
4885
        * trans.c (gfc_trans_code): Handle CRITICAL, ERROR STOP,
4886
        and SYNC statements.
4887
        * trans.h (gfor_fndecl_error_stop_string) Add variable.
4888
        * resolve.c (resolve_sync): Add function.
4889
        (gfc_resolve_blocks): Handle CRITICAL.
4890
        (resolve_code): Handle CRITICAL, ERROR STOP,
4891
        (resolve_branch): Add CRITICAL constraint check.
4892
        and SYNC statements.
4893
        * st.c (gfc_free_statement): Add new statements.
4894
        * trans-decl.c (gfor_fndecl_error_stop_string): Global variable.
4895
        (gfc_build_builtin_function_decls): Initialize it.
4896
        * match.c (gfc_match_if): Handle ERROR STOP and SYNC.
4897
        (gfc_match_critical, gfc_match_error_stop, sync_statement,
4898
        gfc_match_sync_all, gfc_match_sync_images, gfc_match_sync_memory):
4899
        New functions.
4900
        (match_exit_cycle): Handle CRITICAL constraint.
4901
        (gfc_match_stopcode): Handle ERROR STOP.
4902
        * match.h (gfc_match_critical, gfc_match_error_stop,
4903
        gfc_match_sync_all, gfc_match_sync_images,
4904
        gfc_match_sync_memory): Add prototype.
4905
        * parse.c (decode_statement, gfc_ascii_statement,
4906
        parse_executable): Handle new statements.
4907
        (parse_critical_block): New function.
4908
        * parse.h (gfc_compile_state): Add COMP_CRITICAL.
4909
        * intrinsic.texi (num_images): Document new function.
4910
        * simplify.c (gfc_simplify_num_images): Add function.
4911
 
4912
2010-04-06  Tobias Burnus  
4913
 
4914
        PR fortran/43178
4915
        * trans-array.c (gfc_conv_expr_descriptor): Update
4916
        gfc_trans_scalar_assign call.
4917
        (has_default_initializer): New function.
4918
        (gfc_trans_deferred_array): Nullify less often.
4919
        * trans-expr.c (gfc_conv_subref_array_arg,
4920
        gfc_trans_subcomponent_assign): Update call to
4921
        gfc_trans_scalar_assign.
4922
        (gfc_trans_scalar_assign): Add parameter and pass it on.
4923
        (gfc_trans_assignment_1): Optionally, do not dealloc before
4924
        assignment.
4925
        * trans-openmp.c (gfc_trans_omp_array_reduction): Update
4926
        call to gfc_trans_scalar_assign.
4927
        * trans-decl.c (gfc_get_symbol_decl): Do not always apply
4928
        initializer to static variables.
4929
        (gfc_init_default_dt): Add dealloc parameter and pass it on.
4930
        * trans-stmt.c (forall_make_variable_temp,
4931
        generate_loop_for_temp_to_lhs, generate_loop_for_rhs_to_temp,
4932
        gfc_trans_forall_1, gfc_trans_where_assign, gfc_trans_where_3
4933
        gfc_trans_allocate): Update gfc_trans_assignment call.
4934
        * trans.h (gfc_trans_scalar_assign, gfc_init_default_dt,
4935
        gfc_init_default_dt, gfc_trans_assignment): Add bool dealloc
4936
        parameter to prototype.
4937
 
4938
2010-03-31  Paul Thomas  
4939
 
4940
        * ioparm.def : Update copyright.
4941
        * lang.opt : ditto
4942
        * trans-array.c : ditto
4943
        * trans-array.h : ditto
4944
        * expr.c: ditto
4945
        * trans-types.c: ditto
4946
        * dependency.c : ditto
4947
        * gfortran.h : ditto
4948
        * options.c : ditto
4949
        * trans-io.c : ditto
4950
        * trans-intrinsic.c : ditto
4951
        * libgfortran.h : ditto
4952
        * invoke.texi : ditto
4953
        * intrinsic.texi : ditto
4954
        * trans.c : ditto
4955
        * trans.h : ditto
4956
        * intrinsic.c : ditto
4957
        * interface.c : ditto
4958
        * iresolve.c : ditto
4959
        * trans-stmt.c : ditto
4960
        * trans-stmt.h : ditto
4961
        * parse,c : ditto
4962
        * match.h : ditto
4963
        * error.c : ditto
4964
 
4965
2010-03-20  Paul Thomas  
4966
 
4967
        PR fortran/43450
4968
        * trans-decl.c (gfc_create_module_variable): With -fwhole-file
4969
        do not assert the context of derived types.
4970
 
4971
2010-03-20  Jerry DeLisle  
4972
 
4973
        PR fortran/43409
4974
        * ioparm.def: Change inquire size variable to type pointer to
4975
        GFC_IO_INT type.
4976
 
4977
2010-03-18  Paul Thomas  
4978
 
4979
        PR fortran/43039
4980
        * trans-expr.c (conv_parent_component_references): Ensure that
4981
        'dt' has a backend_decl.
4982
 
4983
        PR fortran/43043
4984
        * trans-expr.c (gfc_conv_structure): Ensure that the derived
4985
        type has a backend_decl.
4986
 
4987
        PR fortran/43044
4988
        * resolve.c (resolve_global_procedure): Check that the 'cl'
4989
        structure is not NULL.
4990
 
4991
2010-03-18  Shujing Zhao  
4992
 
4993
        * lang.opt (-ffixed-line-length-, ffree-line-length-): Remove
4994
        redundant tab.
4995
 
4996
2010-03-17  Tobias Burnus  
4997
 
4998
        PR fortran/43331
4999
        * trans-array.c (gfc_conv_array_index_offset,gfc_conv_array_ref,
5000
        gfc_conv_ss_startstride): Remove no-longer-needed cp_was_assumed
5001
        check.
5002
        * decl.c (gfc_match_derived_decl): Don't mark assumed-size Cray
5003
        pointees as having explizit size.
5004
        * expr.c (gfc_check_assign): Remove now unreachable Cray pointee
5005
        check.
5006
        * trans-types.c (gfc_is_nodesc_array): Add cp_was_assumed to assert.
5007
        (gfc_sym_type): Don't mark Cray pointees as restricted pointers.
5008
        * resolve.c (resolve_symbol): Handle cp_was_assumed.
5009
        * trans-decl.c (gfc_trans_deferred_vars): Ditto.
5010
        (gfc_finish_var_decl): Don't mark Cray pointees as restricted
5011
        pointers.
5012
 
5013
2010-03-14  Tobias Burnus  
5014
 
5015
        PR fortran/43362
5016
        * resolve.c (resolve_structure_cons): Add missing PURE constraint.
5017
        (resolve_ordinary_assign): Add check to avoid segfault.
5018
 
5019
2010-03-12  Paul Thomas  
5020
 
5021
        PR fortran/43291
5022
        PR fortran/43326
5023
        * resolve.c (resolve_compcall): Add new boolean dummy argument
5024
        'class_members'. Only resolve expression at end if false.
5025
        Remove redundant, static variable 'class_object'.
5026
        (check_class_members): Add extra argument to call of
5027
        resolve_compcall.
5028
        (resolve_typebound_function): Renamed resolve_class_compcall.
5029
        Do all the detection of class references here. Correct calls to
5030
        resolve_compcall for extra argument.
5031
        (resolve_typebound_subroutine): resolve_class_typebound_call
5032
        renamed. Otherwise same as resolve_typebound_function.
5033
        (gfc_resolve_expr): Call resolve_typebound_function.
5034
        (resolve_code): Call resolve_typebound_subroutine.
5035
 
5036
2010-03-10  Tobias Burnus  
5037
 
5038
        PR fortran/43303
5039
        * symbol.c (get_iso_c_sym): Set sym->result.
5040
 
5041
2010-03-08  Janus Weil  
5042
 
5043
        PR fortran/43256
5044
        * resolve.c (resolve_compcall): Don't set 'value.function.name' here
5045
        for TBPs, otherwise they will not be resolved properly.
5046
        (resolve_function): Use 'value.function.esym' instead of
5047
        'value.function.name' to check if we're dealing with a TBP.
5048
        (check_class_members): Set correct type of passed object for all TBPs,
5049
        not only generic ones, except if the type is abstract.
5050
 
5051
2010-03-04  Janus Weil  
5052
 
5053
        PR fortran/43244
5054
        * decl.c (gfc_match_final_decl): Make sure variable names starting with
5055
        'final...' are not misinterpreted as FINAL statements.
5056
 
5057
2010-03-03  Paul Thomas  
5058
 
5059
        PR fortran/43243
5060
        * trans-array.c (gfc_conv_array_parameter): Contiguous refs to
5061
        allocatable ultimate components do not need temporaries, whilst
5062
        ultimate pointer components do.
5063
 
5064
2010-03-03  Janus Weil  
5065
 
5066
        PR fortran/43169
5067
        * resolve.c (resolve_code): Correctly set gfc_current_ns for
5068
        EXEC_SELECT_TYPE.
5069
        (gfc_impure_variable): Make it work with sub-namespaces (BLOCK etc).
5070
        (gfc_pure): Ditto.
5071
 
5072
2010-03-02  Paul Thomas  
5073
 
5074
        PR fortran/43180
5075
        * trans-array.c (gfc_conv_array_parameter): A full array of
5076
        derived type need not be restricted to a symbol without an
5077
        array spec to use the call to gfc_conv_expr_descriptor.
5078
 
5079
        PR fortran/43173
5080
        * trans-array.c (gfc_conv_array_parameter): Contiguous refs to
5081
        allocatable arrays do not need temporaries.
5082
 
5083
2010-03-01  Tobias Burnus  
5084
 
5085
        PR fortran/43199
5086
        * resolve.c (find_array_spec): Handle REF_COMPONENT with
5087
        CLASS components.
5088
 
5089
2010-02-28  Tobias Burnus  
5090
 
5091
        PR fortran/43205
5092
        * trans-expr.c (is_zero_initializer_p): Move up in the file.
5093
        (gfc_conv_initializer): Handle zero initializer as special case.
5094
 
5095
2010-02-27  Tobias Burnus  
5096
 
5097
        PR fortran/43185
5098
        * resolve.c (resolve_fl_variable_derived): Imply SAVE
5099
        for module variables for Fortran 2008.
5100
 
5101
2010-02-25  Jakub Jelinek  
5102
 
5103
        PR debug/43166
5104
        * trans-common.c (build_common_decl): Also update DECL_MODE,
5105
        and DECL_SIZE when encountering a larger common block and call
5106
        layout_decl.
5107
 
5108
2010-02-24  Tobias Burnus  
5109
 
5110
        PR fortran/43042
5111
        * trans-expr.c (gfc_conv_initializer): Call directly
5112
        gfc_conv_constant for C_NULL_(FUN)PTR.
5113
 
5114
2010-02-22  Paul Thomas  
5115
 
5116
        PR fortran/43072
5117
        * dependency.c (gfc_full_array_ref_p): Check for contiguous by
5118
        checking the rest of the dimensions for elements.
5119
 
5120
2010-02-21  Tobias Burnus  
5121
 
5122
        PR fortran/35259
5123
        * gfortran.h (gfc_option_t): New flag -fprotect-parens.
5124
        * lang.opt: Ditto.
5125
        * option.c (gfc_init_options,gfc_handle_option): Ditto.
5126
        * trans-expr.c (gfc_conv_expr_op): Use the flag.
5127
        * invoke.texi: Document new -fno-protect-parens flag.
5128
 
5129
2010-02-20  Paul Thomas  
5130
 
5131
        PR fortran/36932
5132
        PR fortran/36933
5133
        PR fortran/43072
5134
        PR fortran/43111
5135
        * dependency.c (gfc_check_argument_var_dependency): Use enum
5136
        value instead of arithmetic vaue for 'elemental'.
5137
        (check_data_pointer_types): New function.
5138
        (gfc_check_dependency): Call check_data_pointer_types.
5139
        * trans-array.h : Change fourth argument of
5140
        gfc_conv_array_parameter to boolean.
5141
        * trans-array.c (gfc_conv_array_parameter): A contiguous array
5142
        can be a dummy but it must not be assumed shape or deferred.
5143
        Change fourth argument to boolean. Array constructor exprs will
5144
        always be contiguous and do not need packing and unpacking.
5145
        * trans-expr.c (gfc_conv_procedure_call): Clean up some white
5146
        space and change fourth argument of gfc_conv_array_parameter
5147
        to boolean.
5148
        (gfc_trans_arrayfunc_assign): Change fourth argument of
5149
        gfc_conv_array_parameter to boolean.
5150
        * trans-io.c (gfc_convert_array_to_string): The same.
5151
        * trans-intrinsic.c (gfc_conv_intrinsic_loc): The same.
5152
 
5153
2010-02-20  Tobias Burnus  
5154
 
5155
        PR fortran/42958
5156
        * libgfortran.h: Add GFC_RTCHECK_MEM.
5157
        * invoke.texi (-fcheck=): Document -fcheck=mem.
5158
        * tranc.c (gfc_call_malloc): Remove negative-size run-time error
5159
        and enable malloc-success check only with -fcheck=mem.
5160
        * option.c (gfc_handle_runtime_check_option): Add -fcheck=mem.
5161
 
5162
2010-02-16  Tobias Burnus  
5163
 
5164
        PR fortran/43040
5165
        * gfortran.h (gfc_isym_id): Rename GFS_ISYM_GAMMA to GFS_ISYM_TGAMMA.
5166
        * intrinsic.c (add_functions): Ditto.
5167
        * iresolve.c (gfc_resolve_gamma): Call tgamma instead of gamma.
5168
        * mathbuiltins.def: Use TGAMMA instead of GAMMA with "tgamma".
5169
 
5170
2010-02-14  Jerry DeLisle  
5171
 
5172
        PR fortran/32382
5173
        * trans-stmt.h: Add prototype for gfc_trans_code_cond. Add tree cond to
5174
        gfc_trans_do prototype.
5175
        * trans-stmt.c (gfc_trans_simple_do): Add optional argument to pass in
5176
        a loop exit condition.  If exit condition is given, build the loop exit
5177
        code, checking IO results of implied do loops in READ and WRITE.
5178
        (gfc_trans_do): Likewise.
5179
        * trans.c (trans_code): New static work function, previously
5180
        gfc_trans_code. Passes exit condition to gfc_trans_do.
5181
        (gfc_trans_code): Calls trans_code with NULL_TREE condition.
5182
        (gfc_trans_code_cond): Calls trans_code with loop exit condition.
5183
        * trans-io.c (build_dt): Build an exit condition to allow checking IO
5184
        result status bits in the dtparm structure. Use this condition in call
5185
        to gfc_trans_code_cond.
5186
 
5187
2010-02-13  Paul Thomas  
5188
 
5189
        PR fortran/41113
5190
        PR fortran/41117
5191
        * trans-array.c (gfc_conv_array_parameter): Use
5192
        gfc_full_array_ref_p to detect full and contiguous variable
5193
        arrays. Full array components and contiguous arrays do not need
5194
        internal_pack and internal_unpack.
5195
 
5196
2010-02-11  Jakub Jelinek  
5197
 
5198
        PR fortran/43030
5199
        * resolve.c (gfc_resolve_dim_arg): Call gfc_clear_ts.
5200
 
5201
        PR fortran/43029
5202
        * decl.c (enumerator_decl): Don't call gfc_free_enum_history
5203
        here.
5204
        (gfc_match_enumerator_def): But here whenever enumerator_decl returns
5205
        MATCH_ERROR.
5206
 
5207
2010-02-10  Joost VandeVondele 
5208
            Tobias Burnus 
5209
 
5210
        PR fortran/40823
5211
        * decl.c (gfc_match_subroutine): Explicitly set sym->declared_at.
5212
 
5213
2010-02-10  Tobias Burnus  
5214
 
5215
        PR fortran/43015
5216
        * trans-decl.c (gfc_generate_function_code): Only check
5217
        actual-vs.-dummy character bounds if not bind(C).
5218
 
5219
2010-02-10  Jakub Jelinek  
5220
 
5221
        PR fortran/42309
5222
        * trans-expr.c (gfc_conv_subref_array_arg): Avoid accessing
5223
        info->dimen after info has been freed.
5224
 
5225
2010-02-09  Jerry DeLisle  
5226
 
5227
        PR fortran/42999
5228
        * array.c (gfc_constant_ac): Do not prevent expansion of constructors
5229
        with iterators.
5230
 
5231
2010-02-09  Jakub Jelinek  
5232
 
5233
        * module.c (fix_mio_expr): Declare sym.
5234
 
5235
2010-02-09  Paul Thomas  
5236
 
5237
        PR fortran/41869
5238
        * module.c (fix_mio_expr): Fix for private generic procedures.
5239
 
5240
2010-02-09  Daniel Kraft  
5241
 
5242
        PR fortran/39171
5243
        * resolve.c (resolve_charlen): Change warning about negative CHARACTER
5244
        length to be correct and issue only with -Wsurprising.
5245
        * invoke.texi (Wsurprising): Mention this new warning that is
5246
        turned on by -Wsurprising.
5247
 
5248
2010-02-09  Daniel Kraft  
5249
 
5250
        PR fortran/41507
5251
        * intrinsic.texi (MAXVAL): Remove wrong claim that array argument
5252
        can be CHARACTER type.
5253
        (MINVAL), (MAXLOC), (MINLOC): Ditto.
5254
 
5255
2010-02-05  Paul Thomas  
5256
 
5257
        PR fortran/42309
5258
        * trans-expr.c (gfc_conv_subref_array_arg): Add new argument
5259
        'formal_ptr'. If this is true, give returned descriptor unity
5260
        lbounds, in all dimensions, and the appropriate offset.
5261
        (gfc_conv_procedure_call); If formal is a pointer, set the last
5262
        argument of gfc_conv_subref_array_arg to true.
5263
        * trans.h : Add last argument for gfc_conv_subref_array_arg.
5264
        * trans-io.c (set_internal_unit, gfc_trans_transfer): Set the
5265
        new arg of gfc_conv_subref_array_arg to false.
5266
        * trans-stmt.c (forall_make_variable_temp): The same.
5267
 
5268
2010-02-03  Tobias Burnus  
5269
 
5270
        PR fortran/42936
5271
        * interface.c (compare_parameter): Disable rank-checking
5272
        for NULL().
5273
 
5274
2010-02-02  Tobias Burnus  
5275
 
5276
        PR fortran/42650
5277
        * parse.c (decode_specification_statement): Use sym->result not sym.
5278
 
5279
2010-02-01  Tobias Burnus  
5280
 
5281
        PR fortran/42922
5282
        * decl.c (variable_decl): Allow default initializer in
5283
        TYPE declarations in PURE functions.
5284
 
5285
2010-01-31  Janus Weil  
5286
 
5287
        PR fortran/42888
5288
        * resolve.c (resolve_allocate_expr): Move default initialization code
5289
        here from gfc_trans_allocate.
5290
        * trans.c (gfc_trans_code): Call gfc_trans_class_assign also for
5291
        EXEC_INIT_ASSIGN.
5292
        * trans-expr.c (gfc_trans_class_assign): Handle default initialization
5293
        of CLASS variables via memcpy.
5294
        * trans-stmt.c (gfc_trans_allocate): Move default initialization code
5295
        to resolve_allocate_expr.
5296
 
5297
2010-01-31  Paul Thomas  
5298
 
5299
        PR fortran/38324
5300
        * expr.c (gfc_get_full_arrayspec_from_expr): New function.
5301
        * gfortran.h : Add prototype for above.
5302
        * trans-expr.c (gfc_trans_alloc_subarray_assign): New function.
5303
        (gfc_trans_subcomponent_assign): Call new function to replace
5304
        the code to deal with allocatable components.
5305
        * trans-intrinsic.c (gfc_conv_intrinsic_bound): Call
5306
        gfc_get_full_arrayspec_from_expr to replace existing code.
5307
 
5308
2010-01-25  Tobias Burnus  
5309
 
5310
        PR fortran/42858
5311
        * array.c (gfc_array_dimen_size): Fix intrinsic procedure
5312
        check.
5313
 
5314
2010-01-24  Paul Thomas  
5315
 
5316
        PR fortran/41044
5317
        PR fortran/41167
5318
        * expr.c (remove_subobject_ref): If the constructor is NULL use
5319
        the expression as the source.
5320
        (simplify_const_ref): Change the type of expression if
5321
        there are component references.  Allow for substring to be at
5322
        the end of an arbitrarily long chain of references.  If an
5323
        element is found that is not in an EXPR_ARRAY, assume that this
5324
        is scalar initialization of array. Call remove_subobject_ref in
5325
        this case with NULL second argument.
5326
 
5327
2010-01-24  Tobias Burnus  
5328
 
5329
        PR fortran/39304
5330
        * array.c (gfc_array_dimen_size): Use correct specific
5331
        function in the check.
5332
 
5333
2010-01-21  Paul Thomas  
5334
 
5335
        PR fortran/42736
5336
        * trans-stmt.c (gfc_conv_elemental_dependencies): If temporary
5337
        is required, turn any trailing array elements after a range
5338
        into ranges so that offsets can be calculated.
5339
 
5340
2010-01-20  Joern Rennecke  
5341
 
5342
        * module.c (mio_f2k_derived): Use enumerator as initializer of
5343
        enum variable.
5344
 
5345
        PR bootstrap/42812
5346
        * gfortran.h  (struct gfc_namespace) : Change to signed
5347
        bitfield of width 2.
5348
 
5349
2010-01-19  Janus Weil  
5350
 
5351
        PR fortran/42804
5352
        * resolve.c (extract_compcall_passed_object): Set locus for
5353
        passed-object argument.
5354
        (extract_ppc_passed_object): Set locus and correctly remove PPC
5355
        reference.
5356
 
5357
2010-01-19  Paul Thomas  
5358
 
5359
        PR fortran/42783
5360
        * trans-decl.c (add_argument_checking): Do not use the backend
5361
        decl directly to test for the presence of an optional dummy
5362
        argument.  Use gfc_conv_expr_present, remembering to set the
5363
        symbol referenced.
5364
 
5365
        PR fortran/42772
5366
        * trans-decl.c (gfc_generate_function_code): Small white space
5367
        changes. If 'recurcheckvar' is NULL do not try to reset it.
5368
 
5369
2010-01-19  Janus Weil  
5370
 
5371
        PR fortran/42545
5372
        * resolve.c (resolve_fl_derived): Set the accessibility of the parent
5373
        component for extended types.
5374
        * symbol.c (gfc_find_component): Remove a wrongly-worded error message
5375
        and take care of parent component accessibility.
5376
 
5377
2010-01-17  Janus Weil  
5378
 
5379
        PR fortran/42677
5380
        * gfortran.h (symbol_attribute): Remove 'ambiguous_interfaces'.
5381
        * interface.c (check_interface1): Move a warning message here from
5382
        resolve_fl_procedure.
5383
        (check_sym_interfaces): Removed 'attr.ambiguous_interfaces'.
5384
        * module.c (read_module): Remove call to gfc_check_interfaces, since
5385
        this comes too early here.
5386
        * resolve.c (resolve_fl_procedure): Move warning message to
5387
        check_interface1.
5388
 
5389
2010-01-14 Jerry DeLisle 
5390
 
5391
        PR fortran/42684
5392
        * interface.c (check_interface1): Pass symbol name rather than NULL to
5393
        gfc_compare_interfaces. (gfc_compare_interfaces): Add assert to
5394
        trap MULL.
5395
        * resolve.c (check_generic_tbp_ambiguity): Pass symbol name rather
5396
        than NULL to gfc_compare_interfaces.
5397
 
5398
2010-01-14  Paul Thomas  
5399
 
5400
        PR fortran/41478
5401
        * trans-array.c (duplicate_allocatable):  Static version of
5402
        gfc_duplicate_allocatable with provision to handle scalar
5403
        components. New boolean argument to switch off call to malloc
5404
        if true.
5405
        (gfc_duplicate_allocatable): New function to call above with
5406
        new argument false.
5407
        (gfc_copy_allocatable_data): New function to call above with
5408
        new argument true.
5409
        (structure_alloc_comps): Do not apply indirect reference to
5410
        scalar pointers. Add new section to copy allocatable components
5411
        of arrays. Extend copying of allocatable components to include
5412
        scalars.
5413
        (gfc_copy_only_alloc_comp): New function to copy allocatable
5414
        component derived types, without allocating the base structure.
5415
        * trans-array.h : Add primitive for gfc_copy_allocatable_data.
5416
        Add primitive for gfc_copy_only_alloc_comp.
5417
        * trans-expr.c (gfc_conv_procedure_call): After calls to
5418
        transformational functions with results that are derived types
5419
        with allocatable components, copy the components in the result.
5420
        (gfc_trans_arrayfunc_assign): Deallocate allocatable components
5421
        of lhs derived types before allocation.
5422
 
5423
2010-01-14  Paul Thomas  
5424
 
5425
        PR fortran/42481
5426
        * module.c (load_generic_interfaces): If a procedure that is
5427
        use associated but not generic is given an interface that
5428
        includes itself, then make it generic.
5429
 
5430
2010-01-11  Joseph Myers  
5431
            Shujing Zhao  
5432
 
5433
        PR translation/42469
5434
        * lang.opt (fblas-matmul-limit=, finit-character=, finit-integer=,
5435
        finit-logical=, finit-real=, fmax-array-constructor=): Use tab
5436
        character between option name and help text.
5437
 
5438
2010-01-09 Jerry DeLisle 
5439
 
5440
        PR fortran/20923
5441
        PR fortran/32489
5442
        * trans-array.c (gfc_conv_array_initializer): Change call to
5443
        gfc_error_now to call to gfc_fatal_error.
5444
        * array.c (count_elements): Whitespace. (extract_element): Whitespace.
5445
        (is_constant_element): Changed name from constant_element.
5446
        (gfc_constant_ac): Only use expand_construuctor for expression
5447
        types of EXPR_ARRAY.  If expression type is EXPR_CONSTANT, no need to
5448
        call gfc_is_constant_expr.
5449
        * expr.c (gfc_reduce_init_expr): Adjust conditionals and delete error
5450
        message.
5451
        * resolve.c (gfc_is_expandable_expr): New function that determiners if
5452
        array expressions should have their constructors expanded.
5453
        (gfc_resolve_expr): Use new function to determine whether or not to call
5454
        gfc_expand_constructor.
5455
 
5456
2010-01-09  Tobias Burnus  
5457
 
5458
        PR fortran/41298
5459
        * trans-expr.c (gfc_trans_structure_assign): Handle
5460
        c_null_(fun)ptr.
5461
        * symbol.c (gen_special_c_interop_ptr): Add NULL_EXPR
5462
        to the constructor for c_null_(fun)ptr.
5463
        * resolve.c (resolve_structure_cons): Add special case
5464
        for c_null_(fun)ptr.
5465
 
5466
2010-01-09  Jakub Jelinek  
5467
 
5468
        * gfortranspec.c (lang_specific_driver): Update copyright notice
5469
        dates.
5470
 
5471
2010-01-08  Tobias Burnus  
5472
 
5473
        PR/fortran 25829
5474
        * symbol.c (check_conflict, gfc_copy_attr): Add
5475
        ASYNCHRONOUS support.
5476
        (gfc_add_asynchronous): New function.
5477
        * decl.c (match_attr_spec): Add ASYNCHRONOUS support.
5478
        (gfc_match_asynchronous): New function.
5479
        * dump-parse-tree.c (show_attr): Add ASYNCHRONOUS support.
5480
        * gfortran.h (symbol_attribute): New ASYNCHRONOUS bit.
5481
        (gfc_add_asynchronous): New Prototype.
5482
        * module.c (ab_attribute, mio_symbol_attribute): Add
5483
        ASYNCHRONOUS support.
5484
        * resolve.c (was_declared): Ditto.
5485
        * match.h (gfc_match_asynchronous): New prototype.
5486
        * parse.c (decode_specification_statement,decode_statement):
5487
        Add ASYNCHRONOUS support.
5488
 
5489
2010-01-07  Tobias Burnus  
5490
 
5491
        PR fortran/42597
5492
        * trans-decl.c (get_proc_pointer_decl): Fix call to
5493
        gfc_conv_initializer for array-valued proc-pointer funcs.
5494
 
5495
2010-01-07  Tobias Burnus  
5496
 
5497
        PR fortran/41872
5498
        * trans-decl.c (gfc_trans_deferred_vars): Don't initialize
5499
        allocatable scalars with SAVE attribute.
5500
 
5501
2010-01-05  Tobias Burnus  
5502
 
5503
        PR fortran/42517
5504
        * options.c (gfc_post_options): Set -frecursion
5505
        when -fopenmp is used.
5506
 
5507
2010-01-05  Tobias Burnus  
5508
 
5509
        PR fortran/41872
5510
        * trans-expr.c (gfc_conv_procedure_call): Nullify
5511
        return value for allocatable-scalar character functions.
5512
 
5513
2010-01-04  Tobias Burnus  
5514
 
5515
        PR fortran/36161
5516
        * error.c (error_printf, gfc_warning, gfc_notify_std,
5517
        gfc_warning_now, gfc_error, gfc_error_now,
5518
        gfc_fatal_error): Change argument name from nocmsgid to
5519
        gmsgid to enable (x)gettext's % checking.
5520
 
5521
2010-01-04  Tobias Burnus  
5522
 
5523
        * trans-decl.c (gfc_trans_deferred_vars): Fix spelling.
5524
 
5525
2010-01-04  Tobias Burnus  
5526
 
5527
        PR fortran/41872
5528
        * trans-expr.c (gfc_conv_procedure_call): Add indirect ref
5529
        for functions returning allocatable scalars.
5530
        * trans-stmt.c (gfc_trans_allocate): Emmit error when
5531
        reallocating an allocatable scalar.
5532
        * trans.c (gfc_allocate_with_status): Fix pseudocode syntax
5533
        in comment.
5534
        * trans-decl.c (gfc_trans_deferred_vars): Nullify local
5535
        allocatable scalars.
5536
        (gfc_generate_function_code): Nullify result variable for
5537
        allocatable scalars.
5538
 
5539
        PR fortran/40849
5540
        * module.c (gfc_use_module): Fix warning string to allow
5541
        for translation.
5542
 
5543
        PR fortran/42517
5544
        * invoke.texi (-fcheck=recursion): Mention that the checking
5545
        is also disabled for -frecursive.
5546
        * trans-decl.c (gfc_generate_function_code): Disable
5547
        -fcheck=recursion when -frecursive is used.
5548
 
5549
        * intrinsic.texi (iso_c_binding): Improve wording.
5550
 
5551
 
5552
Copyright (C) 2010 Free Software Foundation, Inc.
5553
 
5554
Copying and distribution of this file, with or without modification,
5555
are permitted in any medium without royalty provided the copyright
5556
notice and this notice are preserved.

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.