Skip to content

Instantly share code, notes, and snippets.

View KalleZ's full-sized avatar
🐟
Something fishy?

Kalle Sommer Nielsen KalleZ

🐟
Something fishy?
View GitHub Profile
<?php
class A
{
}
function test_1(A[] $a)
{
/* ... */
}
js/search.js | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/js/search.js b/js/search.js
index 74764b2..391cb5c 100644
--- a/js/search.js
+++ b/js/search.js
@@ -11,7 +11,13 @@ $('input.search').autocomplete({
minChars:2,
maxHeight:400,
diff --git a/ext/date/php_date.c b/ext/date/php_date.c
index 68235c4..8a17859 100644
--- a/ext/date/php_date.c
+++ b/ext/date/php_date.c
@@ -1,4 +1,4 @@
-/*
+/*
+----------------------------------------------------------------------+
| PHP Version 7 |
+----------------------------------------------------------------------+
Number of tests : 76 70
Tests skipped : 6 ( 7.9%) --------
Tests warned : 0 ( 0.0%) ( 0.0%)
Tests failed : 9 ( 11.8%) ( 12.9%)
Expected fail : 0 ( 0.0%) ( 0.0%)
Tests passed : 61 ( 80.3%) ( 87.1%)
<?php
class Nokia3310
{
protected static $keypad = [
2 => ['a', 'b', 'c'],
3 => ['d', 'e', 'f'],
4 => ['g', 'h', 'i'],
5 => ['j', 'k', 'l'],
6 => ['m', 'n', 'o'],
7 => ['p', 'q', 'r', 's'],
<?php
/* ... */
protected static getRemoteIP() : string
{
if(isset($_SERVER['HTTP_X_FORWARDED_FOR']) && $_SERVER['HTTP_X_FORWARDED_FOR'])
{
return($_SERVER['HTTP_X_FORWARDED_FOR']);
}
elseif(isset($_SERVER['REMOTE_ADDR']) && $_SERVER['REMOTE_ADDR'])
<?php
foreach([false, 0.1, 'hello', [], new stdClass, new SoapFault('a', 'b')] as $value)
{
var_dump(is_soap_fault($value) === ($value instanceof SoapFault));
}
?>
ext\gd\libgd\gd_crop.c(246): warning C4018: '>=': signed/unsigned mismatch
ext\gd\libgd\gd.c(1083): warning C4244: '=': conversion from 'double' to 'int', possible loss of data
ext\gd\libgd\gd.c(1147): warning C4244: '=': conversion from 'double' to 'int', possible loss of data
ext\gd\libgd\gd.c(1331): warning C4244: '=': conversion from 'double' to 'int', possible loss of data
ext\gd\libgd\gd.c(1381): warning C4244: '=': conversion from 'double' to 'int', possible loss of data
ext\gd\libgd\gd.c(2756): warning C4244: '=': conversion from 'double' to 'int', possible loss of data
ext\gd\libgd\gd_interpolation.c(2167): warning C4018: '>=': signed/unsigned mismatch
ext\gd\libgd\gd_interpolation.c(2169): warning C4018: '>=': signed/unsigned mismatch
ext\gd\libgd\gd_webp.c(153): warning C4244: 'function': conversion from 'int' to 'float', possible loss of data
ext\gd\libgd\gdft.c(640): warning C4018: '<': signed/unsigned mismatch
diff --git a/main/output.c b/main/output.c
index 3eb6ddc..6fd1d78 100644
--- a/main/output.c
+++ b/main/output.c
@@ -1514,17 +1514,21 @@ PHP_FUNCTION(ob_get_status)
}
/* }}} */
-/* {{{ proto void ob_implicit_flush([int flag])
+/* {{{ proto void ob_implicit_flush([bool flag])
diff --git a/ext/pdo_dblib/dblib_driver.c b/ext/pdo_dblib/dblib_driver.c
index efc8dc1..c75c698 100644
--- a/ext/pdo_dblib/dblib_driver.c
+++ b/ext/pdo_dblib/dblib_driver.c
@@ -375,6 +375,8 @@ static int pdo_dblib_handle_factory(pdo_dbh_t *dbh, zval *driver_options)
,{ "dbname", NULL, 0 }
,{ "secure", NULL, 0 } /* DBSETLSECURE */
,{ "version", NULL, 0 } /* DBSETLVERSION */
+ ,{ "user", NULL, 0 }
+ ,{ "password", NULL, 0 }