<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/138979>138979</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            [flang] Missing diagnostic on deferred length parameter being used in type-spec of an ALLOCATE statement
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            flang:frontend
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          DanielCChen
      </td>
    </tr>
</table>

<pre>
    Consider the following code:
```
implicit none
character(:), allocatable  :: char
allocate (character(:)::char)
end
```

Flang doesn't diagnose the incorrect usage of the type-spec that has deferred length parameters.
</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJx0kc2K3DAQhJ9GvjQ7yPLf-OCDMhufNuSSF2hLbVtBlozU3rBvH-wMJIQEBIJWleiqD3N2SyAaRPNJNK8FHrzGNLxicOQfj5VCMUX7MTxiyM5SAl4J5uh9_OHCAiZaEpUWUotWPo_Ubtu9M44hxEBCarNiQsOUhLqfatUL9QD0PhpknDwBnONKw6kUUj-fCIS6_8N8aS-p6oXUFOxfCwipR49hARspB6E6ButwCTHTFcAFE1Miw3BkXAjifI35Y6eXvJMBXpFhxQyWZkqJLHgKC6-wY8KNmFK-FXaobF_1WNBQdnXbNk3XlMU6lLaxNU2olLFzo2zfoqW5kn3VTV11rws3KKka2chOKdmX5a3trJFV3VftJFsqjaglbej8zfv37RbTUricDxrK6t53feFxIp8vZErNZ1BR6TnFwGcVSp0g03B6X6ZjyaKW3mXOv39jx_5C_svcvMIXl_MJ9FkTOwMx_D89THSqj0wWXPijuDgDBtBvb18f-ttnyIxMGwUujuSHlXnPF8NRqHFxvB7TzcRNqPFc7Xm97Cl-J8NCjVfqLNT4DP4-qJ8BAAD__9-r3dM">