Bug 45417

Summary: DEALLOCATE: No error when deallocating a target
Product: gcc Reporter: Tobias Burnus <burnus>
Component: fortranAssignee: Not yet assigned to anyone <unassigned>
Status: NEW ---    
Severity: normal CC: gcc-bugs
Priority: P3 Keywords: wrong-code
Version: 4.6.0   
Target Milestone: ---   
Host: Target:
Build: Known to work:
Known to fail: Last reconfirmed: 2013-06-29 00:00:00
Bug Depends on: 37577    
Bug Blocks:    

Description Tobias Burnus 2010-08-26 13:13:35 UTC
See thread starting at http://j3-fortran.org/pipermail/j3/2010-August/003747.html

The first example is valid (state == 0), the second valid (state /= 0), and the third one is invalid.

gfortran produces, http://j3-fortran.org/pipermail/j3/2010-August/003753.html, 0 <crash> <crash>.

Expected: The second example produces state /= 0.


Variant (works, should be state == 0):
  http://j3-fortran.org/pipermail/j3/2010-August/003754.html

The problem is that our array descriptor does not save whether a variable has been allocated or just associated with a named target. For the TR descriptor, mentioned in the last link, cf. http://j3-fortran.org/pipermail/interop-tr/2010-August/000163.html
Comment 1 Dominique d'Humieres 2013-06-29 15:27:30 UTC
Still present at revision 200557.