Skip to content

Exception when analysing file with unterminated comment #130

Closed
@hadomskyi

Description

@hadomskyi
Q A
Bug report? yes
Feature request? no
Library version 1.3.1

This error appears while analyzing

Fatal error: Uncaught TypeError: Return value of SlevomatCodingStandard\Sniffs\Commenting\EmptyCommentSniff::getCommentContent() must be of the type string, bool returned in /phpinsights/vendor/slevomat/coding-standard/SlevomatCodingStandard/Sniffs/Commenting/EmptyCommentSniff.php:153 Stack trace: #0 /phpinsights/vendor/slevomat/coding-standard/SlevomatCodingStandard/Sniffs/Commenting/EmptyCommentSniff.php(48): SlevomatCodingStandard\Sniffs\Commenting\EmptyCommentSniff->getCommentContent(Object(NunoMaduro\PhpInsights\Domain\File), 20, -1) #1 /phpinsights/src/Domain/File.php(128): SlevomatCodingStandard\Sniffs\Commenting\EmptyCommentSniff->process(Object(NunoMaduro\PhpInsights\Domain\File), 20) #2 /phpinsights/src/Domain/File.php(171): NunoMaduro\PhpInsights\Domain\File->process() #3 /phpinsights/src/Domain/FileProcessor.php(79): NunoMaduro\PhpInsights\Domain\File->processWithTokenListenersAndFileInfo(Array, Object(Symplify\PackageBuilder\FileSystem\SmartFileInfo)) #4 /phpinsights/vendor/symplify/easy-coding-standard/src/A in /phpinsights/vendor/slevomat/coding-standard/SlevomatCodingStandard/Sniffs/Commenting/EmptyCommentSniff.php on line 153

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions