1
0
mirror of https://github.com/danog/psalm.git synced 2024-11-26 12:24:49 +01:00

Remove Amp stubs

This commit is contained in:
Brown 2020-04-12 11:47:10 -04:00
parent 370ffa28e4
commit 95ec189e0b
2 changed files with 0 additions and 66 deletions

View File

@ -40,10 +40,6 @@
<class name="LogicException"/>
</ignoreExceptions>
<stubs>
<file name="src/Psalm/Internal/Stubs/Amp.php"/>
</stubs>
<plugins>
<plugin filename="examples/plugins/FunctionCasingChecker.php"/>
<pluginClass class="Psalm\PhpUnitPlugin\Plugin"/>

View File

@ -1,62 +0,0 @@
<?php
namespace Amp;
/**
* @template TReturn
*
* @param callable():\Generator<mixed, mixed, mixed, TReturn> $gen
*
* @return callable():Promise<TReturn>
*/
function coroutine(callable $gen) : callable
{
}
/**
* @template TReturn
*
* @param callable():(\Generator<mixed, mixed, mixed, TReturn>|TReturn) $gen
*
* @return Promise<TReturn>
*/
function call(callable $gen) : Promise
{
}
/**
* @template TReturn
* @psalm-yield TReturn
*/
interface Promise
{
/**
* @param callable(?\Throwable, ?TReturn):void $onResolved
*
* @return void
*/
public function onResolve(callable $onResolved);
}
/**
* @template TReturn
*
* @template-implements Promise<TReturn>
*/
class Success implements Promise
{
/**
* @param TReturn|null $value
*/
public function __construct($value = null)
{
}
/**
* @param callable(?Throwable, ?TReturn):void $onResolved
*
* @return void
*/
public function onResolve(callable $onResolved)
{
}
}