cddf6a9a57
Rector fixes
2023-10-21 20:44:04 +02:00
8ca610ae60
Fix
2023-10-19 11:23:24 +02:00
576e4d2bc4
Fix method calls and property accesses after extension_loaded
2023-10-19 11:16:20 +02:00
robchett
e2d1e83b87
Fix memory explosion with calls to method_exists
2023-10-17 19:15:23 +01:00
orklah
b432d812fb
Merge pull request #10274 from tuqqu/enum-case-value-type-from-class-constant
...
Fix inferring enum case value from a class constant
2023-10-16 20:25:11 +02:00
orklah
c9c3067044
Merge pull request #10279 from trusting-thompson/final-static-constant-type
...
fix final class constant type
2023-10-16 20:24:25 +02:00
Daniel Linjama
545e21b56b
fix final class constant type
2023-10-13 14:18:58 +03:00
tuqqu
d0825b5fe2
Fix for inferring enum case value from a class constant, const test fix
2023-10-13 01:15:05 +02:00
tuqqu
6039e2be9b
Fix for inferring enum case value from a class constant
2023-10-10 22:56:36 +02:00
cgocast
e0c24cbe7a
Remove unused parents_nodes
2023-10-02 15:38:01 +02:00
cgocast
6eb40e7897
Fix code style
2023-10-02 15:22:57 +02:00
cgocast
94a98ccddd
Allow tainted numerics except for 'html' and 'has_quotes'
2023-10-02 15:08:26 +02:00
orklah
2d3a625379
Merge pull request #10230 from ging-dev/lsp
...
feat(LSP): Improve the autocomplete for nested array shape
2023-09-28 23:42:02 +02:00
orklah
f57088646b
Merge pull request #10191 from boesing/bugfix/inherited-conditional-return-types
...
Resolve inherited conditional return types
2023-09-28 23:08:20 +02:00
orklah
bbcf50396d
Merge pull request #10189 from boesing/feature/inherited-assertions-v2
...
Inherited assertions v2
2023-09-28 23:07:15 +02:00
ging-dev
45807e27b8
feat(LSP): Improve the autocomplete for nested array shape
2023-09-26 01:52:23 +07:00
robchett
03e8d19eec
Only the binary op 'plus' works with two arrays
...
Treat the result of any other operation as int|float
Fixes #2123
2023-09-16 15:55:59 +01:00
Maximilian Bösing
7c8a5e8b09
bugfix: resolve recursive conditional return types containing templates
...
Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>
2023-09-11 00:04:01 +02:00
Maximilian Bösing
ad463f38e9
bugfix: always gather class templates
...
No clue why there are conditions on when templates are allowed to get picked up. I've removed this check which actually solves a problem in inherited assertions.
Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>
2023-09-10 22:17:30 +02:00
Maximilian Bösing
66c01813c1
refactor: move assertion detection based on inherited classes/interfaces into internal resolver
...
This also enables `ExistingAtomicStaticCallAnalyzer` to detect those inherited assertions.
Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>
2023-08-28 11:09:23 +02:00
Maximilian Bösing
2a0ce2fecc
qa: add newlines to prevent exceeding 120 character line-length limit
...
Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>
2023-08-28 01:15:49 +02:00
Maximilian Bösing
5e520e6bff
bugfix: properly inherit assertions from parents or implemented interfaces
...
Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>
2023-08-28 01:12:28 +02:00
Bruce Weirdan
1474340cf2
Fix crash on array access to undefined class
2023-08-20 23:45:30 +02:00
Bruce Weirdan
03f7c263fe
Correct type for $enum->name
2023-08-13 05:56:33 +02:00
Kuba Werłos
35183b9542
Add fix
2023-08-12 12:50:24 +02:00
Yannick Gottschalk
a4de6d9dc0
Fix #9997
...
- make SimpleXmlElement and SimpleXmlIterator not a universal object crate
- added typed magic __get method to SimpleXmlElement
- adjusted tests to reflect new behaviour of SimpleXmlElement
- added tests
2023-08-05 17:07:08 +02:00
Nitamet
f742af0221
Check if argument passed to isset() is valid
2023-08-01 14:39:10 +03:00
klimick
38f6d45155
Do not fill template result when arg is unpacked
2023-07-11 11:10:48 +03:00
klimick
9fccf201e3
Fix callable without params inference
2023-07-11 01:01:31 +03:00
Yannick Gottschalk
5a2f7c0a71
Use getParts() instead of $parts on PhpParser\Node\Name.
...
also use getFirst(), getLast() and getString()
2023-06-28 03:13:25 +02:00
orklah
1b571a1649
improve perfs for switch by not creating reverse assertions against constants
2023-06-19 21:24:46 +02:00
robchett
721b65ce2f
Add Type::getIntRange
2023-06-17 12:24:09 +01:00
robchett
338b50a959
Change __LINE__ to a positive-int
2023-06-17 12:24:09 +01:00
kkmuffme
fa644cbb34
code review init variables
2023-06-02 08:54:00 +02:00
kkmuffme
c17564d27c
code style and false positive shepherd
2023-06-01 01:25:46 +02:00
kkmuffme
1f2db5f31c
Allow if/false assert for same variable to allow array/list distinction
...
Fix https://github.com/vimeo/psalm/issues/9037
2023-06-01 01:08:06 +02:00
kkmuffme
25c7f37a44
add test, fix wrong test and fix shepherd
2023-05-30 16:29:47 +02:00
Jack Worman
f279c39503
GH-9825
2023-05-26 18:03:05 -04:00
Jack Worman
f41da745d1
UnsupportedPropertyReferenceUsage
2023-05-12 14:12:12 -05:00
fluffycondor
86fd504965
Allow dynamic properties from PHPDoc
2023-05-04 18:49:41 +02:00
andrew
a18eb447e0
Test match on class const fetch
2023-05-04 17:21:50 +03:00
klimick
ac8d489413
Fix ParadoxicalCondition with complex match expression
2023-05-04 11:58:39 +03:00
orklah
a5effd2d2d
Merge pull request #9681 from robchett/no-seal-methods_and_no-seal-propeties
...
Add support for @psalm-no-seal-properties and @psalm-no-seal-methods
2023-05-02 19:20:34 +02:00
orklah
4843a350a0
Merge pull request #9720 from Jean85/fix-ambiguous-constant-inheritance
...
Fix ambiguous constant inheritance false positive
2023-04-28 23:22:31 +02:00
Alessandro Lai
e8bc9a6209
Do not emit AmbiguousConstantInheritance when inheriting from the same statement
2023-04-28 22:52:22 +02:00
orklah
720f3f1dc2
Merge pull request #9704 from Nicelocal/fix_new_template_object
...
Allow running new on template objects
2023-04-24 16:29:34 +02:00
8288b00ef9
Allow running new on template objects
2023-04-24 13:08:12 +02:00
orklah
eae04f25f6
Merge pull request #9693 from Nicelocal/fix_9692
...
Fix #9692
2023-04-24 12:48:20 +02:00
orklah
41796e324a
Merge pull request #9700 from klimick/method-contextual-closure-arg-inference
...
Contextual closure arg inference for class methods
2023-04-24 12:47:38 +02:00
Evan Shaw
82090f58c5
Handle included directory paths without crashing
...
If an include or require resolves to a directory, this now raises a
MissingFile error rather than throwing an unhandled UnexpectedValueException.
2023-04-24 11:09:48 +12:00