bgzddlmZddlmZddlmZddlmZerddlm Z dd Z dd Z GddeZ ddZ dS)) annotations) TYPE_CHECKING)nodes)BaseRawFileChecker)PyLinterlinebytesreturnboolc|d}|dkrdSt||r%t|d|||dzdzSdS)zEChecks if a `# symbol that is not part of a string was found in line.#FNT)findcomment_part_of_stringis_line_commentedr comment_idxs p/builddir/build/BUILD/cloudlinux-venv-1.0.7/venv/lib/python3.11/site-packages/pylint/extensions/empty_comment.pyrrsf))D//KbudK00O l{l!3d;?;L;L6M!MNNN 4rintc*|d|ddzdkr$||dddzdksH|d|ddzdkr&||dddzdkrdSdS)z8Checks if the symbol at comment_idx is part of a string.N'r"TF)countrs rrrs \k\  &&*a//   $ $T * *Q .! 3 3 \k\  &&*a//   $ $T * *Q .! 3 3t 5rc&eZdZdZddiZdZd d Zd S) CommentChecker empty-commentR2044)zLine with empty commentrzHUsed when a # symbol appears on a line not followed by an actual commentnode nodes.Moduler Nonec@|5}t|D]_\}}|}|dr1t |dds|d|dz` ddddS#1swxYwYdS)Nr rrr)r)stream enumeraterstripendswithr add_message)selfr"r&line_numrs rprocess_modulezCommentChecker.process_module7s [[]] Mf"+F"3"3 M M${{}}==&&M,T#2#Y77M((x!|(LLL  M M M M M M M M M M M M M M M M M M MsA0BBBN)r"r#r r$)__name__ __module__ __qualname__namemsgsoptionsr-r!rrrr*sI D  DGMMMMMMrrlinterrr$cJ|t|dS)N)register_checkerr)r4s rregisterr7@s$ N62233333rN)rr r r )rr rrr r )r4rr r$) __future__rtypingrastroidrpylint.checkersr pylint.lintrrrrr7r!rrr=s #""""" ......%$$$$$$    MMMMM'MMM,444444r