Ecosyste.ms: OpenCollective
An open API service for software projects hosted on Open Collective.
github.com/PHPCSStandards/PHPCSUtils
A suite of utility functions for use with PHP_CodeSniffer
https://github.com/PHPCSStandards/PHPCSUtils
Collections: new nameTokens() method
f9c3588bce7c72b827873c4e00ccb66188ceff0d authored over 4 years ago by Juliette <[email protected]>... containing the tokens used for "names", be it namespace, OO, function or constant names.
In...
96bc79bea8b1f6c5817cfa223328f92401824284 authored over 4 years ago by jrfnl <[email protected]>Collections: deprecate $OONameTokens in favour of namespacedNameTokens()
e01c1708a9ec3f6c28703c068883cff724b1d874 authored over 4 years ago by Juliette <[email protected]>BCFile/GetTokensAsString/GetTokensAsStringTest: make tests independent of PHP 8 identifier names
1ba8c9e7f598e7e53e6a8a010e1787ba5354ec90 authored over 4 years ago by Juliette <[email protected]>Related to 201
As the token counts for identifier names are different between PHP < 8 and PHP 8...
aad1710d38438b62e44df24496e3d836ff9249fd authored over 4 years ago by jrfnl <[email protected]>Deprecate the `$OONameTokens` property in favour of a new `Collections::namespacedNameTokens()` ...
13f368c865fdb475cec79c0f9d1764b4db360d15 authored over 4 years ago by jrfnl <[email protected]>PHP 8.0 | Tests: set up to work with PHP 8.0 identifier name tokens
452bf6b3e409d39e248d409a9e541a83c9b61f53 authored over 4 years ago by Juliette <[email protected]>This adjusts the tests for various utilities to take the different token positions, when PHP 8.0...
40a0fe718b04bd52ed118a2a017aebd51d1e7735 authored over 4 years ago by jrfnl <[email protected]>Add a toggle to retrieve the right token based on the expected tokenization for a test.
12d512cd048c02e2f116d1252ad0981a3356bb59 authored over 4 years ago by jrfnl <[email protected]>When the PHP 8 identifier name tokenization is used, the `T_NAMESPACE` token for the `namespace`...
26b54d2e54f9af353a588a5fb6dbc5b350075934 authored over 4 years ago by jrfnl <[email protected]>Add a toggle to retrieve the right token based on the expected tokenization for a test.
de30d98afa3af2c7cb5fa0f8b22ceb40b3a2a039 authored over 4 years ago by jrfnl <[email protected]>UtilityMethodTestCase: new `usesPhp8NameTokens()` method
ae73a764f02c39d045c5ba0eafda60af91f8803c authored over 4 years ago by Juliette <[email protected]>In PHP 8.0 identifier name tokenization will change as outline in the [accepted RFC "Treat names...
c32f10d064ef4cebf6a0454e3d6997d32ae94280 authored over 4 years ago by jrfnl <[email protected]>Operators::isTypeUnion(): BC-fix - namespace operator in return type
be015eaecf545306d0318e3bec894470b270d8e4 authored over 4 years ago by Juliette <[email protected]>The `Operators::isTypeUnion()` method is subseptible to the Tokenizer bug which will be fixed in...
7f72bc6f6fe9a79625d1e963768fbf94b199d28d authored over 4 years ago by jrfnl <[email protected]>BCFile::isReference(): sync with upstream
783953f79bc5bb801512e86260e3d476a3d0048f authored over 4 years ago by Juliette <[email protected]>Minor code simplification as pulled in upstream PR 3105 and merged in PHPCS 3.5.7.
9876b54a841719c9ba1ac6f98950d81ffe9e4ff6 authored over 4 years ago by jrfnl <[email protected]>Operators::isUnaryPlusMinus(): bug fix - unary after arrow in arrow function
70ea51d17aef7c35168f681df4df8f10857464c3 authored over 4 years ago by Juliette <[email protected]>Just like after the `return` keyword, a plus/minus after the `=>` arrow in an arrow function is ...
d3535ebbce3a3c8efebd94bf0a4708cc884f382e authored over 4 years ago by jrfnl <[email protected]>UseStatements: new `mergeImportUseStatements()` method
a9e6ce59e31eeae0b82690dce4325baff894a76b authored over 4 years ago by Juliette <[email protected]>This splits the "merge" functionality off from the `UseStatements::splitAndMergeImportUseStateme...
7264b96f99f8cf3933bccffe47d7c1758732d594 authored over 4 years ago by jrfnl <[email protected]>PHPCS 4.x | Initial updates to handle T_USE becoming a parentheses owner
87ca29d84b9f5f269ae021bb3cb5f60e9c28826d authored over 4 years ago by Juliette <[email protected]>`T_USE` tokens used for closure use statements are parentheses openers as of PHPCS 4.x.
This in...
214811882e3d48bdeb7fb63a1cc15eea8891670d authored over 4 years ago by jrfnl <[email protected]>`T_USE` tokens used for closure use statements are parentheses owners as of PHPCS 4.x.
This mak...
9d7b3c24c7905e7252d510c14664ff76ee48b4e6 authored over 4 years ago by jrfnl <[email protected]>BCTokens\UnchangedTokenArraysTest: update PHPUnit properties list
e8da419aceb960e191f506a50306a3a2357e404a authored over 4 years ago by Juliette <[email protected]>... for new properties introduced in PHPUnit 9.3.x.
511a88be160c74782b9b1fd4272ad18b33dda39d authored over 4 years ago by jrfnl <[email protected]>BCTokens: test arrays against PHPCS upstream
d4556fc6a61306b425079f398bff851fca13eaae authored over 4 years ago by Juliette <[email protected]>This adds tests for all backfilled token arrays in the `BCTokens` class to verify whether they a...
23bc69c72b004a83beda452607b99ed9d7ca8ddd authored over 4 years ago by jrfnl <[email protected]>Operators::isReference(): bug fix - arrow function params passed by reference
e012cce8ddf73d63ff7f0e22206e0c0286f03666 authored over 4 years ago by Juliette <[email protected]>The bitwise and `&` for parameters passed by reference in an arrow function declaration were inc...
0587e5aea1fc9170454ee4e862686699a2f00056 authored over 4 years ago by jrfnl <[email protected]>Parentheses: improve handling of arrow functions returning by reference
1065c1b872fe70b0ecbaeef3a46b33631e67be2b authored over 4 years ago by Juliette <[email protected]>Includes unit tests.
14005167888748c248038ac8797d718b9398cd0c authored over 4 years ago by jrfnl <[email protected]>Operators::isReference(): remove some redundant code
48d881e54e4cfda69b1ccf11aa6318f9043de985 authored over 4 years ago by Juliette <[email protected]>The "closure use by reference" check only skipped over whitespace, not comments, but in effect, ...
d8c067bc66d5f7eccb2250a562c25f6673c00468 authored over 4 years ago by jrfnl <[email protected]>IsReferenceDiffTest: fix class name
3220fbdbda3ff160361c4569121a4f5e1226f466 authored over 4 years ago by Juliette <[email protected]>894739c08f7348352a51a80102c40fa6ed2f9215 authored over 4 years ago by jrfnl <[email protected]>
Operators::isReference(): bug fix - parameters passed by reference
97c42e935faf57529e18021ba8470c4c4f54825a authored over 4 years ago by Juliette <[email protected]>Somewhere down the line, the key used to look up whether a parameter was passed by reference got...
bca4c3889e4bb7d52ab8c0bb387248598fda9b2b authored over 4 years ago by jrfnl <[email protected]>Operators::isUnaryPlusMinus(): allow for exit, break, continue
a3a060a01ea0123d75cb234ffe07f50727decad3 authored over 4 years ago by Juliette <[email protected]>... as indicators that a plus/minus is unary when preceded by it.
Includes unit tests.
Inspire...
2f3e1db4bb15182ec726771dd1d751f891bd4ca7 authored over 4 years ago by jrfnl <[email protected]>Travis/Composer: future-proof the CS setup a little more
504aded78f4402e06021659347b880460b3034f1 authored over 4 years ago by Juliette <[email protected]>
* Composer: add branch aliases
* Travis: move CS install steps to the `Sniff` stage.
See PHPCom...
0c76615cf51a5c7c899e2ef1ce51d7703234b0a8 authored over 4 years ago by jrfnl <[email protected]>QA/CS: update PHPCSDevCS
210eed9c74358edda63a8e4e07c48471f1611639 authored over 4 years ago by Juliette <[email protected]>The new `1.1.x` version already includes a check for short array syntax, so we can remove that f...
95e8b7b23e0083fc8c576d9b726fd0254cc5c0a5 authored over 4 years ago by jrfnl <[email protected]>Travis: retry composer install on failure
33cab96734ca1699e58e1e954e175ea64e5426ec authored over 4 years ago by Juliette <[email protected]>
The builds are failing a little too often for my taste on the below error.
```
[Composer\Downloa...
Feature/nullsafe operator sync with phpcs
62601fe3bffa2e278612804ad71d797e490b9e19 authored over 4 years ago by Juliette <[email protected]>PHPCS has backfilled the PHP 8.0 `T_NULLSAFE_OBJECT_OPERATOR` token. This backfill will be inclu...
32ab208a4647f179df24fd3455bbcf3455cd7896 authored over 4 years ago by jrfnl <[email protected]>PHPCS has backfilled the PHP 8.0 `T_NULLSAFE_OBJECT_OPERATOR` token. This backfill will be inclu...
58fe69e2022737b063fe8461fd34836c12e34fc8 authored over 4 years ago by jrfnl <[email protected]>Testcase files: fix some unintentional parse errors.
d3e3773a31c77e3d22b687605b012590495b2860 authored over 4 years ago by Juliette <[email protected]>ObjectDeclarations::findNames(): allow for use of namespace keyword as operator
c3e05c11ba7e8e17dd5b8792744bfbc2934fbb7a authored over 4 years ago by Juliette <[email protected]>d9142797b6bf649217712394fa3aecac11a39d55 authored over 4 years ago by jrfnl <[email protected]>
So far, using the `namespace` keyword as an operator was not accounted for. This has now been fi...
a005585ad0b090a4c4e387ce315467a922f87c59 authored over 4 years ago by jrfnl <[email protected]>Support namespace operator in type declarations
4d227900437e193f13aacf6bf359f2e209f9aa60 authored over 4 years ago by Juliette <[email protected]>The commit which added support for the namespace keyword used as an operator to the `Collections...
0941b32b5b8264f0019c47a282e2503e1157c163 authored over 4 years ago by jrfnl <[email protected]>This commit adds support for the namespace keyword used as an operator to the `FunctionDeclarati...
cef0e13f836370a6643bab374b05a5ae1fef45bb authored over 4 years ago by jrfnl <[email protected]>The commit which added support for the namespace keyword used as an operator to the `Collections...
1c607b62b7934339f7c1b97c0eb5deb9daa63369 authored over 4 years ago by jrfnl <[email protected]>The commit which added namespace operator support to the `Collections::returnTypeTokens[BC]()` m...
3af8caccc4baaee1b20c8e1750caa1a754fbd407 authored over 4 years ago by jrfnl <[email protected]>This adds support for the namespace keyword used as an operator in property, parameter and retur...
b32bb33f7edcec6b9d01ed367e2ba2850df26fb8 authored over 4 years ago by jrfnl <[email protected]>GetMemberPropertiesDiffTest: use named data provider entries
8b23ad71f66d9af51330cce070b13e3f9bfd2cc3 authored over 4 years ago by Juliette <[email protected]>4d8c59469747bdc4227635641b82e51067ae68ee authored over 4 years ago by jrfnl <[email protected]>
BCFile::findEndOfStatement(): sync with upstream
ed4bd99a2d13028eef84c3037aa75f768a0a1059 authored over 4 years ago by Juliette <[email protected]>
Refs:
* squizlabs/PHP_CodeSniffer 2883
* https://github.com/squizlabs/PHP_CodeSniffer/commit/437...
CI: fix coverage builds failing
56435d8ff0ad86e9d1c561508ebb8d57b410d34c authored over 4 years ago by Juliette <[email protected]>The code coverage builds on PHP 7.3/7.4 started to fail without clear reason recently.
It has n...
456372c332b477c955b9ffde2dbbfc277053b2ee authored over 4 years ago by jrfnl <[email protected]>PHP 8.0 | Add utilities to handle the nullsafe object operator
52530d777aca019a4ce4eb035cd589f370dbb667 authored over 4 years ago by Juliette <[email protected]>... and add a unit test using the nullsafe object operator.
No additional code is needed for th...
0ec9ce60397b0056ace5cfbfc40b03c0b70c8b9c authored over 4 years ago by jrfnl <[email protected]>... which emulates the backfill as pulled to PHPCS itself.
PHP 8 introduces a new object chaini...
50fc1d1c98773a2099e69e1f41dcfba991d08a4e authored over 4 years ago by jrfnl <[email protected]>... to retrieve the tokens which can represent the nullsafe object operator.
This method will r...
c816e8e84655aa0597ad77fc36503753aabaa5e1 authored over 4 years ago by jrfnl <[email protected]>Sister-method to the `objectOperators()` method, which returns the tokens which can be encounter...
6bd63b3f1dc9cc7ca7c05c497d40fa1df51fa809 authored over 4 years ago by jrfnl <[email protected]>Includes adjusted unit test.
0a7f073404d4e6bc5ede8b7325a06be177c4a53b authored over 4 years ago by jrfnl <[email protected]>Deprecate the `$objectOperators` property in favour of a new `Collections::objectOperators()` me...
e1aeec1eb2d7e988e3ece90becb4bed3406b6d0d authored over 4 years ago by jrfnl <[email protected]>Travis: require PHPUnit 9.3 for PHP 8
fc492419e1819797e549dd199ebdf3c352d3d55b authored over 4 years ago by Juliette <[email protected]>PHPUnit 9.3 is not yet released (expected end of August), but is slated to add official PHP 8 su...
bb0a449f5e5a69b52221e96937ae4c08e1a8297a authored over 4 years ago by jrfnl <[email protected]>Travis: run "nightly" only against PHPCS dev-master
8a62a0e752c8afa11301312de8c60e8a5119ce4b authored over 4 years ago by Juliette <[email protected]>... as testing against older PHPCS version will fail by default because of the removed curly bra...
5cac6ee33116e1ce30f36bc94c12c7c373fb8286 authored over 4 years ago by jrfnl <[email protected]>Travis: change from "trusty" to "xenial"
f8740f458573682e946d1f714e1a059e67833a57 authored over 4 years ago by Juliette <[email protected]>As the "trusty" environment is no longer officially supported by Travis, they decided in their w...
43a18a41ca1094e4278ff75405b837049209b10f authored over 4 years ago by jrfnl <[email protected]>BCTokens: add `magicConstants()` method
a647d9d0ece94aeee13f2b3bd37fa714fdd4e099 authored over 4 years ago by Juliette <[email protected]>Arrays::isShortArray(): update version numbers for upstream merge tokenizer fix
989a14742d5c4a7ecc8f015ff5c8d89e3641c002 authored over 4 years ago by Juliette <[email protected]>Upstream PR 3013 introduces a new `$magicConstants` tokens array to PHPCS, same as already exist...
97275835cb059f6f04a2f65a4a6880296771c2eb authored over 4 years ago by jrfnl <[email protected]>Upstream PR 3013 has been merged and will be released as part of PHPCS 3.x.x.
This updates the ...
729e2a25e220b56566c5343c5081644459147a32 authored over 4 years ago by jrfnl <[email protected]>Operators: new `isTypeUnion()` method
58a4cdc58b3b926224abb52a7e9067eda82968b3 authored over 4 years ago by Juliette <[email protected]>... to distinguish between a `T_BITWISE_OR` token used as "bitwise or" and the same token when i...
3d044e514af2d4fbce1ccaa5b1b4a7e5055ab6b6 authored over 4 years ago by jrfnl <[email protected]>PHP 8.0 | FunctionDeclarations::getParameters(): add support for constructor property promotion
ea5c5ac277f096231655c2ec036e87098493b737 authored over 4 years ago by Juliette <[email protected]>PHP 8.0 | Add support for union types
4d02dd84435c878467d6ed514c8e0a4dc9e46b62 authored over 4 years ago by Juliette <[email protected]>This commit adds support for constructor property promotion to the `FunctionDeclarations::getPar...
a6297d9da60767e831f6ebb1c44084c6abef900e authored over 4 years ago by jrfnl <[email protected]>38ad2b050c8ebf4f6402d269e72d6d8a484be8e1 authored over 4 years ago by jrfnl <[email protected]>
Adds tests, same as wil be pulled upstream, to the tests for the `FunctionDeclarations::isArrowF...
6b3bbef5a8a051cdf635dc6a2dac566cabdba7c9 authored over 4 years ago by jrfnl <[email protected]>The commit which added union type support to the `Collections::propertyTypeTokens[BC]()` methods...
d00a5b7312fb54f6d9f21f25bd366ec55146cea4 authored over 4 years ago by jrfnl <[email protected]>The commit which added union type support to the `Collections::returnTypeTokens[BC]()` methods i...
6584ce46606b0ec6a19e00bfea247f31847e4e52 authored over 4 years ago by jrfnl <[email protected]>
This commit adds support for union types to the `FunctionDeclarations::getParameters()` method.
...
In addition to the other tokens needed to support union types, the `returnTypeTokens[BC]()` meth...
9158cc7c36aa9a30ecd23ae191693988a94cb2ff authored over 4 years ago by jrfnl <[email protected]>Deprecate the `$returnTypeTokens` property in favour of a new `Collections::returnTypeTokens()` ...
311a2d5ba2ddad7b0b9770595bdfd9cf223331de authored over 4 years ago by jrfnl <[email protected]>Includes adjusted unit test.
27d5bedc9c84d851a7f12857f6cf2bacea51f7d0 authored over 4 years ago by jrfnl <[email protected]>Deprecate the `$propertyTypeTokens` property in favour of a new `Collections::propertyTypeTokens...
b3f7e68d757fc2b7c61cb5ee6976f31c2a49febc authored over 4 years ago by jrfnl <[email protected]>Includes adjusted unit test.
ea706342b06a219d0c3a7415eb97c7f76a4e6260 authored over 4 years ago by jrfnl <[email protected]>Deprecate the `$parameterTypeTokens` property in favour of a new `Collections::parameterTypeToke...
8fa856b60418c6c4b03f823a5addd3f9022f34aa authored over 4 years ago by jrfnl <[email protected]>2302d6998ff0014081acab96281cc20e6f579c7b authored over 4 years ago by jrfnl <[email protected]>
FunctionDeclarations::isArrowFunction(): add test with PHP 8 "static" return type
568b6c99958ed0811bb1902296c55986348163aa authored over 4 years ago by Juliette <[email protected]>