1
0
mirror of https://github.com/danog/psalm.git synced 2024-11-30 04:39:00 +01:00

added right types for BCMath functions and GMP functions (#3189)

This commit is contained in:
vladyslavstartsev 2020-04-19 15:04:11 +03:00 committed by GitHub
parent 41e6ef6455
commit d8a4030a21
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -519,11 +519,11 @@ return [
'bbcode_parse' => ['string', 'bbcode_container'=>'resource', 'to_parse'=>'string'],
'bbcode_set_arg_parser' => ['bool', 'bbcode_container'=>'resource', 'bbcode_arg_parser'=>'resource'],
'bbcode_set_flags' => ['bool', 'bbcode_container'=>'resource', 'flags'=>'int', 'mode='=>'int'],
'bcadd' => ['string', 'left_operand'=>'string', 'right_operand'=>'string', 'scale='=>'int'],
'bccomp' => ['int', 'left_operand'=>'string', 'right_operand'=>'string', 'scale='=>'int'],
'bcdiv' => ['?string', 'left_operand'=>'string', 'right_operand'=>'string', 'scale='=>'int'],
'bcmod' => ['?string', 'left_operand'=>'string', 'right_operand'=>'string', 'scale='=>'int'],
'bcmul' => ['string', 'left_operand'=>'string', 'right_operand'=>'string', 'scale='=>'int'],
'bcadd' => ['numeric-string', 'left_operand'=>'numeric-string', 'right_operand'=>'numeric-string', 'scale='=>'int'],
'bccomp' => ['int', 'left_operand'=>'numeric-string', 'right_operand'=>'numeric-string', 'scale='=>'int'],
'bcdiv' => ['?numeric-string', 'left_operand'=>'numeric-string', 'right_operand'=>'numeric-string', 'scale='=>'int'],
'bcmod' => ['?numeric-string', 'left_operand'=>'numeric-string', 'right_operand'=>'numeric-string', 'scale='=>'int'],
'bcmul' => ['numeric-string', 'left_operand'=>'numeric-string', 'right_operand'=>'numeric-string', 'scale='=>'int'],
'bcompiler_load' => ['bool', 'filename'=>'string'],
'bcompiler_load_exe' => ['bool', 'filename'=>'string'],
'bcompiler_parse_class' => ['bool', 'class'=>'string', 'callback'=>'string'],
@ -537,11 +537,11 @@ return [
'bcompiler_write_functions_from_file' => ['bool', 'filehandle'=>'resource', 'filename'=>'string'],
'bcompiler_write_header' => ['bool', 'filehandle'=>'resource', 'write_ver='=>'string'],
'bcompiler_write_included_filename' => ['bool', 'filehandle'=>'resource', 'filename'=>'string'],
'bcpow' => ['string', 'base'=>'string', 'exponent'=>'string', 'scale='=>'int'],
'bcpowmod' => ['?string', 'base'=>'string', 'exponent'=>'string', 'modulus'=>'string', 'scale='=>'int'],
'bcpow' => ['numeric-string', 'base'=>'numeric-string', 'exponent'=>'numeric-string', 'scale='=>'int'],
'bcpowmod' => ['?numeric-string', 'base'=>'numeric-string', 'exponent'=>'numeric-string', 'modulus'=>'numeric-string', 'scale='=>'int'],
'bcscale' => ['int', 'scale='=>'int'],
'bcsqrt' => ['string', 'operand'=>'string', 'scale='=>'int'],
'bcsub' => ['string', 'left_operand'=>'string', 'right_operand'=>'string', 'scale='=>'int'],
'bcsqrt' => ['?numeric-string', 'operand'=>'numeric-string', 'scale='=>'int'],
'bcsub' => ['numeric-string', 'left_operand'=>'numeric-string', 'right_operand'=>'numeric-string', 'scale='=>'int'],
'bin2hex' => ['string', 'data'=>'string'],
'bind_textdomain_codeset' => ['string', 'domain'=>'string', 'codeset'=>'string'],
'bindec' => ['int|float', 'binary_number'=>'string'],
@ -3885,7 +3885,7 @@ return [
'gmdate' => ['string|false', 'format'=>'string', 'timestamp='=>'int'],
'gmmktime' => ['int|false', 'hour='=>'int', 'min='=>'int', 'sec='=>'int', 'mon='=>'int', 'day='=>'int', 'year='=>'int'],
'GMP::__construct' => ['void'],
'GMP::__toString' => ['string'],
'GMP::__toString' => ['numeric-string'],
'GMP::serialize' => ['string'],
'GMP::unserialize' => ['void', 'serialized'=>'string'],
'gmp_abs' => ['GMP', 'a'=>'GMP|string|int'],
@ -3935,8 +3935,8 @@ return [
'gmp_setbit' => ['void', 'a'=>'GMP|string|int', 'index'=>'int', 'set_clear='=>'bool'],
'gmp_sign' => ['int', 'a'=>'GMP|string|int'],
'gmp_sqrt' => ['GMP', 'a'=>'GMP|string|int'],
'gmp_sqrtrem' => ['array', 'a'=>'GMP|string|int'],
'gmp_strval' => ['string', 'gmpnumber'=>'GMP|string|int', 'base='=>'int'],
'gmp_sqrtrem' => ['array{0: GMP, 1: GMP}', 'a'=>'GMP|string|int'],
'gmp_strval' => ['numeric-string', 'gmpnumber'=>'GMP|string|int', 'base='=>'int'],
'gmp_sub' => ['GMP', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],
'gmp_testbit' => ['bool', 'a'=>'GMP|string|int', 'index'=>'int'],
'gmp_xor' => ['GMP', 'a'=>'GMP|string|int', 'b'=>'GMP|string|int'],