Go to file
Lars Moelleken 0829a62533 add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
.github/workflows GithubActions: Add Qodana 2020-12-15 20:22:21 +03:00
.idea fix some more phpdocs 2020-12-14 12:15:52 +03:00
Core update stubs according to reflection 2020-12-18 14:05:02 +01:00
Ev improve some more phpdocs 2020-12-14 12:15:52 +03:00
FFI Add FFI::isNull(CData $ptr): bool 2020-12-14 12:34:51 +03:00
LuaSandbox Update LuaSandbox PECL library (#900) 2020-09-26 10:22:13 +03:00
PDO add tests for class constants and class constant values. Update stubs 2020-12-15 16:13:05 +03:00
Parle Phpdotnet docs validation (#947) 2020-11-03 17:06:54 +03:00
Phar "ArrayShape" -> add more types 2020-12-14 12:15:52 +03:00
Reflection update stubs according to reflection 2020-12-18 14:05:02 +01:00
SPL update stubs according to reflection 2020-12-18 14:05:02 +01:00
SQLite optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
SaxonC more phpdoc fixes 2020-12-14 12:15:52 +03:00
SimpleXML "SimpleXMLElement" -> will return static 2020-12-14 12:15:52 +03:00
SplType Use https for @link annotations (#367) 2018-08-13 14:15:36 +03:00
Zend OPcache Provide PHP 8 return types to function signatures 2020-11-18 17:06:05 +01:00
ZendCache use "&" for references 2020-08-23 01:03:37 +02:00
ZendDebugger WI-33237 split embedded stubs into modules 2017-03-07 14:52:15 +01:00
ZendUtils WI-33237 split embedded stubs into modules 2017-03-07 14:52:15 +01:00
aerospike add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
amqp improve some more phpdocs 2020-12-14 12:15:52 +03:00
apache Annotate apache functions with #[Pure] 2020-10-20 19:40:06 +02:00
apcu fix some more phpdocs 2020-12-14 12:15:52 +03:00
bcmath update stubs according to reflection 2020-12-18 14:05:02 +01:00
blackfire Add stubs for BlackfireProbe (#764) 2020-03-30 17:36:48 +03:00
bz2 more phpdoc fixes 2020-12-14 12:15:52 +03:00
calendar Add proper nullability 2020-11-19 13:20:31 +01:00
cassandra improve some more phpdocs 2020-12-14 12:15:52 +03:00
com_dotnet Phpdotnet docs validation (#947) 2020-11-03 17:06:54 +03:00
couchbase more phpdoc fixes 2020-12-14 12:15:52 +03:00
crypto use "&" for references 2020-08-23 01:03:37 +02:00
ctype Provide PHP 8 return types to function signatures 2020-11-18 17:06:05 +01:00
cubrid Phpdotnet docs validation (#947) 2020-11-03 17:06:54 +03:00
curl optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
date add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
dba Provide PHP 8 return types to function signatures 2020-11-18 17:06:05 +01:00
decimal improve some more phpdocs 2020-12-14 12:15:52 +03:00
dio improve some more phpdocs 2020-12-14 12:15:52 +03:00
dom update stubs according to reflection 2020-12-18 14:05:02 +01:00
ds optimize "checkHtmlTags"-check 2020-12-14 12:15:52 +03:00
enchant improve some more phpdocs 2020-12-14 12:15:52 +03:00
event add some more "ArrayShape" + phpdoc fixes 2020-12-14 12:15:52 +03:00
exif Add proper nullability 2020-11-19 13:20:31 +01:00
expect improve some more phpdocs 2020-12-14 12:15:52 +03:00
fann add some more "ArrayShape" + phpdoc fixes 2020-12-14 12:15:52 +03:00
ffmpeg Fix undefined class inspection 2020-06-08 16:34:00 +02:00
fileinfo more phpdoc fixes 2020-12-14 12:15:52 +03:00
filter more phpdoc fixes 2020-12-14 12:15:52 +03:00
fpm improve some more phpdocs 2020-12-14 12:15:52 +03:00
ftp fix some more broken html tags 2020-12-14 12:15:52 +03:00
gd add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
gearman Phpdotnet docs validation (#947) 2020-11-03 17:06:54 +03:00
geoip fix some more phpdocs 2020-12-14 12:15:52 +03:00
geos Revert "Cleanup and rules for PHPCS" 2020-06-12 14:02:01 +03:00
gettext Add proper nullability 2020-11-19 13:20:31 +01:00
gmagick Annotate gmagick methods with #[Pure] 2020-11-02 09:53:44 +01:00
gmp add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
gnupg use "&" for references 2020-08-23 01:03:37 +02:00
grpc add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
hash optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
http optimize "checkHtmlTags"-check 2020-12-14 12:15:52 +03:00
ibm_db2 optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
iconv optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
igbinary add more type fixes 2020-12-21 17:43:34 +03:00
imagick optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
imap add more type fixes 2020-12-21 17:43:34 +03:00
inotify optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
interbase optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
intl add more type fixes 2020-12-21 17:43:34 +03:00
json more phpdoc fixes 2020-12-14 12:15:52 +03:00
judy Phpdotnet docs validation (#947) 2020-11-03 17:06:54 +03:00
ldap add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
leveldb improve some more phpdocs 2020-12-14 12:15:52 +03:00
libevent Remove whitespaces from stubs. 2020-05-13 21:13:07 +03:00
libsodium improve some more phpdocs 2020-12-14 12:15:52 +03:00
libxml Add proper nullability 2020-11-19 13:20:31 +01:00
lua more phpdoc fixes 2020-12-14 12:15:52 +03:00
lzf Added pecl LZF 2019-12-22 18:12:48 +03:00
mailparse optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
mapscript add more type fixes 2020-12-21 17:43:34 +03:00
mbstring add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
mcrypt fix "&Alias;" usage 2020-12-14 12:15:52 +03:00
memcache optimize "checkHtmlTags"-check 2020-12-14 12:15:52 +03:00
memcached #[Pure] for Exception (and children) methods 2020-10-29 09:15:23 +03:00
meminfo Add ext-meminfo stub 2019-05-15 19:23:38 +02:00
meta WI-37000 array_merge type is the union of all passed arguments types 2020-11-26 09:17:25 +03:00
ming Phpdotnet docs validation (#947) 2020-11-03 17:06:54 +03:00
mongo optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
mongodb improve some more phpdocs 2020-12-14 12:15:52 +03:00
mosquitto-php fix some more phpdocs 2020-12-14 12:15:52 +03:00
mqseries use "&" for references 2020-08-23 01:03:37 +02:00
msgpack add some pecl extensions + update stubs 2020-12-15 18:38:31 +03:00
mssql fix some more broken html tags 2020-12-14 12:15:52 +03:00
mysql fix some more broken html tags 2020-12-14 12:15:52 +03:00
mysql_xdevapi more phpdoc fixes 2020-12-14 12:15:52 +03:00
mysqli optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
ncurses optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
newrelic fix some more phpdocs 2020-12-14 12:15:52 +03:00
oauth improve some more phpdocs 2020-12-14 12:15:52 +03:00
oci8 optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
odbc optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
openssl optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
parallel add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
pcntl optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
pcov add some pecl extensions + update stubs 2020-12-15 18:38:31 +03:00
pcre more phpdoc fixes 2020-12-14 12:15:52 +03:00
pdflib Phpdotnet docs validation (#947) 2020-11-03 17:06:54 +03:00
pdo_ibm WI-33237 split embedded stubs into modules 2017-03-07 14:52:15 +01:00
pdo_mysql WI-33237 split embedded stubs into modules 2017-03-07 14:52:15 +01:00
pdo_pgsql WI-33237 split embedded stubs into modules 2017-03-07 14:52:15 +01:00
pdo_sqlite WI-33237 split embedded stubs into modules 2017-03-07 14:52:15 +01:00
pgsql fix: update pg_last_notice php doc 2020-12-14 12:17:03 +03:00
phpdbg Add stubs for sapi/phpdbg functions 2020-05-13 21:20:22 +03:00
posix more phpdoc fixes 2020-12-14 12:15:52 +03:00
pq optimize "checkHtmlTags"-check 2020-12-14 12:15:52 +03:00
pspell optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
pthreads improve some more phpdocs 2020-12-14 12:15:52 +03:00
radius add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
rar improve some more phpdocs 2020-12-14 12:15:52 +03:00
rdkafka fix annotation 2020-12-18 15:05:48 +03:00
readline Add proper nullability 2020-11-19 13:20:31 +01:00
recode Cleanup @since tags with old versions <5.3 2020-01-22 18:26:13 +01:00
redis optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
regex improve some more phpdocs 2020-12-14 12:15:52 +03:00
rpminfo improve some more phpdocs 2020-12-14 12:15:52 +03:00
rrd add some pecl extensions + update stubs 2020-12-15 18:38:31 +03:00
session Properly test parameter names in interfaces 2020-12-15 16:13:05 +03:00
shmop optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
snmp optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
soap Rename parameter names of methods for PHP 8 2020-11-20 12:44:12 +01:00
sockets add more type fixes 2020-12-21 17:43:34 +03:00
sodium add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
solr optimize "checkHtmlTags"-check 2020-12-14 12:15:52 +03:00
sqlite3 update stubs according to reflection 2020-12-18 14:05:02 +01:00
sqlsrv add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
ssh2 improve some more phpdocs 2020-12-14 12:15:52 +03:00
standard add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
stats use "&" for references 2020-08-23 01:03:37 +02:00
stomp improve some more phpdocs 2020-12-14 12:15:52 +03:00
suhosin Remove whitespaces from stubs. 2020-05-13 21:13:07 +03:00
superglobals improve some more phpdocs 2020-12-14 12:15:52 +03:00
svm improve some more phpdocs 2020-12-14 12:15:52 +03:00
svn fix some more broken html tags 2020-12-14 12:15:52 +03:00
sybase Merge branch 'master' into phpdoc_fixes 2020-09-01 09:45:30 +03:00
sync lowercase keywords null/true/false 2020-06-18 21:20:10 +03:00
sysvmsg fix some more broken html tags 2020-12-14 12:15:52 +03:00
sysvsem Add proper imports 2020-11-18 17:11:37 +01:00
sysvshm Add proper nullability 2020-11-19 13:20:31 +01:00
tests Improve assertions 2020-12-20 23:29:28 +03:00
tidy fix some more phpdocs 2020-12-14 12:15:52 +03:00
tokenizer Provide PHP 8 return types to function signatures 2020-11-18 17:06:05 +01:00
uopz Phpdotnet docs validation (#947) 2020-11-03 17:06:54 +03:00
uuid add / fix some phpdocs 2020-08-16 01:14:11 +02:00
uv improve some more phpdocs 2020-12-14 12:15:52 +03:00
v8js add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
wddx [+]: review "..." usage 2020-09-01 01:06:24 +02:00
win32service Fix `false on error` returns 2020-08-07 17:53:35 +10:00
winbinder Revert "Cleanup and rules for PHPCS" 2020-06-12 14:02:01 +03:00
wincache fix some more phpdocs 2020-12-14 12:15:52 +03:00
xcache add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
xdebug update xdebug stubs according to reflection 2020-12-19 20:08:33 +03:00
xhprof Phpdotnet docs validation (#947) 2020-11-03 17:06:54 +03:00
xlswriter add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
xml optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
xmlreader more phpdoc fixes 2020-12-14 12:15:52 +03:00
xmlrpc optimize "checkHtmlTags"-check + fix html tags 2020-12-14 12:15:52 +03:00
xmlwriter add more type fixes 2020-12-21 17:43:34 +03:00
xsl Fix parameter type 2020-11-13 14:26:06 +01:00
xxtea Stubs for PECL XXTEA 2019-11-06 15:01:57 +03:00
yaf add more type fixes 2020-12-21 17:43:34 +03:00
yaml add some pecl extensions + update stubs 2020-12-15 18:38:31 +03:00
yar add more type fixes + fix phpdoc syntax 2020-12-21 17:43:34 +03:00
zend add more type fixes 2020-12-21 17:43:34 +03:00
zip optimize "checkHtmlTags"-check 2020-12-14 12:15:52 +03:00
zlib fix some more broken html tags 2020-12-14 12:15:52 +03:00
zmq fix "&Alias;" usage 2020-12-14 12:15:52 +03:00
zookeeper add more type fixes 2020-12-21 17:43:34 +03:00
.gitignore Add php-cs-fixer 2020-05-28 18:12:43 +03:00
.php_cs lowercase keywords null/true/false 2020-06-18 21:20:10 +03:00
CONTRIBUTING.md update to php8 beta4 (#908) 2020-09-18 20:03:34 +03:00
Dockerfile add some pecl extensions + update stubs 2020-12-15 18:38:31 +03:00
PhpStormStubsMap.php update xdebug stubs according to reflection 2020-12-19 20:08:33 +03:00
README.md remove travis 2020-12-17 11:30:52 +01:00
composer.json update composer.json 2020-12-17 18:22:39 +03:00
docker-compose.yml Add composer to Dockerfile (#862) 2020-07-09 18:49:53 +03:00
generate-stub-map rdkafka stub fixes, use recurse for generator 2020-08-18 14:22:39 +02:00

README.md

phpstorm-stubs

official JetBrains project GitHub Action Status License Total Downloads

STUBS are normal, syntactically correct PHP files that contain function & class signatures, constant definitions, etc. for all built-in PHP stuff and most standard extensions. Stubs need to include complete PHPDOC, especially proper @return annotations.

An IDE needs them for completion, code inspection, type inference, doc popups, etc. Quality of most of these services depend on the quality of the stubs (basically their PHPDOC @annotations).

Note that the stubs for “non-standard” extensions are provided as is. (Non-Standard extensions are the ones that are not part of PHP Core or are not Bundled/External - see the complete list here.)

The support for such “non-standard” stubs is community-driven, and we only validate their PHPDoc. We do not check whether a stub matches the actual extension or whether the provided descriptions are correct.

Relevant open issues

Contribution process

Contribution process

Updating the IDE

Have a full copy of the .git repo within an IDE and provide its path in Settings | Languages & Frameworks | PHP | PHP Runtime | Advanced settings | Default stubs path. It should then be easily updatable both ways via normal git methods.

Extensions enabled by default

The set of extensions enabled by default in PhpStorm can change anytime without prior notice. To learn how to view the enabled extensions, look here.

How to run tests

  1. Execute docker-compose -f docker-compose.yml run php composer install -d /opt/project/phpstorm-stubs --ignore-platform-reqs
  2. Execute docker-compose -f docker-compose.yml run php /opt/project/phpstorm-stubs/vendor/bin/phpunit /opt/project/phpstorm-stubs/tests/

How to update stub map

Execute docker-compose -f docker-compose.yml run php /usr/local/bin/php /opt/project/phpstorm-stubs/generate-stub-map and commit the resulting PhpStormStubsMap.php

License

Apache 2

contains material by the PHP Documentation Group, licensed with CC-BY 3.0