https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68927
--- Comment #3 from Bill Long <longb at cray dot com> --- Possibly related to pr59796, bun not a duplicate. In this example, the pointer being deallocated is associated. The problem is that it is associated with a target that cannot be deallocated. The standard says that this is an error condition (that must be caught by STAT=) and it is not a case of the program "shall not" do this. The program is technically standard conforming.