aboutsummaryrefslogtreecommitdiff
path: root/libgfortran
AgeCommit message (Collapse)AuthorFilesLines
2006-02-28re PR libfortran/26464 (Runtime I/O error/invald argument on READ)Jerry DeLisle3-3/+13
2006-02-27 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/26464 * io/file_pos.c (st_backspace): Flush and truncate file when in AFTER_ENDFILE condition. * io/transfer.c (st_read_done): Remove flush, no longer needed. From-SVN: r111506
2006-02-24re PR libfortran/26423 (Error on binary I/O for large array)Jerry DeLisle2-6/+17
2006-02-24 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/26423 * io/unix.c (fd_seek): Revert change from 25949. (fd_read): Same. (fd_write): Same. From-SVN: r111420
2006-02-19re PR libfortran/21303 (L edit descriptor without a width)François-Xavier Coudert4-4/+42
PR libfortran/21303 * gfortran.h (notification): New enumeration. (gfc_notification_std): Prototype for the new function. * error.c (gfc_notification_std): New function. * io.c (check_format): Handle the case of a L format descriptor without a width. * runtime/error.c (notification_std): New function. * libgfortran.h (notification): New enumeration. * io/io.h (notification_std): Prototype for the new function. * io/format.c (parse_format_list): Handle the case of a L format descriptor without a width. * gcc/testsuite/gfortran.dg/fmt_l.f90: New test. From-SVN: r111281
2006-02-19* io/open.c (edit_modes): Correct abusive copy-pasting.Francois-Xavier Coudert2-1/+5
From-SVN: r111266
2006-02-16re PR libfortran/24903 (dotprod should use __builtin_conj)Francois-Xavier Coudert6-15/+16
PR libfortran/24903 * m4/dotprodc.m4: Use __builtin_conj instead of assigning real and imaginary parts separately. * generated/dotprod_c4.c: Regenerated. * generated/dotprod_c8.c: Regenerated. * generated/dotprod_c10.c: Regenerated. * generated/dotprod_c16.c: Regenerated. From-SVN: r111131
2006-02-12re PR libfortran/25949 (Unbounded I/O buffer memory usage for formatted IO)Janne Blomqvist4-86/+139
2006-02-12 Janne Blomqvist <jb@gcc.gnu.org> PR libgfortran/25949 * io/io.h: Add set function pointer to struct stream. * io/unix.c (fd_seek): Only update offset, don't seek. (fd_sset): New function. (fd_read): Call lseek directly if necessary. (fd_write): Likewise. (fd_open): Set pointer to fd_sset. (mem_set): New function. (open_internal): Set pointer to mem_set. * io/transfer.c (write_block_direct): Rename to write_buf, add error return, non-pointer length argument. (unformatted_write): Update to use write_buf. (us_write): Simplify by using swrite instead of salloc_w. (write_us_marker): New function. (new_record_w): Use sset instead of memset, use write_us_marker, simplify by using swrite instead of salloc_w. From-SVN: r110895
2006-02-08re PR libfortran/25425 ([4.1 only] F95 and F2003 differ on list-directed ↵François-Xavier Coudert5-6/+24
output for 0.0) PR libfortran/25425 * trans-decl.c (gfc_generate_function_code): Add new argument, pedantic, to set_std call. * libgfortran.h: Add pedantic field to compile_options struct. * io/write.c (calculate_G_format): Depending on the standard, choose E or F format for list-directed output of 0.0. * runtime/error.c (notify_std): Make warning and error dependent on pedanticity. * runtime/compile_options.c (set_std): Use new pedantic argument. From-SVN: r110769
2006-02-08re PR libfortran/25577 (gfortran routine mvbits returns wrong answer.)Tobias Schlüter2-2/+7
libgfortran/ 2006-02-07 Dale Ranta <dir@lanl.gov> PR fortran/25577 * intrinsics/mvbits.c: Shift '(TYPE)1' type when building 'lenmask'. testsuite/ 2006-02-07 Tobias Schlueter <tobias.schlueter@physik.uni-muenchen.de> PR fortran/25577 * gfortran.dg/mvbits_1.f90: New. Also fixed Dirk Mueller's preceding ChangeLog entry. From-SVN: r110728
2006-02-07c99_functions.c: Work around incompatible declarations of cabs{,f,l} on ↵Rainer Emrich2-0/+19
pre-C99 IRIX systems. 2006-02-07 Rainer Emrich <r.emrich@de.tecosim.com> * intrinsics/c99_functions.c: Work around incompatible declarations of cabs{,f,l} on pre-C99 IRIX systems. From-SVN: r110700
2006-02-06re PR fortran/23815 (Add -byteswapio flag)Thomas Koenig6-29/+521
2005-02-06 Thomas Koenig <Thomas.Koenig@online.de> PR libfortran/23815 * gfortran.texi: Document the GFORTRAN_CONVERT_UNIT environment variable. * invoke.texi: Mention the "Runtime" chapter. Document the -fconvert= option. * gfortran.h: Add options_convert. * lang.opt: Add fconvert=little-endian, fconvert=big-endian, fconvert=native and fconvert=swap. * trans-decl.c (top level): Add gfor_fndecl_set_convert. (gfc_build_builtin_function_decls): Set gfor_fndecl_set_convert. (gfc_generate_function_code): If -fconvert was specified, and this is the main program, add a call to set_convert(). * options.c: Handle the -fconvert options. 2005-02-06 Thomas Koenig <Thomas.Koenig@online.de> PR libfortran/23815 * runtime/environ.c (init_unformatted): Add GFORTRAN_CONVERT_UNIT environment variable. (top level): Add defines, type and static variables for GFORTRAN_CONVERT_UNIT handling. (search_unit): New function. (match_word): New function. (match_integer): New function. (next_token): New function. (push_token): New function. (mark_single): New function. (mark_range): New funciton. (do_parse): New function. (init_unformatted): New function. (get_unformatted_convert): New function. * runtime/compile_options.c: Add set_convert(). * libgfortran.h: Add convert to compile_options_t. * io/open.c (st_open): Call get_unformatted_convert to get unit default; if CONVERT_NONE is returned, check for the presence of a CONVERT specifier and use it. As default, use compile_options.convert. * io/io.h (top level): Add CONVERT_NONE to unit_convert, to signal "nothing has been set". (top level): Add prototype for get_unformatted_convert. 2005-02-06 Thomas Koenig <Thomas.Koenig@online.de> PR libfortran/23815 * unf_io_convert_4.f90: New test. From-SVN: r110664
2006-02-05re PR libfortran/24685 (real(16) formatted input is broken for huge values ↵Francois-Xavier Coudert2-2/+8
(gfortran.dg/default_format_2.f90)) PR libfortran/24685 * io/write.c (write_real): Widen the default format for real(10) variables output. * gfortran.dg/large_real_kind_form_io_2.f90: New test. From-SVN: r110627
2006-01-29ChangeLog: Remove garbage text from one entry.Jerry DeLisle1-1/+0
2006-01-29 Jerry DeLisle <jvdelisle@gcc.gnu.org> * ChangeLog: Remove garbage text from one entry. From-SVN: r110381
2006-01-25re PR libfortran/25835 (Segfault or Bad Address error on unformatted ↵Jerry DeLisle2-0/+6
sequential READ) 2006-01-24 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/25835 * io/transfer.c (st_read_done): Flush buffers when read is done. From-SVN: r110200
2006-01-18re PR libfortran/25697 (libfortran - Segmentation fault/ Bad Address on ↵Jerry DeLisle2-2/+14
unformatted read) 2006-01-17 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/25697 * io/transfer.c (us_read): Detect end of file condition from previous operations and bail out (no need to pre-position). From-SVN: r109870
2006-01-18re PR libfortran/25631 (tl format specifier not working correctly)Jerry DeLisle2-1/+21
2006-01-17 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/25631 * io/transfer.c (formatted_transfer_scalar): Adjust pending_spaces and skips so that TL works correctly when no bytes_used yet. From-SVN: r109858
2006-01-16configure.ac (CFLAGS): Update to include -std=gnu99 so that the configure ↵Roger Sayle3-259/+521
tests will be run with the... * configure.ac (CFLAGS): Update to include -std=gnu99 so that the configure tests will be run with the same environment as used to compile the libgfortran source code. * configure: Regenerate. From-SVN: r109774
2006-01-12c99_functions.c: Add function prototypes to avoid warnings from ↵Roger Sayle2-0/+34
-Wstrict-prototypes... * intrinsics/c99_functions.c: Add function prototypes to avoid warnings from -Wstrict-prototypes -Wmissing-prototypes. On Tru64 work around a brain-dead libm by redirecting calls to cabs{,f,l} to a local __gfc_cabs{,f,l}. From-SVN: r109646
2006-01-07configure.ac: Remove check for sys/mman.h.Janne Blomqvist6-516/+286
2006-01-07 Janne Blomqvist <jb@gcc.gnu.org> * configure.ac: Remove check for sys/mman.h. * configure: Regenerated. * Makefile.in: Regenerated. * config.h.in: Regenerated. * aclocal.m4: Regenerated. From-SVN: r109455
2006-01-07Fix date.Jerry DeLisle1-1/+1
From-SVN: r109447
2006-01-06Fix previous ChangeLog entryTobias Schlüter1-4/+0
From-SVN: r109417
2006-01-06re PR libfortran/25598 (gfortran - Fortran runtime error: Invalid argument)Jerry DeLisle3-3/+22
2006-01-05 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/25598 * io/file_pos.c (unformatted_backspace): Assure the new file position to seek is not less than zero. (st_backspace): Set unit bytes_left to zero. * io/transfer.c (next_record_r): Fix line lengths, no functional change. From-SVN: r109405
2006-01-02re PR libgomp/25259 (bootstrap failures on non-C99 platforms (no stdint.h))Paolo Bonzini5-245/+3529
config: 2006-01-02 Paolo Bonzini <bonzini@gnu.org> PR target/25259 * stdint.m4: New. gcc: 2006-01-02 Paolo Bonzini <bonzini@gnu.org> PR target/25259 * Makefile.in (DECNUMINC): Include libdecnumber's build directory. libgfortran: 2006-01-02 Paolo Bonzini <bonzini@gnu.org> PR target/25259 * configure.ac: Use GCC_HEADER_STDINT. * libgfortran.h: Include gstdint.h. * aclocal.m4: Regenerate. * configure: Regenerate. libdecnumber: 2006-01-02 Paolo Bonzini <bonzini@gnu.org> PR target/25259 * configure.ac: Use GCC_HEADER_STDINT. * decContext.h: Include gstdint.h. * aclocal.m4: Regenerate. * configure: Regenerate. From-SVN: r109241
2006-01-01* Split the ChangeLog into years.Steven G. Kargl5-4623/+4627
From-SVN: r109225
2006-01-01re PR libfortran/25594 (LAPACK regression in schkbl.f)Jerry DeLisle2-1/+17
2005-12-31 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/25594 PR libgfortran/25419 * io/list_read.c (list_formatted_read_scalar): Test for comma to return a null value (default). Revert patch of 25419 on 2005-12-28. From-SVN: r109211
2005-12-28re PR libfortran/25139 ("Invalid argument" error on I/O)Jerry DeLisle6-4/+27
2005-12-28 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/25139 * io/unix.c (fd_truncate): Set s->active to zero. PR libgfortran/25510 * libgfortran.h: Add ERROR_INTERNAL and ERROR_INTERNAL_UNIT. * runtime/error.c (translate_error): Add messages for new errors. * io/list_read.c (next_char): Use new errors. * io/transfer.c (next_record_r) (next_record_w): Use new errors. From-SVN: r109122
2005-12-28re PR libfortran/25550 (file data corrupted after reading end of file)Jerry DeLisle2-0/+7
2005-12-28 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/25550 * io/file_pos.c (st_rewind): Reset bytes left so no error occurs in next_record_r. From-SVN: r109101
2005-12-28re PR libfortran/25419 (gfortran read does not take comma for default on one ↵Jerry DeLisle2-4/+7
entry) 2005-12-28 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/25419 * io/list_read.c (list_formatted_read_scalar): Allow comma to return a null value (default). From-SVN: r109099
2005-12-22re PR libfortran/25307 (internal read with end=label aborts)Jerry DeLisle2-13/+58
2005-12-21 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/25307 * io/list_read.c (next_char): Handle end-of-file conditions for internal units and add support for internal character array units. From-SVN: r108938
2005-12-19re PR libfortran/25463 (T edit descriptor and ADVANCE="no")Jerry DeLisle2-1/+7
2005-12-18 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/25463 * io/transfer.c (finalize_transfer): Fix execution order so that next_record is set to zero in all cases. From-SVN: r108784
2005-12-16re PR fortran/25264 (write to internal unit from the string itself gives ↵Jerry DeLisle3-13/+67
wrong result ?) 2005-12-16 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/25264 PR libgfortran/25349 * io/unit.c (get_unit): Delete code that cleared the string when the unit was opened, which is too soon. * io/transfer.c (next_record_w): Pass done flag in. Change logic for setting max_pos. Add code to position unit and pad record as needed. From-SVN: r108671
2005-12-13re PR libfortran/24991 (gfortran build fails with - error:gthr-default.h: No ↵Jakub Jelinek1-0/+17
such file or directory) PR libfortran/24991 * acinclude.m4 (LIBGFOR_CHECK_PRAGMA_WEAK): Rename to... (LIBGFOR_GTHREAD_WEAK): ... this. Define SUPPORTS_WEAK rather than HAVE_PRAGMA_WEAK. Define GTHREAD_USE_WEAK to 0 on hosts that shouldn't use weak in gthr.h. * configure.ac: Use LIBGFOR_GTHREAD_WEAK instead of LIBGFOR_CHECK_PRAGMA_WEAK. * config.h.in: Regenerated. * configure: Regenerated. * io/io.h (SUPPORTS_WEAK): Don't define here. * intrinsics/ftell.c (ftell, FTELL_SUB): Add unlock_unit call. * intrinsics/fget.c (fgetc, fputs): Likewise. * intrinsics/tty.c (ttynam): Likewise. From-SVN: r108471
2005-12-13Make-lang.in (fortran/trans-resolve.o): Depend on fortran/dependency.h.Richard Sandiford13-96/+766
gcc/fortran/ * Make-lang.in (fortran/trans-resolve.o): Depend on fortran/dependency.h. * gfortran.h (gfc_expr): Add an "inline_noncopying_intrinsic" flag. * dependency.h (gfc_get_noncopying_intrinsic_argument): Declare. (gfc_check_fncall_dependency): Change prototype. * dependency.c (gfc_get_noncopying_intrinsic_argument): New function. (gfc_check_argument_var_dependency): New function, split from gfc_check_fncall_dependency. (gfc_check_argument_dependency): New function. (gfc_check_fncall_dependency): Replace the expression parameter with separate symbol and argument list parameters. Generalize the function to handle dependencies for any type of expression, not just variables. Accept a further argument giving the intent of the expression being tested. Ignore intent(in) arguments if that expression is also intent(in). * resolve.c: Include dependency.h. (find_noncopying_intrinsics): New function. (resolve_function, resolve_call): Call it on success. * trans-array.h (gfc_conv_array_transpose): Declare. (gfc_check_fncall_dependency): Remove prototype. * trans-array.c (gfc_conv_array_transpose): New function. * trans-intrinsic.c (gfc_conv_intrinsic_function): Don't use the libcall handling if the expression is to be evaluated inline. Add a case for handling inline transpose()s. * trans-expr.c (gfc_trans_arrayfunc_assign): Adjust for the new interface provided by gfc_check_fncall_dependency. libgfortran/ * m4/matmul.m4: Use a different order in the special case of a transposed first argument. * generated/matmul_c4.c, generated/matmul_c8.c, generated/matmul_c10.c, * generated/matmul_c16.c, generated/matmul_i4.c, generated/matmul_i8.c, * generated/matmul_i10.c, generated/matmul_r4.c, generated/matmul_r8.c * generated/matmul_r10.c, generated/matmul_r16.c: Regenerated. Co-Authored-By: Victor Leikehman <LEI@il.ibm.com> From-SVN: r108459
2005-12-11Forgot ChangeLog for 108359Janne Blomqvist1-0/+7
From-SVN: r108361
2005-12-10Makefile.am: Enable loop unrolling for matmul.Janne Blomqvist4-442/+224
2005-12-10 Janne Blomqvist <jb@gcc.gnu.org> * Makefile.am: Enable loop unrolling for matmul. * configure: Regenerated. * Makefile.in: Regenerated. * aclocal.m4: Regenerated. From-SVN: r108359
2005-12-10re PR fortran/23815 (Add -byteswapio flag)Thomas Koenig6-14/+213
2005-12-10 Thomas Koenig <Thomas.Koenig@online.de> PR fortran/23815 * io.c (top level): Add convert to io_tag. (resolve_tag): convert is GFC_STD_GNU. (match_open_element): Add convert. (gfc_free_open): Likewise. (gfc_resolve_open): Likewise. (gfc_free_inquire): Likewise. (match_inquire_element): Likewise. * dump-parse-tree.c (gfc_show_code_node): Add convet for open and inquire. gfortran.h: Add convert to gfc_open and gfc_inquire. * trans-io.c (gfc_trans_open): Add convert. (gfc_trans_inquire): Likewise. * ioparm.def: Add convert to open and inquire. * gfortran.texi: Document CONVERT. 2005-12-10 Thomas Koenig <Thomas.Koenig@online.de> PR fortran/23815 * io/file_pos.c (unformatted_backspace): If flags.convert does not equal CONVERT_NATIVE, reverse the record marker. * io/open.c: Add convert_opt[]. (st_open): If no convert option is given, set CONVERT_NATIVE. If CONVERT_BIG or CONVERT_LITTLE are given, set flags.convert to CONVERT_NATIVE or CONVERT_SWAP (depending on wether we have a big- or little-endian system). * io/transfer.c (unformatted_read): Remove unused attribute from arguments. If we need to reverse bytes, break up large transfers into a loop. Split complex numbers into its two parts. (unformatted_write): Likewise. (us_read): If flags.convert does not equal CONVERT_NATIVE, reverse the record marker. (next_record_w): Likewise. (reverse_memcpy): New function. * io/inquire.c (inquire_via_unit): Implement convert. * io/io.h (top level): Add enum unit_convert. Add convert to st_parameter_open and st_parameter_inquire. Define IOPARM_OPEN_HAS_CONVERT and IOPARM_INQUIRE_HAS_CONVERT. Increase padding for st_parameter_dt. Declare reverse_memcpy(). 2005-12-10 Thomas Koenig <Thomas.Koenig@online.de> PR fortran/23815 * gfortran.dg/unf_io_convert_1.f90: New test. * gfortran.dg/unf_io_convert_2.f90: New test. * gfortran.dg/unf_io_convert_3.f90: New test. From-SVN: r108358
2005-12-09re PR libfortran/24991 (gfortran build fails with - error:gthr-default.h: No ↵Jakub Jelinek6-45/+94
such file or directory) PR libfortran/24991 * acinclude.m4: Include acx.m4 and no-executables.m4. * configure.ac: Add GCC_TOPLEVEL_SUBDIRS. * configure: Rebuilt. * Makefile.am (AM_CPPFLAGS): Use $(host_subdir) in build dir path. * Makefile.in: Rebuilt. From-SVN: r108280
2005-12-09re PR libfortran/25039 ([4.1 only] comma short-circuit field width)Jerry DeLisle4-1/+36
2005-12-08 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/25039 * io/io.h: Create a new flag sf_read_comma to control comma separators in numeric reads. * io/transfer.c (formatted_transfer_scalar): Initialize the flag. (read_sf): Check for commas coming in and if the flag is set, shortcut the read. * io/read.c (read_a) (read_x): Clear the flag for character reads and reset it after the reads. From-SVN: r108271
2005-12-04format.c: Removing unused code.Francois-Xavier Coudert3-544/+20
* io/format.c: Removing unused code. * intrinsics/random.c: Likewise. From-SVN: r108014
2005-12-02Add forgotten ChangeLog entry:Janne Blomqvist1-0/+20
2005-11-27 Janne Blomqvist <jb@gcc.gnu.org> * m4/ifunction.m4: Add const restrict to function arguments. * m4/iforeach.m4: Likewise. * m4/eoshift1.m4: Likewise. * m4/eoshift3.m4: Likewise. * m4/dotprod.m4: Likewise. * m4/dotprodc.m4: Likewise. * m4/dotprodl.m4: Likewise. * m4/shape.m4: Likewise. * m4/cshift1.m4: Likewise. * m4/reshape.m4: Likewise. * m4/transpose.m4: Likewise. * generated/eoshift*: Regenerated * generated/dotprod*: Likewise. * generated/shape*: Likewise. * generated/cshift1*: Likewise. * generated/reshape*: Likewise. * generated/transpose*: Likewise. From-SVN: r107912
2005-12-02re PR libfortran/25116 ([4.0] namelist read from non-opened file)Francois-Xavier Coudert2-1/+10
PR libfortran/25116 * io/transfer.c (data_transfer_init): Don't set the default for namelist I/O on preconnected files to UNFORMATTED. From-SVN: r107900
2005-11-30libgfortran.h (ILP32 typedefs): Define _UINT8_T, _UINT32_T and _UINT64_T on ↵Eric Botcazou2-0/+20
Solaris. * libgfortran.h (ILP32 typedefs): Define _UINT8_T, _UINT32_T and _UINT64_T on Solaris. From-SVN: r107708
2005-11-29re PR fortran/25149 (Compiler dies on -std=f95)Steven G. Kargl2-15/+16
2005-11-28 Steven G. Kargl <kargls@comcast.net> PR libgfortran/25149 * intrinsics/abort.c: Add external abort_ to allow linking when invoking -std=f95 in testsuite. From-SVN: r107655
2005-11-28acinclude.m4 (LIBGFOR_CHECK_PRAGMA_WEAK): Rename to...Jakub Jelinek6-12/+37
libfortran/24991 * acinclude.m4 (LIBGFOR_CHECK_PRAGMA_WEAK): Rename to... (LIBGFOR_GTHREAD_WEAK): ... this. Define SUPPORTS_WEAK rather than HAVE_PRAGMA_WEAK. Define GTHREAD_USE_WEAK to 0 on hosts that shouldn't use weak in gthr.h. * configure.ac: Use LIBGFOR_GTHREAD_WEAK instead of LIBGFOR_CHECK_PRAGMA_WEAK. * config.h.in: Regenerated. * configure: Regenerated. * io/io.h (SUPPORTS_WEAK): Don't define here. From-SVN: r107616
2005-11-28ftell.c (ftell, FTELL_SUB): Add unlock_unit call.Jakub Jelinek4-4/+21
* intrinsics/ftell.c (ftell, FTELL_SUB): Add unlock_unit call. * intrinsics/fget.c (fgetc, fputs): Likewise. * intrinsics/tty.c (ttynam): Likewise. From-SVN: r107595
2005-11-28re PR fortran/25109 (formatted reads with embedded blanks in input fields)Jerry DeLisle2-3/+11
2005-11-27 Jerry DeLisle <jvdelisle@gcc.gnu.org> PR libgfortran/25109 * io/unit.c (init_units): Set default flag to BLANK_NULL per requirement of F95 standard. Set PAD_YES for stdin. From-SVN: r107588
2005-11-27random.c: Include config.hDavid Edelsohn4-5/+9
* intrinsics/random.c: Include config.h * io/size_from_kind.c: Include config.h and libgfortran.h * io/io.h: Revert 2005-11-21 change. From-SVN: r107577
2005-11-27libgfortran ChangeLog:Janne Blomqvist186-1838/+2734
2005-11-27 Janne Blomqvist <jb@gcc.gnu.org> * m4/*: Add const restrict to function arguments. * generated/*.c: Regenerate. From-SVN: r107573
2005-11-27* io/write.c (namelist_write): Correct type in previous commit.Francois-Xavier Coudert2-1/+6
From-SVN: r107564
2005-11-27re PR libfortran/24919 ([4.0] CRLF support in libgfortran)Francois-Xavier Coudert6-12/+104
PR libfortran/24919 * io/list_read.c (eat_separator, finish_separator, read_character): Handle CRLF separators correctly during reads. (nml_query): Use the HAVE_CRLF macro to print adequate newlines. * io/io.h (st_parameter_dt): Add comment about the possible values for sf_seen_eor. * io/unix.c (tempfile, regular_file): HAVE_CRLF doesn't imply that O_BINARY is defined, so we add that condition. (stream_at_bof): Fix typo in comment. * io/transfer.c (read_sf): Handle correctly CRLF, setting sf_seen_eor value to 2 instead of 1. (formatted_transfer_scalar): Use the sf_seen_eor value to handle CRLF the right way. * io/write.c (nml_write_obj, namelist_write): Use CRLF as newline when HAVE_CRLF is defined. * gfortran.dg/ftell_1.f90: Modify testcase so that it doesn't fail on CRLF platforms. * gfortran.dg/ftell_2.f90: Likewise. From-SVN: r107563
2005-11-26list_read.c (nml_parse_qualifier): Use ssize_t instead of int in dtp->u.p.value.Richard Henderson2-5/+10
* io/list_read.c (nml_parse_qualifier): Use ssize_t instead of int in dtp->u.p.value. From-SVN: r107545