1
0
mirror of https://github.com/danog/psalm.git synced 2024-12-11 16:59:45 +01:00
Commit Graph

69 Commits

Author SHA1 Message Date
Vincent
3c3e692e7e AtomicStaticCallAnalyzer: clear tmp var from context (fix #7556) 2022-02-02 13:51:54 +01:00
Vincent
280de4bc98 Fix undefined parent method call (ref #7414) 2022-01-24 09:17:29 +01:00
Vincent Quatrevieux
c7bfc03a6b
Merge branch '4.x' into call-docblock-method-using-parent 2022-01-20 08:59:50 +01:00
Vincent
7b25ca75f4 Resolve generics of inherited pseudo methods (fix #7419) 2022-01-19 11:45:19 +01:00
Vincent
09fc43a4d8 Add support of docblock method using parent keyword (fix #7411) 2022-01-17 19:26:42 +01:00
Vincent
a52362465b Handle inherited docblock method (fix #7198) 2022-01-14 10:30:09 +01:00
rarila
97e6511fab Set number of lines before and after namespace. 2021-12-15 04:58:32 +01:00
rarila
39402c233d
Return type hints (#7065)
Co-authored-by: ralila <>
2021-12-05 19:51:26 +02:00
ralila
8fb2e0f885 Handle some partials 2021-12-04 21:55:53 +01:00
ralila
711be643c6 Import instead of using fqn exceptions 2021-12-03 20:29:06 +01:00
Semyon
28385dc526 Fix failed test 2021-10-14 18:00:32 +03:00
ElisDN
61b78e117f Fix negative numbers 2021-07-08 19:17:31 +03:00
Bruce Weirdan
6abce3525a
Enforce use sort (#5900) 2021-06-07 22:55:21 -04:00
Jean-Nicolas
30f64b79de
Checks the intersection type if the magic method does not exist (#5473) 2021-03-24 15:34:05 -04:00
AndrolGenhald
d4590711d6
Fix object-like array keys when combining string and automatic keys (fixes #5427). (#5428)
* Fix object-like array keys (fixes #5427).

* Fix incorrect return types for tests.

* Fix false positive list with literal int key.
2021-03-19 21:44:44 -04:00
Fran Moreno
fcd9dcb9b5
Allow by reference parameters in method docblock (#4873) 2020-12-21 17:11:34 +00:00
orklah
ead107fa9e
More return types (#4173)
* add native return types

* redundant phpdoc
2020-09-12 11:24:05 -04:00
Brown
cf5aa5c5cd Fix #4083 - namespace docblock method classes the proper way 2020-08-29 11:46:24 -04:00
Bruce Weirdan
4dcb7183f5
Fix windows tests (#4040)
* Fix windows tests by not mangling the expectations

* Use platform-dependent directory separator in expected messages

* fix CS
2020-08-22 10:00:36 -04:00
Brown
45d9ab12e1 Fix #4017 - allow float defaults in namespaced classes 2020-08-18 12:13:27 -04:00
Brown
c0b0036109 Fix #3934 - prevent unsafe use of new static 2020-08-05 19:39:27 -04:00
Brown
4c368da75e Fix #3721 - prevent crash on empty @method 2020-07-01 09:00:33 -04:00
Brown
2c5c9e95e1 Don’t add two @return docblocks after @method 2020-06-20 15:30:47 -04:00
Brown
edbeec2c6a Fix @method annotation namespacing 2020-06-20 15:18:22 -04:00
Olle Härstedt
e1cc27f7a2
Add new config: sealAllMethods (#3578)
* Add new config: sealAllMethods

* Add some more tests

* Fix codesniffer issue with preg_quote

* Fix missing method in test

Co-authored-by: Olle <noemail>
2020-06-15 22:36:42 -04:00
Brown
16189782ab Inherit whether methods are sealed from parent
Ref #3561
2020-06-11 11:28:41 -04:00
orklah
1621a9f3ea
Add checks for duplicated params and returns (#3487) 2020-05-30 16:54:16 -04:00
Brown
d8cd30b34a Fix #3340 - catch more errors in @method type parsing 2020-05-11 18:39:07 -04:00
Brown
65b4263315 Fix #3320 - add final flag to pseudo methods where appropriate 2020-05-08 07:28:12 -04:00
Brown
13d9354cde Fix #3107 - prevent bad @method with dash 2020-04-09 12:16:58 -04:00
Matthew Brown
950260a041 No erroneous UndefinedMethod when accessing sealed class 2020-03-11 18:27:07 -04:00
Brown
f1dbd0863a Allow magic methods named "as"
Fixes #2881
2020-02-26 13:50:45 -05:00
Matthew Brown
d0b87b6cb0 Fix #2723 - use magic method return type where necessary 2020-02-01 18:21:32 -05:00
Brown
03030d4887 Fix #2583 - don’t convert scalar terms in @method annotations 2020-01-10 11:29:18 -05:00
Brown
083fbc55e1 Add more specific UndefinedMagicMethod issue 2020-01-06 14:23:33 -05:00
Matthew Brown
b6d5021251 Fix line number 2020-01-03 08:50:27 -05:00
Matthew Brown
df33405635 Seal properties and methods whenever @method/@property is used 2020-01-03 08:44:52 -05:00
Matthew Brown
8c1638efc5 Fix tests once more 2019-12-20 19:37:36 +00:00
Matthew Brown
3d03da271d Fix tests to give more accurate locations 2019-12-20 18:18:26 +00:00
Brown
e564d67214 Add support for simple default arrays in @method docblocks
Fixes #2455
2019-12-11 11:29:00 -05:00
lhchavez
216f991b0c Normalize stringified type names (#2239)
This change makes stringified types more normalized. Concretely it sorts
all union types, reconciled types, and sorts the keys within object-like
types.
2019-10-17 01:14:33 -04:00
Matthew Brown
b61d0c6dcd Fix #2104 - only treat @method returns as separate if attached to method name 2019-09-07 22:30:09 -04:00
Brown
071fae98b2 Fix #2095 - respect @method annotations even when method already exists 2019-09-04 09:42:12 -04:00
Brown
bdac01582d Fix #1989 - support fully-qualified params in @method annotations 2019-08-08 17:25:56 -04:00
Brown
7d05568e22 Add skipped test for broken stubbing behaviour
Ref #1935
2019-07-11 12:51:43 -04:00
Matthew Brown
da42be175f Apply PHPCS fixes
Fixes #1880
2019-07-05 16:27:53 -04:00
Matthew Brown
422d9944d8 Fix #1903 - inherit @method from parent interfaces 2019-07-04 22:39:28 -04:00
LeSuisse
f29826b958 Fully qualify constants and function calls (#1849)
This should give a small performance boost.
Part of #1837.

The change is enforced via phpcs and can be autofixed
with phpcbf.
2019-06-26 16:52:29 -04:00
Matthew Brown
c356c452ec Fix #1692 - allow magic annotations on all interfaces without config flag 2019-05-26 23:35:03 -04:00
Brown
0bd4dbcbc4 Bump to PHP 7.1
Fixes #1650
2019-05-16 18:36:36 -04:00