forked from diablomedia/zf1
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathphpstan-bootstrap.php
More file actions
105 lines (82 loc) · 3.37 KB
/
phpstan-bootstrap.php
File metadata and controls
105 lines (82 loc) · 3.37 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
<?php
// The Zend_Service_WindowsAzure_CommandLine classes try to bootstrap the Zend_Service_Console_Command
// component when the classes are loaded (bottom of file), which phpstan will trigger when it
// autoloads the classes. This prevents it from bootstrapping (which prevents some exceptions being thrown)
define('MICROSOFT_CONSOLE_COMMAND_HOST', 'nobootstrap');
// Use stubs so we can analyze types from unloaded extensions
if (!extension_loaded('apc')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/apc/apc.php';
}
if (!extension_loaded('gmp')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/gmp/gmp.php';
}
if (!extension_loaded('ibm_db2')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/ibm_db2/ibm_db2.php';
}
if (!extension_loaded('igbinary')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/igbinary/igbinary.php';
}
if (!extension_loaded('intl')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/intl/intl.php';
}
if (!extension_loaded('mcrypt')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/mcrypt/mcrypt.php';
}
if (!extension_loaded('memcache')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/memcache/memcache.php';
}
if (!extension_loaded('memcached')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/memcached/memcached.php';
}
if (!extension_loaded('hash')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/hash/hash.php';
}
// The hash extension may emulate the mhash extension if PHP is configured with --with-mhash
// otherwise the mhash* functions/constants won't exist
if (!function_exists('mhash')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/mhash/mhash.php';
}
if (!extension_loaded('mysql')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/mysql/mysql.php';
}
if (!extension_loaded('oci8')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/oci8/oci8.php';
}
if (!extension_loaded('openssl')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/openssl/openssl.php';
} else {
// Only defined when php/openssl compiled with MD2 support
if (!defined('OPENSSL_ALGO_MD2')) {
define('OPENSSL_ALGO_MD2', 4);
}
}
if (!extension_loaded('rar')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/rar/rar.php';
}
if (!extension_loaded('sqlite')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/SQLite/SQLite.php';
}
if (!extension_loaded('sqlsrv')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/sqlsrv/sqlsrv.php';
}
if (!extension_loaded('ssh2')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/ssh2/ssh2.php';
}
if (!extension_loaded('wincache')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/wincache/wincache.php';
}
if (!extension_loaded('tidy')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/tidy/tidy.php';
}
if (!extension_loaded('xcache')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/xcache/xcache.php';
}
if (!extension_loaded('jobqueue_client')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/zend/zend.php';
}
if (!extension_loaded('wddx')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/wddx/wddx.php';
}
if (!extension_loaded('zendcache')) {
require_once __DIR__ . '/vendor/jetbrains/phpstorm-stubs/ZendCache/ZendCache.php';
}