c23b81f5e30462094994f10ecaa299580a6b0839
[gcc.git] / gcc / fortran / ChangeLog
1 2008-02-16 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
2
3 PR fortran/34952
4 * gfortran.texi: Create new section for unimplemented extensions.
5 Add "STRUCTURE and RECORD" and "ENCODE and DECODE statements".
6 Remove "smaller projects" list. Fix a few typos.
7
8 2008-02-15 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
9
10 * intrinsic.texi: Rename INDEX node to avoid clashing with
11 index.html on case-insensitive systems.
12
13 2008-02-15 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
14
15 PR fortran/35150
16 * trans-expr.c (gfc_conv_function_call): Force evaluation of
17 se->expr.
18
19 2008-02-10 Daniel Franke <franke.daniel@gmail.com>
20
21 fortran/PR35019
22 * lang.opt: Allow '-J<dir>' next to '-J <dir>',
23 likewise '-I <dir>' and '-I<dir>'.
24
25 2008-02-06 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
26
27 PR other/35107
28 * Make-lang.in (f951): Add $(GMPLIBS).
29
30 2008-02-05 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
31
32 PR fortran/35037
33 * trans-common.c (build_field): Mark fields as volatile when needed.
34
35 2008-02-05 Tobias Burnus <burnus@net-b.de>
36
37 PR fortran/35093
38 * data.c (gfc_assign_data_value): Only free "size" if
39 it has not already been freed.
40
41 2008-02-05 Paul Thomas <pault@gcc.gnu.org>
42
43 PR fortran/34945
44 * array.c (match_array_element_spec): Remove check for negative
45 array size.
46 (gfc_resolve_array_spec): Add check for negative size.
47
48 2008-02-05 Paul Thomas <pault@gcc.gnu.org>
49
50 PR fortran/32315
51 * data.c (gfc_assign_data_value): Add bounds check for array
52 references.
53
54 2008-02-04 Daniel Franke <franke.daniel@gmail.com>
55
56 * resolve.c (resolve_where): Fix typo.
57 (gfc_resolve_where_code_in_forall): Likewise.
58
59 2008-02-03 Paul Thomas <pault@gcc.gnu.org>
60
61 PR fortran/32760
62 * resolve.c (resolve_allocate_deallocate): New function.
63 (resolve_code): Call it for allocate and deallocate.
64 * match.c (gfc_match_allocate, gfc_match_deallocate) : Remove
65 the checking of the STAT tag and put in above new function.
66 * primary,c (match_variable): Do not fix flavor of host
67 associated symbols yet if the type is not known.
68
69 2008-01-31 Paul Thomas <pault@gcc.gnu.org>
70
71 PR fortran/34910
72 * expr.c (gfc_check_assign): It is an error to assign
73 to a sibling procedure.
74
75 2008-01-30 Paul Thomas <pault@gcc.gnu.org>
76
77 PR fortran/34975
78 * symbol.c (gfc_delete_symtree, gfc_undo_symbols): Rename
79 delete_symtree to gfc_delete_symtree.
80 * gfortran.h : Add prototype for gfc_delete_symtree.
81 * module.c (load_generic_interfaces): Transfer symbol to a
82 unique symtree and delete old symtree, instead of renaming.
83 (read_module): The rsym and the found symbol are the same, so
84 the found symtree can be deleted.
85
86 PR fortran/34429
87 * decl.c (match_char_spec): Remove the constraint on deferred
88 matching of functions and free the length expression.
89 delete_symtree to gfc_delete_symtree.
90 (gfc_match_type_spec): Whitespace.
91 (gfc_match_function_decl): Defer characteristic association for
92 all types except BT_UNKNOWN.
93 * parse.c (decode_specification_statement): Only derived type
94 function matching is delayed to the end of specification.
95
96 2008-01-28 Tobias Burnus <burnus@net-b.de>
97
98 PR libfortran/34980
99 * simplify.c (gfc_simplify_shape): Simplify rank zero arrays.
100
101 2008-01-27 Jerry DeLisle <jvdelisle@gcc.gnu.org>
102
103 PR fortran/34990
104 * array.c (gfc_check_constructor_type): Revert clearing the expression.
105
106 2008-01-26 Tobias Burnus <burnus@net-b.de>
107
108 PR fortran/34848
109 * trans-expr.c (gfc_conv_function_call): Don't call
110 gfc_add_interface_mapping if the expression is NULL.
111
112 2008-01-26 Jerry DeLisle <jvdelisle@gcc.gnu.org>
113
114 PR fortran/31610
115 * trans-array.c (gfc_trans_create_temp_array): Remove call to
116 gcc_assert (integer_zerop (loop->from[n])).
117
118 2008-01-25 Daniel Franke <franke.daniel@gmail.com>
119
120 PR fortran/34661
121 * resolve.c (resolve_where): Added check if user-defined assignment
122 operator is an elemental subroutine.
123 (gfc_resolve_where_code_in_forall): Likewise.
124
125 2008-01-24 Daniel Franke <franke.daniel@gmail.com>
126
127 PR fortran/33375
128 PR fortran/34858
129 * gfortran.h: Revert changes from 2008-01-17.
130 * match.c: Likewise.
131 * symbol.c: Likewise.
132 (gfc_undo_symbols): Undo namespace changes related to common blocks.
133
134 2008-01-24 Daniel Franke <franke.daniel@gmail.com>
135
136 PR fortran/34202
137 * data.c (formalize_structure_cons): Skip formalization on
138 empty structures.
139
140 2008-01-24 Daniel Franke <franke.daniel@gmail.com>
141
142 * gfortran.texi (OpenMP): Extended existing documentation.
143 (contributors): Added major contributors of 2008 that were
144 not listed yet.
145 (proposed extensions): Removed implemented items.
146
147 2008-01-24 Paul Thomas <pault@gcc.gnu.org>
148
149 PR fortran/34872
150 * parse.c (next_statement) : If ST_GET_FCN_CHARACTERISTICS is
151 seen, check for a statement label and, if present, delete it
152 and set the locus to the start of the statement.
153
154 2008-01-22 Paul Thomas <pault@gcc.gnu.org>
155
156 PR fortran/34875
157 * trans-io.c (gfc_trans_transfer): If the array reference in a
158 read has a vector subscript, use gfc_conv_subref_array_arg to
159 copy back the temporary.
160
161 2008-01-22 Tobias Burnus <burnus@net-b.de>
162
163 PR fortran/34848
164 * interface.c (compare_actual_formal): Fix adding type
165 to missing_arg_type for absent optional arguments.
166
167 2008-01-22 Tobias Burnus <burnus@net-b.de>
168
169 PR fortran/34907
170 * parse.c (parse_spec): Change = into ==.
171
172 2008-01-22 Daniel Franke <franke.daniel@gmail.com>
173
174 PR fortran/34915
175 * expr.c (check_elemental): Fix check for valid data types.
176
177 2008-01-22 Tobias Burnus <burnus@net-b.de>
178
179 PR fortran/34899
180 * scanner.c (load_line): Support <tab><digit> continuation lines.
181 * invoke.texi (-Wtabs): Document this.
182
183 2008-01-22 Paul Thomas <pault@gcc.gnu.org>
184
185 PR fortran/34896
186 * module.c (read_module): Set use_rename attribute.
187
188 2007-01-21 Tobias Burnus <burnus@net-b.de>
189
190 PR fortran/34901
191 * interface.c (compare_parameter): Improved error message
192 for arguments of same type and mismatched kinds.
193
194 2008-01-20 Paul Thomas <pault@gcc.gnu.org>
195
196 PR fortran/34861
197 * resolve.c (resolve_entries): Do not do an array bounds check
198 if the result symbols are the same.
199
200 PR fortran/34854
201 * module.c (read_module) : Hide the symtree of the previous
202 version of the symbol if this symbol is renamed.
203
204 2008-01-20 Paul Thomas <pault@gcc.gnu.org>
205
206 PR fortran/34784
207 * array.c (gfc_check_constructor_type): Clear the expression ts
208 so that the checking starts from the deepest level of array
209 constructor.
210 * primary.c (match_varspec): If an unknown type is changed to
211 default character and the attempt to match a substring fails,
212 change it back to unknown.
213
214 PR fortran/34785
215 * trans-array.c (gfc_add_loop_ss_code) : If ss->string_length is
216 NULL for an array constructor, use the cl.length expression to
217 build it.
218 (gfc_conv_array_parameter): Change call to gfc_evaluate_now to
219 a tree assignment.
220
221 2008-01-19 Thomas Koenig <tkoenig@gcc.gnu.org>
222
223 PR fortran/34817
224 PR fortran/34838
225 * iresolve.c (gfc_resolve_all): Remove conversion of mask
226 argument to kind=1 by removing call to resolve_mask_arg().
227 (gfc_resolve_any): Likewise.
228
229 2008-01-19 Tobias Burnus <burnus@net-b.de>
230
231 PR fortran/34760
232 * primary.c (match_variable): Handle FL_UNKNOWN without
233 uneducated guessing.
234 (match_variable): Improve error message.
235
236 2008-01-18 Tobias Burnus <burnus@net-b.de>
237
238 PR fortran/32616
239 * interface.c (get_expr_storage_size): Return storage size
240 for array element designators.
241 (compare_actual_formal): Reject unequal string sizes for
242 assumed-shape dummy arguments. And fix error message for
243 array-sections with vector subscripts.
244
245 2008-01-17 Jerry DeLisle <jvdelisle@gcc.gnu.org>
246
247 PR fortran/34556
248 * simplify.c (is_constant_array_expr): New static function that returns
249 true if the given expression is an array and is constant.
250 (gfc_simplify_reshape): Use new function.
251
252 2008-01-17 H.J. Lu <hongjiu.lu@intel.com>
253
254 PR fortran/33375
255 * symbol.c (free_common_tree): Renamed to ...
256 (gfc_free_common_tree): This. Remove static.
257 (gfc_free_namespace): Updated.
258
259 * gfortran.h (gfc_free_common_tree): New.
260
261 * match.c (gfc_match_common): Call gfc_free_common_tree () with
262 gfc_current_ns->common_root and set gfc_current_ns->common_root
263 to NULL on syntax error.
264
265 2008-01-18 Richard Sandiford <rsandifo@nildram.co.uk>
266
267 PR fortran/34686
268 * trans-expr.c (gfc_conv_function_call): Use proper
269 type for returned character pointers.
270
271 2008-01-17 Paul Thomas <pault@gcc.gnu.org>
272
273 PR fortran/34429
274 PR fortran/34431
275 PR fortran/34471
276 * decl.c : Remove gfc_function_kind_locus and
277 gfc_function_type_locus. Add gfc_matching_function.
278 (match_char_length): If matching a function and the length
279 does not match, return MATCH_YES and try again later.
280 (gfc_match_kind_spec): The same.
281 (match_char_kind): The same.
282 (gfc_match_type_spec): The same for numeric and derived types.
283 (match_prefix): Rename as gfc_match_prefix.
284 (gfc_match_function_decl): Except for function valued character
285 lengths, defer applying kind, type and charlen info until the
286 end of specification block.
287 gfortran.h (gfc_statement): Add ST_GET_FCN_CHARACTERISTICS.
288 parse.c (decode_specification_statement): New function.
289 (decode_statement): Call it when a function has kind = -1. Set
290 and reset gfc_matching function, as function statement is being
291 matched.
292 (match_deferred_characteristics): Simplify with a single call
293 to gfc_match_prefix. Do appropriate error handling. In any
294 case, make sure that kind = -1 is reset or corrected.
295 (parse_spec): Call above on seeing ST_GET_FCN_CHARACTERISTICS.
296 Throw an error if kind = -1 after last specification statement.
297 parse.h : Prototype for gfc_match_prefix.
298
299 2008-01-16 Tobias Burnus <burnus@net-b.de>
300
301 PR fortran/34796
302 * interface.c (compare_parameter): Allow AS_DEFERRED array
303 elements and reject attr.pointer array elemenents.
304 (get_expr_storage_size): Return storage size of elements of
305 assumed-shape and pointer arrays.
306
307 2008-01-15 Sebastian Pop <sebastian.pop@amd.com>
308
309 * f95-lang.c (gfc_init_builtin_functions): Initialize GOMP builtins
310 for flag_tree_parallelize_loops.
311
312 2008-01-15 Thomas Koenig <tkoenig@gcc.gnu.org>
313
314 PR libfortran/34671
315 * iresolve.c (gfc_resolve_all): Call resolve_mask_arg.
316 (gfc_resolve_any): Likewise.
317 (gfc_resolve_count): Likewise. Don't append kind of
318 argument to function name.
319
320 2008-01-13 Tobias Burnus <burnus@net-b.de>
321
322 PR fortran/34665
323 * resolve.c (resolve_actual_arglist): For expressions,
324 also check for assume-sized arrays.
325 * interface.c (compare_parameter): Move F2003 character checks
326 here, print error messages here, reject elements of
327 assumed-shape array as argument to dummy arrays.
328 (compare_actual_formal): Update for the changes above.
329
330 2008-01-13 Tobias Burnus <burnus@net-b.de>
331
332 PR fortran/34763
333 * decl.c (contained_procedure): Only check directly preceeding state.
334
335 2008-01-13 Tobias Burnus <burnus@net-b.de>
336
337 PR fortran/34759
338 * check.c (gfc_check_shape): Accept array ranges of
339 assumed-size arrays.
340
341 2008-01-12 Jerry DeLisle <jvdelisle@gcc.gnu.org>
342
343 PR fortran/34432
344 * match.c (gfc_match_name): Don't error if leading character is a '(',
345 just return MATCH_NO.
346
347 2008-01-11 Jerry DeLisle <jvdelisle@gcc.gnu.org>
348
349 PR fortran/34722
350 * trans-io.c (create_dummy_iostat): Commit the symbol.
351
352 2008-01-11 Paul Thomas <pault@gcc.gnu.org>
353
354 PR fortran/34537
355 * simplify.c (gfc_simplify_transfer): Return NULL if the size
356 of the element is unavailable and only assign character length
357 to the result, if 'mold' is constant.
358
359 2008-01-10 Paul Thomas <pault@gcc.gnu.org>
360
361 PR fortran/34396
362 * trans-array.c (gfc_trans_array_ctor_element): Use gfc_trans_string_copy
363 to assign strings and perform bounds checks on the string length.
364 (get_array_ctor_strlen): Remove bounds checking.
365 (gfc_trans_array_constructor): Initialize string length checking.
366 * trans-array.h : Add prototype for gfc_trans_string_copy.
367
368 2008-01-08 Richard Guenther <rguenther@suse.de>
369
370 PR fortran/34706
371 PR tree-optimization/34683
372 * trans-types.c (gfc_get_array_type_bounds): Use an array type
373 with known size for accesses if that is known.
374
375 2008-01-08 Paul Thomas <pault@gcc.gnu.org>
376
377 PR fortran/34476
378 * expr.c (find_array_element): Check that the array bounds are
379 constant before using them. Use lower, as well as upper bound.
380 (check_restricted): Allow implied index variable.
381
382 2008-01-08 Paul Thomas <pault@gcc.gnu.org>
383
384 PR fortran/34681
385 * trans_array.c (gfc_trans_deferred_array): Do not null the
386 data pointer on entering scope, nor deallocate it on leaving
387 scope, if the symbol has the 'save' attribute.
388
389 PR fortran/34704
390 * trans_decl.c (gfc_finish_var_decl): Derived types with
391 allocatable components and an initializer must be TREE_STATIC.
392
393 2008-01-07 Paul Thomas <pault@gcc.gnu.org>
394
395 PR fortran/34672
396 * module.c (write_generic): Rewrite completely.
397 (write_module): Change call to write_generic.
398
399 2008-01-06 Jerry DeLisle <jvdelisle@gcc.gnu.org>
400
401 PR fortran/34659
402 * scanner.c (load_line): Do not count ' ' as printable when checking for
403 continuations.
404
405 2008-01-06 Paul Thomas <pault@gcc.gnu.org>
406
407 PR fortran/34545
408 * module.c (load_needed): If the namespace has no proc_name
409 give it the module symbol.
410
411 2008-01-06 Jerry DeLisle <jvdelisle@gcc.gnu.org>
412
413 PR fortran/34387
414 * trans-expr.c (gfc_conv_missing_dummy): Use a temporary to type convert
415 the dummy variable expression, test for NULL, and pass the variable
416 address to the called function.
417
418 2007-01-06 Tobias Burnus <burnus@net-b.de>
419
420 PR fortran/34658
421 * match.c (gfc_match_common): Remove blank common in
422 DATA BLOCK warning.
423 * resolve.c (resolve_common_vars): New function.
424 (resolve_common_blocks): Move checks to resolve_common_vars
425 and invoke that function.
426 (resolve_types): Call resolve_common_vars for blank commons.
427
428 2008-01-06 Tobias Burnus <burnus@net-b.de>
429
430 PR fortran/34655
431 * resolve.c (resolve_equivalence_derived): Reject derived types with
432 default initialization if equivalenced with COMMON variable.
433
434 2008-01-06 Tobias Burnus <burnus@net-b.de>
435
436 PR fortran/34654
437 * io.c (check_io_constraints): Disallow unformatted I/O for
438 internal units.
439
440 2008-01-06 Tobias Burnus <burnus@net-b.de>
441
442 PR fortran/34660
443 * resolve.c (resolve_formal_arglist): Reject dummy procedure in
444 ELEMENTAL functions.
445
446 2008-01-06 Tobias Burnus <burnus@net-b.de>
447
448 PR fortran/34662
449 * interface.c (compare_actual_formal): Reject parameter
450 actual to intent(out) dummy.
451
452 2008-01-04 Tobias Burnus <burnus@net-b.de>
453
454 PR fortran/34557
455 * primary.c (match_varspec): Gobble whitespace before
456 checking for '('.