Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added parsing and checking functions docblocks #302

Merged
merged 1 commit into from
Oct 27, 2022

Conversation

AlessandroMinoccheri
Copy link
Member

This should fix this issue #301
Is it a BC?

@codecov-commenter
Copy link

codecov-commenter commented Oct 18, 2022

Codecov Report

Merging #302 (92bf76a) into main (66b5f5e) will increase coverage by 0.18%.
The diff coverage is 100.00%.

@@             Coverage Diff              @@
##               main     #302      +/-   ##
============================================
+ Coverage     95.87%   96.06%   +0.18%     
- Complexity      397      399       +2     
============================================
  Files            59       59              
  Lines          1091     1092       +1     
============================================
+ Hits           1046     1049       +3     
+ Misses           45       43       -2     
Impacted Files Coverage Δ
src/Analyzer/ClassDescription.php 96.96% <100.00%> (+0.04%) ⬆️
src/Analyzer/ClassDescriptionBuilder.php 94.82% <100.00%> (ø)
src/Analyzer/FileVisitor.php 84.52% <100.00%> (+2.38%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Copy link
Contributor

@micheleorselli micheleorselli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Noice! Left a minor, non blocking comment

@@ -133,6 +127,12 @@ public function enterNode(Node $node): void
);
}

if (null !== $this->classDescriptionBuilder && null !== $node->getDocComment()) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we need the null check on $this->classDescriptionBuilder? I find it a bit confusing, as we are already using $this->classDescriptionBuilder a few lines above without any check

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have got different errors without this check

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not sure I got what you mean but just out of curiosity: doesn't the check on line 28 prevent from having a null in $this->classDescriptionBuilder here?

And just to be super clear: all good from me, feel free to merge it

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The check on line 28 is inside an if that finish before the new check, this check is more generic

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a little bit confusing, if tou want to split this method this could be a great refactoring... but if you prefer we can work on it on another PR.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

split the if @fain182 ? What is confusing in this part?

Copy link
Collaborator

@fain182 fain182 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@AlessandroMinoccheri AlessandroMinoccheri merged commit eb3fbab into main Oct 27, 2022
@AlessandroMinoccheri AlessandroMinoccheri deleted the parse-functions-docblocks branch October 27, 2022 19:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants