1
0
mirror of https://github.com/danog/psalm.git synced 2024-12-11 08:49:52 +01:00
Commit Graph

54 Commits

Author SHA1 Message Date
Fran Moreno
7ddec46e76
Allow by reference parameters in method docblock (#4873) 2021-01-29 11:47:22 +01:00
orklah
db45ff1ba4
More return types (#4173)
* add native return types

* redundant phpdoc
2021-01-29 11:38:57 +01:00
Brown
e5e50926d4
Fix #4083 - namespace docblock method classes the proper way 2021-01-29 11:38:48 +01:00
Bruce Weirdan
1cc4715740
Fix windows tests (#4040)
* Fix windows tests by not mangling the expectations

* Use platform-dependent directory separator in expected messages

* fix CS
2021-01-29 11:38:04 +01:00
Brown
7ac771da48
Fix #4017 - allow float defaults in namespaced classes 2021-01-29 11:37:59 +01: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
Brown
30cbcb6c36 Add ImplementedParamTypeMismatch issue
Fixes #1633
2019-05-14 15:44:46 -04:00
Matthew Brown
c772914910 Add some formatting 2019-03-23 14:27:54 -04:00
Matthew Brown
136429dfd4 Fix location of @method docblocks for issues 2019-03-18 21:05:37 -04:00
Matthew Brown
3b616eb850 Remove bad test
Fixes #1426
2019-03-07 09:27:34 -05:00
Brown
ea149339f4 Skip broken test for now 2019-03-06 18:32:29 -05:00
Bruce Weirdan
9bdc9f774f More provider typing 2019-03-02 08:43:19 -05:00
Brown
601f303de2 Fix position of invalid param 2019-02-27 16:00:44 -05:00
bugreportuser
51493b552a Add @psalm-property and @psalm-method override tests 2019-02-23 11:04:08 -05:00
bugreportuser
68a135f434 Allow @psalm-property and @psalm-method 2019-02-23 11:04:08 -05:00
SignpostMarv
4a56688800 adding DIRECTORY_SEPARATOR to tests that fail under windows 2019-02-06 14:29:10 -05:00
Brown
e060ec35de Fix #1258 - allow static method returns 2019-01-30 11:44:12 -05:00
Matthew Brown
bfb2a5c19e Fix #1257 - transform docblock types for magic methods to something more meaningful 2019-01-30 09:46:23 -05:00
Matthew Brown
eddaaea01b Add support for static @method annotations 2019-01-18 11:37:52 -05:00
Matthew Brown
9d8c2792e2 Add array-key type and improve general type handling
Fixes #1144
2019-01-05 00:15:53 -05:00
Brown
9e4765663d Fix #999 - respect @method annotations to redefine parent methods 2018-11-30 15:13:25 -05:00