This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: [PATCH, libfortran] PR 48587 Newunit allocator
- From: Dominique d'Humières <dominiq at lps dot ens dot fr>
- To: blomqvist dot janne at gmail dot com
- Cc: fortran at gcc dot gnu dot org, gcc-patches List <gcc-patches at gcc dot gnu dot org>
- Date: Thu, 13 Oct 2016 22:59:58 +0200
- Subject: Re: [PATCH, libfortran] PR 48587 Newunit allocator
- Authentication-results: sourceware.org; auth=none
With the patch, the following code
integer :: i, j
i = -10
write(unit=i,fmt=*, iostat=j) 10
print *, j
end
fails at run time with
Assertion failed: (ind >= 0 && ind < newunit_size), function newunit_free, file ../../../work/libgfortran/io/unit.c, line 966.
Without the patch the output is 5002.
TIA
Dominique