<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/58178>58178</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[Flang][OpenMP] Unexpected error: name in DEALLOCATE statement must have the ALLOCATABLE or POINTER attribute
</td>
</tr>
<tr>
<th>Labels</th>
<td>
openmp,
flang:frontend
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
sscalpone
</td>
</tr>
</table>
<pre>
omp_dealloc.f90
```
subroutine s
implicit none
double precision,allocatable,dimension(:) :: r
!$omp parallel private(r)
allocate(r(1))
deallocate(r)
!$omp end parallel
end subroutine
```
```
% flang -c omp_dealloc.f90
% flang -c -fopenmp omp_dealloc.f90
./omp_dealloc.f90:6:20: error: name in DEALLOCATE statement must have the ALLOCATABLE or POINTER attribute
deallocate(r)
^
```
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJy1U0uPmzAQ_jXmYgWBiXkcOLCbRKqUdlfV9lwZPARXxka2idp_34FNmyZK1VMtwN88mMfncWvlj9qO01cJQmvbxX2VkGRHkubyzZPLs4oUl59bZ-egDFB_1S5LjZNWnQrUWAO3JmnnVgOdHHTKK2sIe17ziSBQj5JUI5h3S0myhrCKLlvWUHcbibCUsC2WTCfhMAZojKrOImCU0uF_t-6XLBdjmS4O9z6X3v8W4poRjPyd9eqzaK-kPOTtXmSc9lqYE9109DH7f3psejuBwfwPXWPCDveGrMnxZQug4Jx1CzBiBKoM3e2b4_HluXnbUx-waSQ-0HH2gQ7iDDQMQC8OzdNxT62jry8fPr3tP1MRglPtHO4O958M3izC93ekRFCnec6TjBcli2SdySqrRBRU0FAT_nRYiCB8h_AFifj4iph-MfB9gi6A_C8dRrPT9RDC5NdpPOBzUmGY27izIwpan39tm8nZb1gJisr7GTwCXqZFGQ11xTJAnEuQnciLpM_5VlYpajNRCrmNtGhB-6VLwtj7MSPAC4Fjx9YJwPy9sybgmC0WvotUzRLG0iTJE85zxuI2gzwreNUXkouuyMg2gVEoHS_lxdadIlevlbbzyaNRKx_81Si8VycDK9dLfDGHwbra-07oCa9ytLZVrz39BKEsOik">