-
-
Notifications
You must be signed in to change notification settings - Fork 490
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
Documentation Class Instantiation #1801
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems to cover all the violations in the sniff.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@FORTE-WP Hi Frank, thank you for this PR! Looking good.
I've left some minor, mostly grammatical, remarks inline.
Other than that, I also noticed there is trailing whitespace after the description in each of the <standard>
blocks.
Aside from that, all looks good.
</code_comparison> | ||
<standard> | ||
<![CDATA[ | ||
Don't use spaces between object name and open parenthesis when instantiating new object. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't use spaces between object name and open parenthesis when instantiating new object. | |
Don't use spaces between the object name and the open parenthesis when instantiating new object. |
]]> | ||
</standard> | ||
<code_comparison> | ||
<code title="Valid: no spaces between object name and parenthesis."> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<code title="Valid: no spaces between object name and parenthesis."> | |
<code title="Valid: no whitespace between the object name and the parenthesis."> |
$a = new Foobar(); | ||
]]> | ||
</code> | ||
<code title="Invalid: spaces between object name and parenthesis."> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<code title="Invalid: spaces between object name and parenthesis."> | |
<code title="Invalid: a space between the object name and the parenthesis."> |
<code_comparison> | ||
<code title="Valid: object instantiation without reference."> | ||
<![CDATA[ | ||
$a = new Foobar(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
$a = new Foobar(); | |
$a = <em>new</em> Foobar(); |
</code> | ||
<code title="Invalid: object instantiation by reference."> | ||
<![CDATA[ | ||
$a = <em>&</em> new Foobar(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
$a = <em>&</em> new Foobar(); | |
$a = <em>& new</em> Foobar(); |
I just processed all feedback from jrfnl in a new commit. |
Thank you @FORTE-WP for making those changes! |
Related to #1722