mirror of
https://github.com/danog/psalm.git
synced 2024-11-26 20:34:47 +01:00
Fix #998 - use lowercase comparison for method signature checks
This commit is contained in:
parent
3187b5723d
commit
350afe3e7f
@ -633,10 +633,11 @@ class MethodChecker extends FunctionLikeChecker
|
||||
&& (
|
||||
!$implemeneter_param_type
|
||||
|| (
|
||||
$implemeneter_param_type->getId() !== $guide_param->type->getId()
|
||||
strtolower($implemeneter_param_type->getId()) !== strtolower($guide_param->type->getId())
|
||||
&& (
|
||||
!$or_null_guide_type
|
||||
|| $implemeneter_param_type->getId() !== $or_null_guide_type->getId()
|
||||
|| strtolower($implemeneter_param_type->getId())
|
||||
!== strtolower($or_null_guide_type->getId())
|
||||
)
|
||||
)
|
||||
)
|
||||
|
@ -288,6 +288,35 @@ class MethodSignatureTest extends TestCase
|
||||
use T;
|
||||
}',
|
||||
],
|
||||
'inheritsSplClasses' => [
|
||||
'<?php
|
||||
namespace App;
|
||||
|
||||
use SplObserver;
|
||||
use SplSubject;
|
||||
|
||||
class Observer implements \SplObserver
|
||||
{
|
||||
public function update(SplSubject $subject)
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
class Subject implements \SplSubject
|
||||
{
|
||||
public function attach(SplObserver $observer)
|
||||
{
|
||||
}
|
||||
|
||||
public function detach(SplObserver $observer)
|
||||
{
|
||||
}
|
||||
|
||||
public function notify()
|
||||
{
|
||||
}
|
||||
}',
|
||||
],
|
||||
];
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user