1
0
mirror of https://github.com/danog/psalm.git synced 2024-12-11 08:49:52 +01:00
psalm/tests/fixtures/stubs/polyfill.phpstub

24 lines
367 B
Plaintext
Raw Normal View History

<?php
2019-03-23 19:27:54 +01:00
if (!function_exists('random_bytes')) {
/**
* @param int $bytes
2019-03-23 19:27:54 +01:00
*
* @return void
*/
function random_bytes($bytes)
{
2019-03-23 19:27:54 +01:00
throw new \Exception('bad');
}
}
2019-03-23 19:27:54 +01:00
if (!function_exists('new_random_bytes')) {
/**
* @param int $bytes
2019-03-23 19:27:54 +01:00
*
*/
function new_random_bytes($bytes): int
{
return 5;
}
}