You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Plugin should add capability to infer reduced type from Collection::reduce based on assertions in a callback, similarly as Psalm currently does for array_reduce.
Plugin should add capability to infer reduced type from
Collection::reduce
based on assertions in a callback, similarly as Psalm currently does forarray_reduce
.This is the the same as #58.
This is the current annotation: https://github.com/doctrine/collections/blob/b1f7c33ebb2d73a4860d6b65a11b9662b9904ebd/src/ReadableCollection.php#L241
For example, the following code must not raise any error:
See example: https://psalm.dev/r/80735e2f8d
The
Collections.phpstub
file must updated to reflect changes.The text was updated successfully, but these errors were encountered: