The nullable field returned from SignatureTrait::getMethodSignature is used by DocBlockParamAllowDefaultValueSniff assuming that it means whether or not the parameter accepts null, so we need to also check if an explicit null is part of the typehint. This is because in the arrays returned by File::getMethodParameters, the nullable_type field only indicates if the typehint is prefixed with "?".
Fixes #368.
Checklist
[x] I agree with the Code Contribution License Agreement in CONTRIBUTING.md
The
nullable
field returned from SignatureTrait::getMethodSignature is used by DocBlockParamAllowDefaultValueSniff assuming that it means whether or not the parameter accepts null, so we need to also check if an explicit null is part of the typehint. This is because in the arrays returned by File::getMethodParameters, thenullable_type
field only indicates if the typehint is prefixed with "?".Fixes #368.
Checklist