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

Fix the formatting for the textual operators(AND, OR, XOR) #4635 #4741

Merged

Conversation

junichi11
Copy link
Member

#4635

  • WHITESPACE_BEFORE_BINARY_OP and WHITESPACE_AFTER_BINARY_OP are added to && and ||
  • There is the problem if we add them to AND, OR, and XOR
  • See: https://bz.apache.org/netbeans/show_bug.cgi?id=240274
  • e.g. if they are false, copy($old,$new) or die("error"); -> copy($old,$new) ordie("error");
  • Instead, add WHITESPACE_AROUND_TEXTUAL_OP as a new token

@junichi11 junichi11 added the PHP [ci] enable extra PHP tests (php/php.editor) label Oct 6, 2022
@junichi11 junichi11 added this to the NB16 milestone Oct 6, 2022
@junichi11 junichi11 linked an issue Oct 6, 2022 that may be closed by this pull request
@junichi11 junichi11 changed the title Fix the formatting for the textual operators(AND, OR, XORi) #4635 Fix the formatting for the textual operators(AND, OR, XOR) #4635 Oct 6, 2022
…he#4635

- `WHITESPACE_BEFORE_BINARY_OP` and `WHITESPACE_AFTER_BINARY_OP` are added to `&&` and `||`
- There is the problem if we add them to `AND`, `OR`, and `XOR`
- See: https://bz.apache.org/netbeans/show_bug.cgi?id=240274
- e.g. if they are false, `copy($old,$new) or die("error");` -> `copy($old,$new) ordie("error");`
- Instead, add `WHITESPACE_AROUND_TEXTUAL_OP` as a new token
@junichi11 junichi11 force-pushed the gh-4635-formatting-for-textual-operators branch from 5266d21 to 2dc1907 Compare October 6, 2022 15:13
@junichi11 junichi11 requested a review from tmysik October 6, 2022 22:02
@junichi11
Copy link
Member Author

@tmysik Could you please have a look at this when you have time? If there is no problem, let's merge it. Thanks!

@tmysik tmysik merged commit cafc4bb into apache:master Oct 7, 2022
@junichi11 junichi11 deleted the gh-4635-formatting-for-textual-operators branch October 7, 2022 23:30
@junichi11
Copy link
Member Author

@tmysik Thank you for your review!

@tmysik
Copy link
Member

tmysik commented Oct 8, 2022

@junichi11 Sure, whenever :)

@junichi11 junichi11 added the hacktoberfest-accepted Hacktoberfest label Oct 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
hacktoberfest-accepted Hacktoberfest PHP [ci] enable extra PHP tests (php/php.editor)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

PHP Formatting: No space between 'AND !$var'.
2 participants