Remove brackets from PHP statements by grandeljay · Pull Request #137447 · microsoft/vscode (original) (raw)

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 andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Conversation4 Commits3 Checks0 Files changed

Conversation

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters

[ Show hidden characters]({{ revealButtonHref }})

grandeljay

This PR changes some mentions of PHP statements which have brackets on them. It makes it looks like they are functions which they are clearly not. VS Code correctly describes them as statements. The tooltips should now reflect that too.

image

@roblourens

Sure, and I'm not a PHP expert but it seems common and idiomatic to include parens, even if they aren't required, right? Plus it seems that PHP includes them in error messages. If a require fails, I get Fatal error: require(): Failed opening required

@grandeljay

That is a very good point. I was browsing the official PHP doc and I found some arguments for my PR:

As you may know PHP is a heavily criticised programming language and often rightfully criticized. There are many quirks and inconsistencies. I'm willing to bet the error message you received (require() instead of require) is also incorrect.

roblourens

Jay Trees added 2 commits

November 23, 2021 08:10

@grandeljay

guibber pushed a commit to guibber/vscode that referenced this pull request

Nov 30, 2021

@roblourens

…rom-statements

Remove brackets from PHP statements

2 participants

@grandeljay @roblourens