<table role="table">
<thead>
<tr>
<th>Q</th>
<th>A</th>
</tr>
</thead>
<tbody>
<tr>
<td>Bug report?</td>
<td>yes</td>
</tr>
<tr>
<td>Feature request?</td>
<td>no</td>
</tr>
<tr>
<td>BC Break report?</td>
<td>no</td>
</tr>
<tr>
<td>RFC?</td>
<td>no</td>
</tr>
<tr>
<td>Symfony version</td>
<td>3.x</td>
</tr>
</tbody>
</table>
<p dir="auto"><strong>Description:</strong><br>
I am using the PropertyInfo component to read phpdoc comments.<br>
Somewhere we got :</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="    /**
     * Array of categories IDs
     * @var array|null
     * @SWG\Property(@SWG\Items(type=&quot;string&quot;))
     */"><pre class="notranslate"><code class="notranslate">    /**
     * Array of categories IDs
     * @var array|null
     * @SWG\Property(@SWG\Items(type="string"))
     */
</code></pre></div>
<p dir="auto">and in our code $type-&gt;isNullable() returns "false".<br>
$type is a Symfony\Component\PropertyInfo\Type instance.</p>
<p dir="auto"><strong>Fix:</strong><br>
<a href="https://github.com/symfony/symfony/blob/3.2/src/Symfony/Component/PropertyInfo/Util/PhpDocTypeHelper.php#L107">https://github.com/symfony/symfony/blob/3.2/src/Symfony/Component/PropertyInfo/Util/PhpDocTypeHelper.php#L107</a><br>
The "nullable" argument should be used here i believe ?</p>
<p dir="auto">I can provide a pull request to fix this if you agree that it is an issue (not sure if the argument is unused on purpose here ..)</p>
<table role="table">
<thead>
<tr>
<th>Q</th>
<th>A</th>
</tr>
</thead>
<tbody>
<tr>
<td>Bug report?</td>
<td>yes</td>
</tr>
<tr>
<td>Feature request?</td>
<td>no</td>
</tr>
<tr>
<td>BC Break report?</td>
<td>no</td>
</tr>
<tr>
<td>RFC?</td>
<td>no</td>
</tr>
<tr>
<td>Symfony version</td>
<td>2.8</td>
</tr>
</tbody>
</table>
<p dir="auto">PHP allows null value when using an array type hint but the <a href="https://github.com/symfony/property-info/blob/2.8/Extractor/PhpDocExtractor.php#L343">PhpDocExtractor</a> does not consider array and collections as nullable since the <a href="https://github.com/symfony/property-info/blob/2.8/Extractor/ReflectionExtractor.php#L214">ReflectionExtractor</a> does.</p>
<div class="highlight highlight-text-html-php notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="function setProperty(array $prop = null)"><pre class="notranslate"><span class="pl-k">function</span> setProperty(<span class="pl-smi">array</span> <span class="pl-s1"><span class="pl-c1">$</span>prop</span> = <span class="pl-c1">null</span>)</pre></div>