fully quality paths
I was pretty inconsistent in here. It is better to be explicit. To keep myself honest, I did: rm -r test/zend; tools/import_zend_test.py -z /tmp/php-5.4.13/ Of the changed files: * type_hinting_005a.php was missed in the original import * closure_033.php someone changed by hand before * date and posix tests now pass magically * bug43703 too The rest are whitespace updates
Esse commit está contido em:
@@ -1,40 +0,0 @@
|
||||
<?php
|
||||
|
||||
$fd = bzopen(dirname(__FILE__)."/004_1.txt.bz2","r");
|
||||
var_dump(bzerror($fd));
|
||||
var_dump(bzerrstr($fd));
|
||||
var_dump(bzerrno($fd));
|
||||
|
||||
$fd2 = bzopen(dirname(__FILE__)."/004_2.txt.bz2","r");
|
||||
var_dump(bzerror($fd2));
|
||||
var_dump(bzerrstr($fd2));
|
||||
var_dump(bzerrno($fd2));
|
||||
|
||||
var_dump(bzread($fd, 10));
|
||||
var_dump(bzerror($fd));
|
||||
var_dump(bzerrstr($fd));
|
||||
var_dump(bzerrno($fd));
|
||||
|
||||
var_dump(bzread($fd2, 10));
|
||||
var_dump(bzerror($fd2));
|
||||
var_dump(bzerrstr($fd2));
|
||||
var_dump(bzerrno($fd2));
|
||||
|
||||
var_dump(bzread($fd));
|
||||
var_dump(bzerror($fd));
|
||||
var_dump(bzerrstr($fd));
|
||||
var_dump(bzerrno($fd));
|
||||
|
||||
var_dump(bzread($fd2));
|
||||
var_dump(bzerror($fd2));
|
||||
var_dump(bzerrstr($fd2));
|
||||
var_dump(bzerrno($fd2));
|
||||
|
||||
bzclose($fd2);
|
||||
var_dump(bzread($fd2));
|
||||
var_dump(bzerror($fd2));
|
||||
var_dump(bzerrstr($fd2));
|
||||
var_dump(bzerrno($fd2));
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
@@ -1,61 +0,0 @@
|
||||
array(2) {
|
||||
["errno"]=>
|
||||
int(0)
|
||||
["errstr"]=>
|
||||
string(2) "OK"
|
||||
}
|
||||
string(2) "OK"
|
||||
int(0)
|
||||
array(2) {
|
||||
["errno"]=>
|
||||
int(0)
|
||||
["errstr"]=>
|
||||
string(2) "OK"
|
||||
}
|
||||
string(2) "OK"
|
||||
int(0)
|
||||
string(0) ""
|
||||
array(2) {
|
||||
["errno"]=>
|
||||
int(-5)
|
||||
["errstr"]=>
|
||||
string(16) "DATA_ERROR_MAGIC"
|
||||
}
|
||||
string(16) "DATA_ERROR_MAGIC"
|
||||
int(-5)
|
||||
string(0) ""
|
||||
array(2) {
|
||||
["errno"]=>
|
||||
int(-4)
|
||||
["errstr"]=>
|
||||
string(10) "DATA_ERROR"
|
||||
}
|
||||
string(10) "DATA_ERROR"
|
||||
int(-4)
|
||||
string(0) ""
|
||||
array(2) {
|
||||
["errno"]=>
|
||||
int(-5)
|
||||
["errstr"]=>
|
||||
string(16) "DATA_ERROR_MAGIC"
|
||||
}
|
||||
string(16) "DATA_ERROR_MAGIC"
|
||||
int(-5)
|
||||
string(0) ""
|
||||
array(2) {
|
||||
["errno"]=>
|
||||
int(-4)
|
||||
["errstr"]=>
|
||||
string(10) "DATA_ERROR"
|
||||
}
|
||||
string(10) "DATA_ERROR"
|
||||
int(-4)
|
||||
HipHop Warning: %a
|
||||
bool(false)
|
||||
HipHop Warning: %a
|
||||
bool(false)
|
||||
HipHop Warning: %a
|
||||
bool(false)
|
||||
HipHop Warning: %a
|
||||
bool(false)
|
||||
Done
|
||||
@@ -1,18 +0,0 @@
|
||||
<?php
|
||||
$now = '2010-03-07 13:21:38 UTC';
|
||||
//positive DateInterval
|
||||
$da1 = date_create( $now );
|
||||
$ds1 = date_create( $now );
|
||||
$i = DateInterval::createFromDateString('third Tuesday of next month');
|
||||
echo $da1->format( DateTime::ISO8601 ), "\n";
|
||||
echo date_add($da1, $i)->format( DateTime::ISO8601 ), "\n";
|
||||
date_sub($ds1, $i);
|
||||
|
||||
//negative DateInterval
|
||||
$da2 = date_create( $now );
|
||||
$ds2 = date_create( $now );
|
||||
$i2 = DateInterval::createFromDateString('third Tuesday of last month');
|
||||
echo $da2->format( DateTime::ISO8601 ), "\n";
|
||||
echo date_add($da2, $i2)->format( DateTime::ISO8601 ), "\n";//works
|
||||
date_sub($ds2, $i);
|
||||
?>
|
||||
@@ -1,6 +0,0 @@
|
||||
2010-03-07T13:21:38+0000
|
||||
2010-04-20T13:21:38+0000
|
||||
HipHop Warning: %a
|
||||
2010-03-07T13:21:38+0000
|
||||
2010-02-16T13:21:38+0000
|
||||
HipHop Warning: %a
|
||||
@@ -1,3 +0,0 @@
|
||||
<?php
|
||||
imagecreatefromgd(dirname(__FILE__) . '/crafted.gd2');
|
||||
?>
|
||||
@@ -1 +0,0 @@
|
||||
HipHop Warning: %a
|
||||
@@ -3,7 +3,7 @@
|
||||
/* Prototype : array hash_algos (void)
|
||||
* Description: Return a list of registered hashing algorithms
|
||||
* Source code: ext/hash/hash.c
|
||||
* Alias to functions:
|
||||
* Alias to functions:
|
||||
*/
|
||||
|
||||
echo "*** Testing hash_algos() : basic functionality ***\n";
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
/* Prototype : string hash_file ( string algo, string filename [, bool raw_output] )
|
||||
* Description: Generate a hash value using the contents of a given file
|
||||
* Source code: ext/hash/hash.c
|
||||
* Alias to functions:
|
||||
* Alias to functions:
|
||||
*/
|
||||
|
||||
echo "*** Testing hash_file() : basic functionality ***\n";
|
||||
@@ -13,9 +13,9 @@ $file = dirname(__FILE__) . "hash_file.txt";
|
||||
if (($fp = fopen( $file, "w+")) == FALSE) {
|
||||
echo "Cannot create file ($file)";
|
||||
exit;
|
||||
}
|
||||
}
|
||||
|
||||
/* Writing into file */
|
||||
/* Writing into file */
|
||||
$content = "This is a sample string used to test the hash_file function with various hashing algorithms";
|
||||
if (is_writable($file)) {
|
||||
if (fwrite($fp, $content) === FALSE) {
|
||||
@@ -24,7 +24,7 @@ if (is_writable($file)) {
|
||||
}
|
||||
}
|
||||
|
||||
// close the file
|
||||
// close the file
|
||||
fclose($fp);
|
||||
|
||||
echo "adler32: " . hash_file('adler32', $file) . "\n";
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
/* Prototype : string hash_hmac ( string $algo , string $data , string $key [, bool $raw_output ] )
|
||||
* Description: Generate a keyed hash value using the HMAC method
|
||||
* Source code: ext/hash/hash.c
|
||||
* Alias to functions:
|
||||
* Alias to functions:
|
||||
*/
|
||||
|
||||
echo "*** Testing hash_hmac() : basic functionality ***\n";
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
/* Prototype : string hash_hmac_file ( string algo, string filename, string key [, bool raw_output] )
|
||||
* Description: Generate a keyed hash value using the HMAC method and the contents of a given file
|
||||
* Source code: ext/hash/hash.c
|
||||
* Alias to functions:
|
||||
* Alias to functions:
|
||||
*/
|
||||
|
||||
echo "*** Testing hash_hmac_file() : basic functionality ***\n";
|
||||
@@ -14,9 +14,9 @@ $file = dirname(__FILE__) . "hash_hmac_file.txt";
|
||||
if (($fp = fopen( $file, "w+")) == FALSE) {
|
||||
echo "Cannot create file ($file)";
|
||||
exit;
|
||||
}
|
||||
}
|
||||
|
||||
/* Writing into file */
|
||||
/* Writing into file */
|
||||
$content = "This is a sample string used to test the hash_hmac_file function with various hashing algorithms";
|
||||
if (is_writable($file)) {
|
||||
if (fwrite($fp, $content) === FALSE) {
|
||||
@@ -25,7 +25,7 @@ if (is_writable($file)) {
|
||||
}
|
||||
}
|
||||
|
||||
// close the files
|
||||
// close the files
|
||||
fclose($fp);
|
||||
|
||||
$key = 'secret';
|
||||
|
||||
@@ -12,7 +12,7 @@ $pass = true;
|
||||
|
||||
foreach ($tests as $test) {
|
||||
++$i;
|
||||
|
||||
|
||||
$result = hash("joaat", $test[0]);
|
||||
if ($result != $test[1]) {
|
||||
echo "Iteration " . $i . " failed - expected '" . $test[1] . "', got '" . $result . "' for '" . $test[1] . "'\n";
|
||||
|
||||
@@ -22,7 +22,7 @@ $supported_hash_al = array(
|
||||
|
||||
$hc = mhash_count() + 1;
|
||||
|
||||
$known_hash_al = array();
|
||||
$known_hash_al = array();
|
||||
for ($i=0; $i < $hc; $i++) {
|
||||
$known_hash_al[mhash_get_hash_name($i)] = $i;
|
||||
}
|
||||
@@ -33,6 +33,6 @@ foreach ($supported_hash_al as $name => $len) {
|
||||
echo "$name = $len\n";
|
||||
} else {
|
||||
echo "$name ? $len\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
@@ -18,5 +18,5 @@ Content-Description: description3
|
||||
contents.data3
|
||||
|
||||
|
||||
|
||||
|
||||
--%s--
|
||||
@@ -2,15 +2,15 @@
|
||||
$envelope["from"] = 'Santa <somewhere@northpole.gov>';
|
||||
$envelope["to"] = 'The bad smurf <bad@smurf.com>';
|
||||
$envelope['date'] = 'Wed, 04 Jan 2006 19:24:43 -0500';
|
||||
|
||||
|
||||
$multipart["type"] = TYPEMULTIPART;
|
||||
$multipart["subtype"] = "MIXED";
|
||||
$body[] = $multipart; //add multipart stuff
|
||||
|
||||
|
||||
$textpart["type"] = TYPEMULTIPART;
|
||||
$textpart["subtype"] = "ALTERNATIVE";
|
||||
$body[] = $textpart; //add body part
|
||||
|
||||
|
||||
$plain["type"] = TYPETEXT;
|
||||
$plain["subtype"] = "PLAIN";
|
||||
$plain["charset"] = "iso-8859-1";
|
||||
@@ -18,9 +18,9 @@
|
||||
$plain["description"] = "Plaintype part of message";
|
||||
$plain['disposition'] = "inline";
|
||||
$plain["contents.data"] = 'See mom, it will crash';
|
||||
|
||||
|
||||
$body[] = $plain; //next add plain text part
|
||||
|
||||
|
||||
$html["type"] = TYPETEXT;
|
||||
$html["subtype"] = "HTML";
|
||||
$html["charset"] = "iso-8859-1";
|
||||
@@ -28,8 +28,8 @@
|
||||
$html["description"] = "HTML part of message";
|
||||
$html['disposition'] = "inline";
|
||||
$html["contents.data"] = 'See mom, it will <b>crash</b>';
|
||||
|
||||
|
||||
$body[] = $html;
|
||||
|
||||
|
||||
echo imap_mail_compose($envelope, $body);
|
||||
?>
|
||||
@@ -18,5 +18,5 @@ Content-Description: description3
|
||||
contents.data3
|
||||
|
||||
|
||||
|
||||
|
||||
--%s--
|
||||
@@ -1,48 +1,48 @@
|
||||
array (
|
||||
0 =>
|
||||
0 =>
|
||||
stdClass::__set_state(array(
|
||||
'mailbox' => 'iane',
|
||||
'host' => 'example.ac.uk',
|
||||
'personal' => 'ian eiloart',
|
||||
)),
|
||||
1 =>
|
||||
1 =>
|
||||
stdClass::__set_state(array(
|
||||
'mailbox' => 'shuf6',
|
||||
'host' => 'example.ac.uk',
|
||||
)),
|
||||
2 =>
|
||||
2 =>
|
||||
stdClass::__set_state(array(
|
||||
'mailbox' => 'blobby',
|
||||
'host' => 'example.com',
|
||||
)),
|
||||
3 =>
|
||||
3 =>
|
||||
stdClass::__set_state(array(
|
||||
'mailbox' => 'ian',
|
||||
'host' => 'example.ac.uk',
|
||||
'personal' => 'ian,eiloart',
|
||||
)),
|
||||
4 =>
|
||||
4 =>
|
||||
stdClass::__set_state(array(
|
||||
'mailbox' => 'foo',
|
||||
'host' => 'example.ac.uk',
|
||||
'adl' => '@example.com',
|
||||
)),
|
||||
5 =>
|
||||
5 =>
|
||||
stdClass::__set_state(array(
|
||||
'mailbox' => 'foo',
|
||||
'host' => '#',
|
||||
)),
|
||||
6 =>
|
||||
6 =>
|
||||
stdClass::__set_state(array(
|
||||
'mailbox' => 'ian',
|
||||
'host' => '-example.com',
|
||||
)),
|
||||
7 =>
|
||||
7 =>
|
||||
stdClass::__set_state(array(
|
||||
'mailbox' => 'ian',
|
||||
'host' => 'one',
|
||||
)),
|
||||
8 =>
|
||||
8 =>
|
||||
stdClass::__set_state(array(
|
||||
'mailbox' => 'UNEXPECTED_DATA_AFTER_ADDRESS',
|
||||
'host' => '.SYNTAX-ERROR.',
|
||||
|
||||
@@ -15,7 +15,7 @@ if (!is_resource($imap_stream)) {
|
||||
}
|
||||
|
||||
$mb_details = imap_mailboxmsginfo($imap_stream);
|
||||
echo "Add a couple of msgs to new mailbox " . $mb_details->Mailbox . "\n";
|
||||
echo "Add a couple of msgs to new mailbox " . $mb_details->Mailbox . "\n";
|
||||
var_dump(imap_append($imap_stream, $mb_details->Mailbox
|
||||
, "From: webmaster@something.com\r\n"
|
||||
. "To: info@something.com\r\n"
|
||||
@@ -23,15 +23,15 @@ var_dump(imap_append($imap_stream, $mb_details->Mailbox
|
||||
. "\r\n"
|
||||
. "this is a test message, please ignore\r\n"
|
||||
));
|
||||
|
||||
|
||||
var_dump(imap_append($imap_stream, $mb_details->Mailbox
|
||||
, "From: webmaster@something.com\r\n"
|
||||
. "To: info@something.com\r\n"
|
||||
. "Subject: Another test\r\n"
|
||||
. "\r\n"
|
||||
. "this is another test message, please ignore it too!!\r\n"
|
||||
));
|
||||
|
||||
));
|
||||
|
||||
$check = imap_check($imap_stream);
|
||||
echo "Msg Count after append : ". $check->Nmsgs . "\n";
|
||||
|
||||
@@ -40,6 +40,6 @@ var_dump(imap_headers($imap_stream));
|
||||
|
||||
imap_close($imap_stream);
|
||||
?>
|
||||
===Done===<?php
|
||||
===Done===<?php
|
||||
require_once('clean.inc');
|
||||
?>
|
||||
@@ -6,7 +6,7 @@ echo "Checking with incorrect parameter type\n";
|
||||
imap_body('');
|
||||
imap_body(false);
|
||||
require_once(dirname(__FILE__).'/imap_include.inc');
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
die("Cannot connect to mailbox $default_mailbox: " . imap_last_error());
|
||||
imap_body($stream_id);
|
||||
imap_body($stream_id,-1);
|
||||
|
||||
@@ -15,8 +15,8 @@ if (!is_resource($imap_stream)) {
|
||||
}
|
||||
|
||||
$check = imap_check($imap_stream);
|
||||
echo "Msg Count in new mailbox: ". $check->Nmsgs . "\n";
|
||||
|
||||
echo "Msg Count in new mailbox: ". $check->Nmsgs . "\n";
|
||||
|
||||
// show body for msg 1
|
||||
var_dump(imap_body($imap_stream, 1));
|
||||
|
||||
@@ -25,6 +25,6 @@ var_dump(imap_body($imap_stream, 1, FT_UID));
|
||||
|
||||
imap_close($imap_stream);
|
||||
?>
|
||||
===Done===<?php
|
||||
===Done===<?php
|
||||
require_once('clean.inc');
|
||||
?>
|
||||
@@ -13,10 +13,10 @@ if (!is_resource($imap_stream)) {
|
||||
exit("TEST FAILED: Unable to create test mailbox\n");
|
||||
}
|
||||
|
||||
echo "\nGet and validate structure of body part 1\n";
|
||||
|
||||
$m = imap_bodystruct($imap_stream, 1, "1");
|
||||
echo "\nGet and validate structure of body part 1\n";
|
||||
|
||||
$m = imap_bodystruct($imap_stream, 1, "1");
|
||||
|
||||
$mandatoryFields = array(
|
||||
'ifsubtype',
|
||||
'ifdescription',
|
||||
@@ -26,9 +26,9 @@ $mandatoryFields = array(
|
||||
'ifparameters',
|
||||
);
|
||||
|
||||
foreach($mandatoryFields as $mf)
|
||||
foreach($mandatoryFields as $mf)
|
||||
{
|
||||
if(isValid($m->$mf))
|
||||
if(isValid($m->$mf))
|
||||
{
|
||||
echo "$mf is 0 or 1\n";
|
||||
}
|
||||
@@ -38,29 +38,29 @@ foreach($mandatoryFields as $mf)
|
||||
}
|
||||
}
|
||||
|
||||
if(is_array($m->parameters))
|
||||
if(is_array($m->parameters))
|
||||
{
|
||||
echo "parameters is an array\n";
|
||||
}
|
||||
|
||||
echo "\nTry to get part 4!\n";
|
||||
var_dump(imap_bodystruct($imap_stream, 1, "4"));
|
||||
var_dump(imap_bodystruct($imap_stream, 1, "4"));
|
||||
|
||||
imap_close($imap_stream);
|
||||
|
||||
function isValid($param)
|
||||
function isValid($param)
|
||||
{
|
||||
if(($param == 0) || ($param == 1))
|
||||
if(($param == 0) || ($param == 1))
|
||||
{
|
||||
$result=true;
|
||||
}
|
||||
else
|
||||
{
|
||||
$result=false;
|
||||
}
|
||||
}
|
||||
return $result;
|
||||
}
|
||||
?>
|
||||
===Done===<?php
|
||||
===Done===<?php
|
||||
require_once('clean.inc');
|
||||
?>
|
||||
@@ -17,7 +17,7 @@ if (!is_resource($imap_stream)) {
|
||||
$check = imap_check($imap_stream);
|
||||
echo "Initial msg count in new_mailbox : ". $check->Nmsgs . "\n";
|
||||
|
||||
echo "Set some flags\n";
|
||||
echo "Set some flags\n";
|
||||
var_dump(imap_setflag_full($imap_stream, "1,3", "\\Seen \\Answered"));
|
||||
var_dump(imap_setflag_full($imap_stream, "2,4", "\\Answered"));
|
||||
var_dump(imap_setflag_full($imap_stream, "5,7", "\\Flagged \\Deleted"));
|
||||
@@ -40,6 +40,6 @@ var_dump(imap_search($imap_stream, "DELETED"));
|
||||
|
||||
imap_close($imap_stream);
|
||||
?>
|
||||
===Done===<?php
|
||||
===Done===<?php
|
||||
require_once('clean.inc');
|
||||
?>
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : bool imap_close(resource $stream_id [, int $options])
|
||||
* Description: Close an IMAP stream
|
||||
* Description: Close an IMAP stream
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : bool imap_close(resource $stream_id [, int $options])
|
||||
* Description: Close an IMAP stream
|
||||
* Description: Close an IMAP stream
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : bool imap_close(resource $stream_id [, int $options])
|
||||
* Description: Close an IMAP stream
|
||||
* Description: Close an IMAP stream
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -52,7 +52,7 @@ $inputs = array(
|
||||
false,
|
||||
TRUE,
|
||||
FALSE,
|
||||
|
||||
|
||||
// empty data
|
||||
/*16*/ "",
|
||||
'',
|
||||
@@ -62,7 +62,7 @@ $inputs = array(
|
||||
/*19*/ "string",
|
||||
'string',
|
||||
$heredoc,
|
||||
|
||||
|
||||
// object data
|
||||
/*22*/ new classA(),
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : bool imap_close(resource $stream_id [, int $options])
|
||||
* Description: Close an IMAP stream
|
||||
* Description: Close an IMAP stream
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -50,7 +50,7 @@ $inputs = array(
|
||||
false,
|
||||
TRUE,
|
||||
FALSE,
|
||||
|
||||
|
||||
// empty data
|
||||
/*16*/ "",
|
||||
'',
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : bool imap_close(resource $stream_id [, int $options])
|
||||
* Description: Close an IMAP stream
|
||||
* Description: Close an IMAP stream
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : bool imap_close(resource $stream_id [, int $options])
|
||||
* Description: Close an IMAP stream
|
||||
* Description: Close an IMAP stream
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ echo "*** Testing imap_createmailbox() : basic functionality ***\n";
|
||||
|
||||
require_once(dirname(__FILE__).'/imap_include.inc');
|
||||
|
||||
$imap_stream = imap_open($default_mailbox, $username, $password) or
|
||||
$imap_stream = imap_open($default_mailbox, $username, $password) or
|
||||
die("Cannot connect to mailbox $default_mailbox: " . imap_last_error());
|
||||
|
||||
$newname = "phpnewbox";
|
||||
@@ -18,8 +18,8 @@ echo "Newname will be '$newname'\n";
|
||||
$newbox = imap_utf7_encode($server.$newname);
|
||||
if (imap_createmailbox($imap_stream, $newbox)) {
|
||||
|
||||
echo "Add a couple of msgs to '$newname' mailbox\n";
|
||||
populate_mailbox($imap_stream, $newbox, 2);
|
||||
echo "Add a couple of msgs to '$newname' mailbox\n";
|
||||
populate_mailbox($imap_stream, $newbox, 2);
|
||||
|
||||
$status = imap_status($imap_stream, $newbox, SA_ALL);
|
||||
if ($status) {
|
||||
@@ -29,7 +29,7 @@ if (imap_createmailbox($imap_stream, $newbox)) {
|
||||
echo "Unseen: " . $status->unseen . "\n";
|
||||
echo "UIDnext: " . $status->uidnext . "\n";
|
||||
echo "UIDvalidity: " . $status->uidvalidity . "\n";
|
||||
|
||||
|
||||
} else {
|
||||
echo "imap_status on new mailbox failed: " . imap_last_error() . "\n";
|
||||
}
|
||||
|
||||
@@ -6,18 +6,18 @@
|
||||
|
||||
echo "*** Testing imap_errors() : basic functionality ***\n";
|
||||
require_once(dirname(__FILE__).'/imap_include.inc');
|
||||
$password = "bogus"; // invalid password to use in this test
|
||||
$password = "bogus"; // invalid password to use in this test
|
||||
|
||||
echo "Issue open with invalid password with normal default number of retries, i.e 3\n";
|
||||
$mbox = imap_open($default_mailbox, $username, $password, OP_READONLY, 3);
|
||||
|
||||
echo "List any errors\n";
|
||||
var_dump(imap_errors());
|
||||
var_dump(imap_errors());
|
||||
|
||||
echo "\n\nIssue open with invalid password with retries == 1\n";
|
||||
$mbox = imap_open($default_mailbox, $username, $password, OP_READONLY, 1);
|
||||
|
||||
echo "List any errors\n";
|
||||
var_dump(imap_errors());
|
||||
var_dump(imap_errors());
|
||||
?>
|
||||
===Done===
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Prototype : array imap_fetch_overview(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Read an overview of the information in the headers
|
||||
* of the given message sequence
|
||||
* Description: Read an overview of the information in the headers
|
||||
* of the given message sequence
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Prototype : array imap_fetch_overview(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Read an overview of the information in the headers
|
||||
* of the given message sequence
|
||||
* Description: Read an overview of the information in the headers
|
||||
* of the given message sequence
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Prototype : array imap_fetch_overview(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Read an overview of the information in the headers
|
||||
* of the given message sequence
|
||||
* Description: Read an overview of the information in the headers
|
||||
* of the given message sequence
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -56,7 +56,7 @@ $inputs = array(
|
||||
false,
|
||||
TRUE,
|
||||
FALSE,
|
||||
|
||||
|
||||
// empty data
|
||||
/*16*/ "",
|
||||
'',
|
||||
@@ -66,7 +66,7 @@ $inputs = array(
|
||||
/*19*/ "string",
|
||||
'string',
|
||||
$heredoc,
|
||||
|
||||
|
||||
// object data
|
||||
/*22*/ new classA(),
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Prototype : array imap_fetch_overview(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Read an overview of the information in the headers
|
||||
* of the given message sequence
|
||||
* Description: Read an overview of the information in the headers
|
||||
* of the given message sequence
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -60,7 +60,7 @@ $inputs = array(
|
||||
false,
|
||||
TRUE,
|
||||
FALSE,
|
||||
|
||||
|
||||
// empty data
|
||||
/*16*/ "",
|
||||
'',
|
||||
@@ -70,7 +70,7 @@ $inputs = array(
|
||||
/*19*/ "string",
|
||||
'string',
|
||||
$heredoc,
|
||||
|
||||
|
||||
// object data
|
||||
/*22*/ new classA(),
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : array imap_fetch_overview(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Read an overview of the information in the headers of the given message sequence
|
||||
* Description: Read an overview of the information in the headers of the given message sequence
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -21,13 +21,13 @@ $msg_uid = imap_uid($stream_id, $msg_no);
|
||||
|
||||
$options = array ('1',
|
||||
true,
|
||||
1.000000000000001,
|
||||
0.00001e5,
|
||||
PHP_INT_MAX,
|
||||
1.000000000000001,
|
||||
0.00001e5,
|
||||
PHP_INT_MAX,
|
||||
-PHP_INT_MAX
|
||||
);
|
||||
|
||||
// iterate over each element of $options array
|
||||
// iterate over each element of $options array
|
||||
$iterator = 1;
|
||||
imap_check($stream_id);
|
||||
foreach($options as $option) {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Prototype : array imap_fetch_overview(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Read an overview of the information in the headers
|
||||
* of the given message sequence
|
||||
* Description: Read an overview of the information in the headers
|
||||
* of the given message sequence
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Prototype : array imap_fetch_overview(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Read an overview of the information in the headers
|
||||
* of the given message sequence
|
||||
* Description: Read an overview of the information in the headers
|
||||
* of the given message sequence
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -28,7 +28,7 @@ foreach($sequences as $msg_no) {
|
||||
foreach($overview as $ov) {
|
||||
echo "\n";
|
||||
displayOverviewFields($ov);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : array imap_fetch_overview(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Read an overview of the information in the headers of the given message sequence
|
||||
* Description: Read an overview of the information in the headers of the given message sequence
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -40,17 +40,17 @@ function create_multipart_message($imap_stream, $mailbox) {
|
||||
|
||||
$part1["type"] = TYPEMULTIPART;
|
||||
$part1["subtype"] = "mixed";
|
||||
|
||||
|
||||
$part2["type"] = TYPETEXT;
|
||||
$part2["subtype"] = "plain";
|
||||
$part2["description"] = "imap_mail_compose() function";
|
||||
$part2["contents.data"] = "message 1:xxxxxxxxxxxxxxxxxxxxxxxxxx";
|
||||
|
||||
|
||||
$part3["type"] = TYPETEXT;
|
||||
$part3["subtype"] = "plain";
|
||||
$part3["description"] = "Example";
|
||||
$part3["contents.data"] = "message 2:yyyyyyyyyyyyyyyyyyyyyyyyyy";
|
||||
|
||||
|
||||
$file_handle = fopen(__FILE__, 'r+');
|
||||
$file_size = 1;
|
||||
|
||||
@@ -62,12 +62,12 @@ function create_multipart_message($imap_stream, $mailbox) {
|
||||
$part4['disposition'] = array ('filename' => 'Test');
|
||||
$part4['type.parameters'] = array('name' => 'Test');
|
||||
$part4["contents.data"] = base64_encode(fread($file_handle, 1));
|
||||
|
||||
|
||||
$body[1] = $part1;
|
||||
$body[2] = $part2;
|
||||
$body[3] = $part3;
|
||||
$body[4] = $part4;
|
||||
|
||||
|
||||
$msg = imap_mail_compose($envelope, $body);
|
||||
|
||||
if (imap_append($imap_stream, $mailbox, $msg) === false) {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Prototype : string imap_fetchbody(resource $stream_id, int $msg_no, string $section
|
||||
/* Prototype : string imap_fetchbody(resource $stream_id, int $msg_no, string $section
|
||||
* [, int $options])
|
||||
* Description: Get a specific body section
|
||||
* Description: Get a specific body section
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -27,14 +27,14 @@ foreach ($options as $key => $option) {
|
||||
$msg_uid = imap_uid($stream_id, $msg_no);
|
||||
var_dump( imap_fetchbody($stream_id, $msg_uid, $section, $option) );
|
||||
break;
|
||||
|
||||
|
||||
case 'FT_PEEK';
|
||||
var_dump( imap_fetchbody($stream_id, $msg_no, $section, $option) );
|
||||
$overview = imap_fetch_overview($stream_id, 1);
|
||||
echo "Seen Flag: ";
|
||||
var_dump( $overview[0]->seen );
|
||||
break;
|
||||
|
||||
|
||||
case 'FT_INTERNAL';
|
||||
var_dump( imap_fetchbody($stream_id, $msg_no, $section, $option) );
|
||||
break;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Prototype :string imap_fetchbody(resource $stream_id, int $msg_no, string $section
|
||||
/* Prototype :string imap_fetchbody(resource $stream_id, int $msg_no, string $section
|
||||
* [, int $options])
|
||||
* Description: Get a specific body section
|
||||
* Description: Get a specific body section
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Prototype : string imap_fetchbody(resource $stream_id, int $msg_no, string $section
|
||||
/* Prototype : string imap_fetchbody(resource $stream_id, int $msg_no, string $section
|
||||
* [, int $options])
|
||||
* Description: Get a specific body section
|
||||
* Description: Get a specific body section
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -57,7 +57,7 @@ $inputs = array(
|
||||
false,
|
||||
TRUE,
|
||||
FALSE,
|
||||
|
||||
|
||||
// empty data
|
||||
/*16*/ "",
|
||||
'',
|
||||
@@ -67,7 +67,7 @@ $inputs = array(
|
||||
/*19*/ "string",
|
||||
'string',
|
||||
$heredoc,
|
||||
|
||||
|
||||
// object data
|
||||
/*22*/ new classA(),
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Prototype : string imap_fetchbody(resource $stream_id, int $msg_no, string $section
|
||||
/* Prototype : string imap_fetchbody(resource $stream_id, int $msg_no, string $section
|
||||
* [, int $options])
|
||||
* Description: Get a specific body section
|
||||
* Description: Get a specific body section
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -59,7 +59,7 @@ $inputs = array(
|
||||
false,
|
||||
TRUE,
|
||||
FALSE,
|
||||
|
||||
|
||||
// empty data
|
||||
/*16*/ "",
|
||||
'',
|
||||
@@ -69,7 +69,7 @@ $inputs = array(
|
||||
/*19*/ "string",
|
||||
'string',
|
||||
$heredoc,
|
||||
|
||||
|
||||
// object data
|
||||
/*22*/ new classA(),
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Prototype : string imap_fetchbody(resource $stream_id, int $msg_no, string $section
|
||||
/* Prototype : string imap_fetchbody(resource $stream_id, int $msg_no, string $section
|
||||
* [, int $options])
|
||||
* Description: Get a specific body section
|
||||
* Description: Get a specific body section
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -59,7 +59,7 @@ $inputs = array(
|
||||
false,
|
||||
TRUE,
|
||||
FALSE,
|
||||
|
||||
|
||||
// empty data
|
||||
/*16*/ "",
|
||||
'',
|
||||
@@ -69,7 +69,7 @@ $inputs = array(
|
||||
/*19*/ "string",
|
||||
'string',
|
||||
$heredoc,
|
||||
|
||||
|
||||
// object data
|
||||
/*22*/ new classA(),
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : string imap_fetchbody(resource $stream_id, int $msg_no, string $section [, int $options])
|
||||
* Description: Get a specific body section
|
||||
* Description: Get a specific body section
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -20,8 +20,8 @@ $msg_uid = imap_uid($stream_id, $msg_no);
|
||||
$section = 1;
|
||||
|
||||
//Note: the first four values are valid as they will all be cast to 1L.
|
||||
$options = array ('1', true,
|
||||
1.000000000000001, 0.00001e5,
|
||||
$options = array ('1', true,
|
||||
1.000000000000001, 0.00001e5,
|
||||
PHP_INT_MAX, -PHP_INT_MAX);
|
||||
|
||||
// iterate over each element of $options array to test whether FT_UID is set
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?php
|
||||
/* Prototype : string imap_fetchbody(resource $stream_id, int $msg_no, string $section
|
||||
/* Prototype : string imap_fetchbody(resource $stream_id, int $msg_no, string $section
|
||||
* [, int options])
|
||||
* Description: Get a specific body section
|
||||
* Description: Get a specific body section
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : string imap_fetchbody(resource $stream_id, int $msg_no, string $section [, int $options])
|
||||
* Description: Get a specific body section
|
||||
* Description: Get a specific body section
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : string imap_fetchheader(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Get the full unfiltered header for a message
|
||||
* Description: Get the full unfiltered header for a message
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -10,7 +10,7 @@ require_once(dirname(__FILE__).'/imap_include.inc');
|
||||
// Initialise all required variables
|
||||
$stream_id = setup_test_mailbox('', 1, $mailbox, 'multiPart'); // setup temp mailbox with 1 msg
|
||||
$msg_no = 1;
|
||||
$options = array('FT_UID' => FT_UID, 'FT_INTERNAL' => FT_INTERNAL,
|
||||
$options = array('FT_UID' => FT_UID, 'FT_INTERNAL' => FT_INTERNAL,
|
||||
'FT_PREFETCHTEXT' => FT_PREFETCHTEXT);
|
||||
|
||||
// Calling imap_fetchheader() with all possible arguments
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : string imap_fetchheader(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Get the full unfiltered header for a message
|
||||
* Description: Get the full unfiltered header for a message
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : string imap_fetchheader(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Get the full unfiltered header for a message
|
||||
* Description: Get the full unfiltered header for a message
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -62,7 +62,7 @@ $inputs = array(
|
||||
false,
|
||||
TRUE,
|
||||
FALSE,
|
||||
|
||||
|
||||
// empty data
|
||||
/*16*/ "",
|
||||
'',
|
||||
@@ -71,14 +71,14 @@ $inputs = array(
|
||||
/*18*/ "string",
|
||||
'string',
|
||||
$heredoc,
|
||||
|
||||
|
||||
// array data
|
||||
/*21*/ array(),
|
||||
$index_array,
|
||||
$assoc_array,
|
||||
array('foo', $index_array, $assoc_array),
|
||||
|
||||
|
||||
|
||||
|
||||
// object data
|
||||
/*25*/ new classA(),
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : string imap_fetchheader(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Get the full unfiltered header for a message
|
||||
* Description: Get the full unfiltered header for a message
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -62,7 +62,7 @@ $inputs = array(
|
||||
false,
|
||||
TRUE,
|
||||
FALSE,
|
||||
|
||||
|
||||
// empty data
|
||||
/*16*/ "",
|
||||
'',
|
||||
@@ -71,14 +71,14 @@ $inputs = array(
|
||||
/*18*/ "string",
|
||||
'string',
|
||||
$heredoc,
|
||||
|
||||
|
||||
// array data
|
||||
/*21*/ array(),
|
||||
$index_array,
|
||||
$assoc_array,
|
||||
array('foo', $index_array, $assoc_array),
|
||||
|
||||
|
||||
|
||||
|
||||
// object data
|
||||
/*25*/ new classA(),
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : string imap_fetchheader(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Get the full unfiltered header for a message
|
||||
* Description: Get the full unfiltered header for a message
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -19,8 +19,8 @@ $stream_id = setup_test_mailbox('', 1); // set up temporary mailbox with one sim
|
||||
$msg_no = 1;
|
||||
$msg_uid = imap_uid($stream_id, $msg_no);
|
||||
|
||||
$options = array ('1', true,
|
||||
1.000000000000001, 0.00001e5,
|
||||
$options = array ('1', true,
|
||||
1.000000000000001, 0.00001e5,
|
||||
PHP_INT_MAX, -PHP_INT_MAX);
|
||||
|
||||
// iterate over each element of $options array to test whether FT_UID is set
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : string imap_fetchheader(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Get the full unfiltered header for a message
|
||||
* Description: Get the full unfiltered header for a message
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
<?php
|
||||
/* Prototype : string imap_fetchheader(resource $stream_id, int $msg_no [, int $options])
|
||||
* Description: Get the full unfiltered header for a message
|
||||
* Description: Get the full unfiltered header for a message
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
/*
|
||||
* Pass different integers and strings as $msg_no argument
|
||||
* Pass different integers and strings as $msg_no argument
|
||||
* to test behaviour of imap_fetchheader()
|
||||
*/
|
||||
|
||||
@@ -17,7 +17,7 @@ $stream_id = setup_test_mailbox('', 3, $mailbox, 'notSimple'); // set up temp ma
|
||||
|
||||
$sequences = array (0, 4, // out of range
|
||||
'1,3', '1:3', // message sequences instead of numbers
|
||||
);
|
||||
);
|
||||
|
||||
foreach($sequences as $msg_no) {
|
||||
echo "\n-- \$msg_no is $msg_no --\n";
|
||||
|
||||
@@ -28,6 +28,6 @@ var_dump($z->lines);
|
||||
var_dump(is_object($z->parameters));
|
||||
|
||||
imap_close($stream_id);
|
||||
?><?php
|
||||
?><?php
|
||||
require_once('clean.inc');
|
||||
?>
|
||||
@@ -7,7 +7,7 @@ imap_gc('', false);
|
||||
imap_gc(false, false);
|
||||
|
||||
require_once(dirname(__FILE__).'/imap_include.inc');
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
die("Cannot connect to mailbox $default_mailbox: " . imap_last_error());
|
||||
imap_gc($stream_id, -1);
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ imap_getsubscribed('');
|
||||
imap_getsubscribed(false);
|
||||
|
||||
require_once(dirname(__FILE__).'/imap_include.inc');
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
die("Cannot connect to mailbox $default_mailbox: " . imap_last_error());
|
||||
|
||||
imap_getsubscribed($stream_id);
|
||||
@@ -28,6 +28,6 @@ var_dump(is_array($z));
|
||||
var_dump($z[0]);
|
||||
|
||||
imap_close($stream_id);
|
||||
?><?php
|
||||
?><?php
|
||||
require_once('clean.inc');
|
||||
?>
|
||||
@@ -7,7 +7,7 @@ $z = imap_headerinfo($stream_id, 1);
|
||||
|
||||
$fields = array ('toaddress','to','fromaddress','from',
|
||||
'reply_toaddress','reply_to',
|
||||
'senderaddress', 'sender',
|
||||
'senderaddress', 'sender',
|
||||
'subject','Subject',
|
||||
'Recent','Unseen','Flagged','Answered','Deleted','Draft',
|
||||
'Msgno','MailDate','Size','udate');
|
||||
@@ -73,6 +73,6 @@ var_dump($z->udate);
|
||||
|
||||
imap_close($stream_id);
|
||||
|
||||
?><?php
|
||||
?><?php
|
||||
require_once('clean.inc');
|
||||
?>
|
||||
@@ -7,9 +7,9 @@ imap_headerinfo('');
|
||||
imap_headerinfo(false);
|
||||
|
||||
require_once(dirname(__FILE__).'/imap_include.inc');
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
die("Cannot connect to mailbox $default_mailbox: " . imap_last_error());
|
||||
|
||||
|
||||
imap_headerinfo($stream_id);
|
||||
|
||||
imap_close($stream_id);
|
||||
|
||||
@@ -7,7 +7,7 @@ imap_list('');
|
||||
imap_list(false);
|
||||
|
||||
require_once(dirname(__FILE__).'/imap_include.inc');
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
die("Cannot connect to mailbox $default_mailbox: " . imap_last_error());
|
||||
|
||||
imap_list($stream_id);
|
||||
|
||||
@@ -7,7 +7,7 @@ imap_lsub('');
|
||||
imap_lsub(false);
|
||||
|
||||
require_once(dirname(__FILE__).'/imap_include.inc');
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
die("Cannot connect to mailbox $default_mailbox: " . imap_last_error());
|
||||
|
||||
imap_lsub($stream_id);
|
||||
@@ -28,6 +28,6 @@ var_dump(is_array($z));
|
||||
var_dump($z[0]);
|
||||
|
||||
imap_close($stream_id);
|
||||
?><?php
|
||||
?><?php
|
||||
require_once('clean.inc');
|
||||
?>
|
||||
@@ -13,9 +13,9 @@ require_once(dirname(__FILE__).'/imap_include.inc');
|
||||
|
||||
|
||||
echo "Test with IMAP server\n";
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
die("Cannot connect to mailbox $default_mailbox: " . imap_last_error());
|
||||
|
||||
|
||||
var_dump(imap_mail_copy($stream_id));
|
||||
var_dump(imap_mail_copy($stream_id,-1));
|
||||
var_dump(imap_mail_copy($stream_id, ''));
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : bool imap_mail_copy ( resource $imap_stream , string $msglist , string $mailbox [, int $options = 0 ] )
|
||||
* Description: Copies mail messages specified by msglist to specified mailbox.
|
||||
* Description: Copies mail messages specified by msglist to specified mailbox.
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -16,12 +16,12 @@ if (!is_resource($imap_stream)) {
|
||||
}
|
||||
|
||||
$check = imap_check($imap_stream);
|
||||
echo "Msg Count in new mailbox: ". $check->Nmsgs . "\n";
|
||||
echo "Msg Count in new mailbox: ". $check->Nmsgs . "\n";
|
||||
|
||||
var_dump(imap_mail_copy($imap_stream, '1', 'INBOX.'.$mailbox_prefix));
|
||||
|
||||
imap_close($imap_stream);
|
||||
?>
|
||||
===Done===<?php
|
||||
===Done===<?php
|
||||
require_once('clean.inc');
|
||||
?>
|
||||
@@ -13,9 +13,9 @@ require_once(dirname(__FILE__).'/imap_include.inc');
|
||||
|
||||
|
||||
echo "Test with IMAP server\n";
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
die("Cannot connect to mailbox $default_mailbox: " . imap_last_error());
|
||||
|
||||
|
||||
var_dump(imap_mail_move($stream_id));
|
||||
var_dump(imap_mail_move($stream_id,-1));
|
||||
var_dump(imap_mail_move($stream_id, ''));
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Prototype : bool imap_mail_move ( resource $imap_stream , string $msglist , string $mailbox [, int $options = 0 ] )
|
||||
* Description: Copies mail messages specified by msglist to specified mailbox.
|
||||
* Description: Copies mail messages specified by msglist to specified mailbox.
|
||||
* Source code: ext/imap/php_imap.c
|
||||
*/
|
||||
|
||||
@@ -16,12 +16,12 @@ if (!is_resource($imap_stream)) {
|
||||
}
|
||||
|
||||
$check = imap_check($imap_stream);
|
||||
echo "Msg Count in new mailbox: ". $check->Nmsgs . "\n";
|
||||
echo "Msg Count in new mailbox: ". $check->Nmsgs . "\n";
|
||||
|
||||
var_dump(imap_mail_move($imap_stream, '1', 'INBOX.'.$mailbox_prefix));
|
||||
|
||||
imap_close($imap_stream);
|
||||
?>
|
||||
===Done===<?php
|
||||
===Done===<?php
|
||||
require_once('clean.inc');
|
||||
?>
|
||||
@@ -8,7 +8,7 @@ imap_renamemailbox(false);
|
||||
|
||||
|
||||
require_once(dirname(__FILE__).'/imap_include.inc');
|
||||
|
||||
|
||||
$stream_id = setup_test_mailbox('', 1);
|
||||
|
||||
if (!is_resource($stream_id)) {
|
||||
@@ -32,6 +32,6 @@ var_dump(imap_createmailbox($stream_id, $newbox.'.test'));
|
||||
var_dump(imap_renamemailbox($stream_id, $newbox.'.test', $newbox.'.testd'));
|
||||
|
||||
imap_close($stream_id);
|
||||
?><?php
|
||||
?><?php
|
||||
require_once('clean.inc');
|
||||
?>
|
||||
@@ -7,7 +7,7 @@ $z = imap_headerinfo($stream_id, 1);
|
||||
|
||||
$fields = array ('toaddress','to','fromaddress','from',
|
||||
'reply_toaddress','reply_to',
|
||||
'senderaddress', 'sender',
|
||||
'senderaddress', 'sender',
|
||||
'subject','Subject',
|
||||
'MailDate','Size','udate');
|
||||
|
||||
@@ -73,6 +73,6 @@ var_dump($z->udate);
|
||||
|
||||
imap_close($stream_id);
|
||||
|
||||
?><?php
|
||||
?><?php
|
||||
require_once('clean.inc');
|
||||
?>
|
||||
@@ -26,7 +26,7 @@ var_dump($z);
|
||||
echo "Size: ".filesize($file)."\n";
|
||||
|
||||
imap_close($stream_id);
|
||||
?><?php
|
||||
?><?php
|
||||
@unlink(dirname(__FILE__).'/tmpsavebody.txt');
|
||||
require_once('clean.inc');
|
||||
?>
|
||||
@@ -9,6 +9,6 @@ var_dump(imap_undelete($stream_id, 1));
|
||||
|
||||
imap_close($stream_id);
|
||||
|
||||
?><?php
|
||||
?><?php
|
||||
require_once('clean.inc');
|
||||
?>
|
||||
@@ -7,9 +7,9 @@ imap_undelete('');
|
||||
imap_undelete(false);
|
||||
|
||||
require_once(dirname(__FILE__).'/imap_include.inc');
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
$stream_id = imap_open($default_mailbox, $username, $password) or
|
||||
die("Cannot connect to mailbox $default_mailbox: " . imap_last_error());
|
||||
|
||||
|
||||
imap_undelete($stream_id);
|
||||
|
||||
imap_close($stream_id);
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
<?php
|
||||
Class C { function f(array $a) {} }
|
||||
|
||||
echo "Compatible hint.\n";
|
||||
Class D1 extends C { function f(array $a) {} }
|
||||
|
||||
echo "Class hint, should be array.\n";
|
||||
Class D2 extends C { function f(SomeClass $a) {} }
|
||||
?>
|
||||
==DONE==
|
||||
@@ -0,0 +1,4 @@
|
||||
Strict Standards: Declaration of D2::f() should be compatible with C::f(array $a) in hphp/test/zend/bad/tests-classes/type_hinting_005a.php on line 8
|
||||
Compatible hint.
|
||||
Class hint, should be array.
|
||||
==DONE==
|
||||
@@ -1,59 +0,0 @@
|
||||
<?php
|
||||
|
||||
// the stack size + some random constant
|
||||
$boundary = 64*1024;
|
||||
$limit = $boundary+42;
|
||||
|
||||
|
||||
function test($a,$b)
|
||||
{
|
||||
var_dump($a === $b);
|
||||
test2($a,$b);
|
||||
}
|
||||
|
||||
function test2($a, $b)
|
||||
{
|
||||
if ($a !== $b) {
|
||||
var_dump("something went wrong: $a !== $b");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// generate the function
|
||||
$str = "<?php\nfunction x(";
|
||||
|
||||
for($i=0; $i < $limit; ++$i) {
|
||||
$str .= '$v'.dechex($i).($i===($limit-1) ? '' : ',');
|
||||
}
|
||||
|
||||
$str .= ') {
|
||||
test($v42, \'42\');
|
||||
test(\'4000\', $v4000);
|
||||
test2($v300, \'300\');
|
||||
test($v0, \'0\'); // first
|
||||
test($v'.dechex($limit-1).", '".dechex($limit-1).'\'); // last
|
||||
test($v'.dechex($boundary).", '".dechex($boundary).'\'); //boundary
|
||||
test($v'.dechex($boundary+1).", '".dechex($boundary+1).'\'); //boundary+1
|
||||
test($v'.dechex($boundary-1).", '".dechex($boundary-1).'\'); //boundary-1
|
||||
}';
|
||||
|
||||
// generate the function call
|
||||
$str .= "\n\nx(";
|
||||
|
||||
for($i=0; $i< $limit; ++$i) {
|
||||
$str .= "'".dechex($i)."'".($i===($limit-1) ? '' : ',');
|
||||
}
|
||||
|
||||
$str .= ");\n";
|
||||
|
||||
$filename = dirname(__FILE__).'/010-file.php';
|
||||
file_put_contents(dirname(__FILE__).'/010-file.php', $str);
|
||||
unset($str);
|
||||
|
||||
include($filename);
|
||||
|
||||
echo "Done\n";
|
||||
|
||||
?><?php
|
||||
@unlink(dirname(__FILE__).'/010-file.php');
|
||||
?>
|
||||
@@ -1,8 +0,0 @@
|
||||
bool(true)
|
||||
bool(true)
|
||||
bool(true)
|
||||
bool(true)
|
||||
bool(true)
|
||||
bool(true)
|
||||
bool(true)
|
||||
Done
|
||||
@@ -1,33 +0,0 @@
|
||||
<?php
|
||||
|
||||
define("MAX_64Bit", 9223372036854775807);
|
||||
define("MAX_32Bit", 2147483647);
|
||||
define("MIN_64Bit", -9223372036854775807 - 1);
|
||||
define("MIN_32Bit", -2147483647 - 1);
|
||||
|
||||
$longVals = array(
|
||||
MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit,
|
||||
MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1,
|
||||
MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1
|
||||
);
|
||||
|
||||
$otherVals = array(0, 1, -1, 7, 9, 65, -44, MAX_32Bit, MAX_64Bit);
|
||||
|
||||
error_reporting(E_ERROR);
|
||||
|
||||
foreach ($longVals as $longVal) {
|
||||
foreach($otherVals as $otherVal) {
|
||||
echo "--- testing: $longVal / $otherVal ---\n";
|
||||
var_dump($longVal/$otherVal);
|
||||
}
|
||||
}
|
||||
|
||||
foreach ($otherVals as $otherVal) {
|
||||
foreach($longVals as $longVal) {
|
||||
echo "--- testing: $otherVal / $longVal ---\n";
|
||||
var_dump($otherVal/$longVal);
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
===DONE===
|
||||
@@ -1,541 +0,0 @@
|
||||
--- testing: 9223372036854775807 / 0 ---
|
||||
bool(false)
|
||||
--- testing: 9223372036854775807 / 1 ---
|
||||
int(9223372036854775807)
|
||||
--- testing: 9223372036854775807 / -1 ---
|
||||
int(-9223372036854775807)
|
||||
--- testing: 9223372036854775807 / 7 ---
|
||||
int(1317624576693539401)
|
||||
--- testing: 9223372036854775807 / 9 ---
|
||||
float(1.0248191152061E+18)
|
||||
--- testing: 9223372036854775807 / 65 ---
|
||||
float(1.4189803133623E+17)
|
||||
--- testing: 9223372036854775807 / -44 ---
|
||||
float(-2.096220917467E+17)
|
||||
--- testing: 9223372036854775807 / 2147483647 ---
|
||||
float(4294967298)
|
||||
--- testing: 9223372036854775807 / 9223372036854775807 ---
|
||||
int(1)
|
||||
--- testing: -9223372036854775808 / 0 ---
|
||||
bool(false)
|
||||
--- testing: -9223372036854775808 / 1 ---
|
||||
int(-9223372036854775808)
|
||||
--- testing: -9223372036854775808 / -1 ---
|
||||
float(9.2233720368548E+18)
|
||||
--- testing: -9223372036854775808 / 7 ---
|
||||
float(-1.3176245766935E+18)
|
||||
--- testing: -9223372036854775808 / 9 ---
|
||||
float(-1.0248191152061E+18)
|
||||
--- testing: -9223372036854775808 / 65 ---
|
||||
float(-1.4189803133623E+17)
|
||||
--- testing: -9223372036854775808 / -44 ---
|
||||
float(2.096220917467E+17)
|
||||
--- testing: -9223372036854775808 / 2147483647 ---
|
||||
float(-4294967298)
|
||||
--- testing: -9223372036854775808 / 9223372036854775807 ---
|
||||
float(-1)
|
||||
--- testing: 2147483647 / 0 ---
|
||||
bool(false)
|
||||
--- testing: 2147483647 / 1 ---
|
||||
int(2147483647)
|
||||
--- testing: 2147483647 / -1 ---
|
||||
int(-2147483647)
|
||||
--- testing: 2147483647 / 7 ---
|
||||
float(306783378.14286)
|
||||
--- testing: 2147483647 / 9 ---
|
||||
float(238609294.11111)
|
||||
--- testing: 2147483647 / 65 ---
|
||||
float(33038209.953846)
|
||||
--- testing: 2147483647 / -44 ---
|
||||
float(-48806446.522727)
|
||||
--- testing: 2147483647 / 2147483647 ---
|
||||
int(1)
|
||||
--- testing: 2147483647 / 9223372036854775807 ---
|
||||
float(2.3283064354545E-10)
|
||||
--- testing: -2147483648 / 0 ---
|
||||
bool(false)
|
||||
--- testing: -2147483648 / 1 ---
|
||||
int(-2147483648)
|
||||
--- testing: -2147483648 / -1 ---
|
||||
int(2147483648)
|
||||
--- testing: -2147483648 / 7 ---
|
||||
float(-306783378.28571)
|
||||
--- testing: -2147483648 / 9 ---
|
||||
float(-238609294.22222)
|
||||
--- testing: -2147483648 / 65 ---
|
||||
float(-33038209.969231)
|
||||
--- testing: -2147483648 / -44 ---
|
||||
float(48806446.545455)
|
||||
--- testing: -2147483648 / 2147483647 ---
|
||||
float(-1.0000000004657)
|
||||
--- testing: -2147483648 / 9223372036854775807 ---
|
||||
float(-2.3283064365387E-10)
|
||||
--- testing: 9223372034707292160 / 0 ---
|
||||
bool(false)
|
||||
--- testing: 9223372034707292160 / 1 ---
|
||||
int(9223372034707292160)
|
||||
--- testing: 9223372034707292160 / -1 ---
|
||||
int(-9223372034707292160)
|
||||
--- testing: 9223372034707292160 / 7 ---
|
||||
float(1.3176245763868E+18)
|
||||
--- testing: 9223372034707292160 / 9 ---
|
||||
float(1.0248191149675E+18)
|
||||
--- testing: 9223372034707292160 / 65 ---
|
||||
float(1.4189803130319E+17)
|
||||
--- testing: 9223372034707292160 / -44 ---
|
||||
float(-2.0962209169789E+17)
|
||||
--- testing: 9223372034707292160 / 2147483647 ---
|
||||
float(4294967297)
|
||||
--- testing: 9223372034707292160 / 9223372036854775807 ---
|
||||
float(0.99999999976717)
|
||||
--- testing: -9223372034707292160 / 0 ---
|
||||
bool(false)
|
||||
--- testing: -9223372034707292160 / 1 ---
|
||||
int(-9223372034707292160)
|
||||
--- testing: -9223372034707292160 / -1 ---
|
||||
int(9223372034707292160)
|
||||
--- testing: -9223372034707292160 / 7 ---
|
||||
float(-1.3176245763868E+18)
|
||||
--- testing: -9223372034707292160 / 9 ---
|
||||
float(-1.0248191149675E+18)
|
||||
--- testing: -9223372034707292160 / 65 ---
|
||||
float(-1.4189803130319E+17)
|
||||
--- testing: -9223372034707292160 / -44 ---
|
||||
float(2.0962209169789E+17)
|
||||
--- testing: -9223372034707292160 / 2147483647 ---
|
||||
float(-4294967297)
|
||||
--- testing: -9223372034707292160 / 9223372036854775807 ---
|
||||
float(-0.99999999976717)
|
||||
--- testing: 2147483648 / 0 ---
|
||||
bool(false)
|
||||
--- testing: 2147483648 / 1 ---
|
||||
int(2147483648)
|
||||
--- testing: 2147483648 / -1 ---
|
||||
int(-2147483648)
|
||||
--- testing: 2147483648 / 7 ---
|
||||
float(306783378.28571)
|
||||
--- testing: 2147483648 / 9 ---
|
||||
float(238609294.22222)
|
||||
--- testing: 2147483648 / 65 ---
|
||||
float(33038209.969231)
|
||||
--- testing: 2147483648 / -44 ---
|
||||
float(-48806446.545455)
|
||||
--- testing: 2147483648 / 2147483647 ---
|
||||
float(1.0000000004657)
|
||||
--- testing: 2147483648 / 9223372036854775807 ---
|
||||
float(2.3283064365387E-10)
|
||||
--- testing: -2147483649 / 0 ---
|
||||
bool(false)
|
||||
--- testing: -2147483649 / 1 ---
|
||||
int(-2147483649)
|
||||
--- testing: -2147483649 / -1 ---
|
||||
int(2147483649)
|
||||
--- testing: -2147483649 / 7 ---
|
||||
float(-306783378.42857)
|
||||
--- testing: -2147483649 / 9 ---
|
||||
float(-238609294.33333)
|
||||
--- testing: -2147483649 / 65 ---
|
||||
float(-33038209.984615)
|
||||
--- testing: -2147483649 / -44 ---
|
||||
float(48806446.568182)
|
||||
--- testing: -2147483649 / 2147483647 ---
|
||||
float(-1.0000000009313)
|
||||
--- testing: -2147483649 / 9223372036854775807 ---
|
||||
float(-2.3283064376229E-10)
|
||||
--- testing: 4294967294 / 0 ---
|
||||
bool(false)
|
||||
--- testing: 4294967294 / 1 ---
|
||||
int(4294967294)
|
||||
--- testing: 4294967294 / -1 ---
|
||||
int(-4294967294)
|
||||
--- testing: 4294967294 / 7 ---
|
||||
float(613566756.28571)
|
||||
--- testing: 4294967294 / 9 ---
|
||||
float(477218588.22222)
|
||||
--- testing: 4294967294 / 65 ---
|
||||
float(66076419.907692)
|
||||
--- testing: 4294967294 / -44 ---
|
||||
float(-97612893.045455)
|
||||
--- testing: 4294967294 / 2147483647 ---
|
||||
int(2)
|
||||
--- testing: 4294967294 / 9223372036854775807 ---
|
||||
float(4.656612870909E-10)
|
||||
--- testing: 4294967295 / 0 ---
|
||||
bool(false)
|
||||
--- testing: 4294967295 / 1 ---
|
||||
int(4294967295)
|
||||
--- testing: 4294967295 / -1 ---
|
||||
int(-4294967295)
|
||||
--- testing: 4294967295 / 7 ---
|
||||
float(613566756.42857)
|
||||
--- testing: 4294967295 / 9 ---
|
||||
float(477218588.33333)
|
||||
--- testing: 4294967295 / 65 ---
|
||||
float(66076419.923077)
|
||||
--- testing: 4294967295 / -44 ---
|
||||
float(-97612893.068182)
|
||||
--- testing: 4294967295 / 2147483647 ---
|
||||
float(2.0000000004657)
|
||||
--- testing: 4294967295 / 9223372036854775807 ---
|
||||
float(4.6566128719932E-10)
|
||||
--- testing: 4294967293 / 0 ---
|
||||
bool(false)
|
||||
--- testing: 4294967293 / 1 ---
|
||||
int(4294967293)
|
||||
--- testing: 4294967293 / -1 ---
|
||||
int(-4294967293)
|
||||
--- testing: 4294967293 / 7 ---
|
||||
float(613566756.14286)
|
||||
--- testing: 4294967293 / 9 ---
|
||||
float(477218588.11111)
|
||||
--- testing: 4294967293 / 65 ---
|
||||
float(66076419.892308)
|
||||
--- testing: 4294967293 / -44 ---
|
||||
float(-97612893.022727)
|
||||
--- testing: 4294967293 / 2147483647 ---
|
||||
float(1.9999999995343)
|
||||
--- testing: 4294967293 / 9223372036854775807 ---
|
||||
float(4.6566128698248E-10)
|
||||
--- testing: 9223372036854775806 / 0 ---
|
||||
bool(false)
|
||||
--- testing: 9223372036854775806 / 1 ---
|
||||
int(9223372036854775806)
|
||||
--- testing: 9223372036854775806 / -1 ---
|
||||
int(-9223372036854775806)
|
||||
--- testing: 9223372036854775806 / 7 ---
|
||||
float(1.3176245766935E+18)
|
||||
--- testing: 9223372036854775806 / 9 ---
|
||||
float(1.0248191152061E+18)
|
||||
--- testing: 9223372036854775806 / 65 ---
|
||||
float(1.4189803133623E+17)
|
||||
--- testing: 9223372036854775806 / -44 ---
|
||||
float(-2.096220917467E+17)
|
||||
--- testing: 9223372036854775806 / 2147483647 ---
|
||||
int(4294967298)
|
||||
--- testing: 9223372036854775806 / 9223372036854775807 ---
|
||||
float(1)
|
||||
--- testing: 9.2233720368548E+18 / 0 ---
|
||||
bool(false)
|
||||
--- testing: 9.2233720368548E+18 / 1 ---
|
||||
float(9.2233720368548E+18)
|
||||
--- testing: 9.2233720368548E+18 / -1 ---
|
||||
float(-9.2233720368548E+18)
|
||||
--- testing: 9.2233720368548E+18 / 7 ---
|
||||
float(1.3176245766935E+18)
|
||||
--- testing: 9.2233720368548E+18 / 9 ---
|
||||
float(1.0248191152061E+18)
|
||||
--- testing: 9.2233720368548E+18 / 65 ---
|
||||
float(1.4189803133623E+17)
|
||||
--- testing: 9.2233720368548E+18 / -44 ---
|
||||
float(-2.096220917467E+17)
|
||||
--- testing: 9.2233720368548E+18 / 2147483647 ---
|
||||
float(4294967298)
|
||||
--- testing: 9.2233720368548E+18 / 9223372036854775807 ---
|
||||
float(1)
|
||||
--- testing: -9223372036854775807 / 0 ---
|
||||
bool(false)
|
||||
--- testing: -9223372036854775807 / 1 ---
|
||||
int(-9223372036854775807)
|
||||
--- testing: -9223372036854775807 / -1 ---
|
||||
int(9223372036854775807)
|
||||
--- testing: -9223372036854775807 / 7 ---
|
||||
int(-1317624576693539401)
|
||||
--- testing: -9223372036854775807 / 9 ---
|
||||
float(-1.0248191152061E+18)
|
||||
--- testing: -9223372036854775807 / 65 ---
|
||||
float(-1.4189803133623E+17)
|
||||
--- testing: -9223372036854775807 / -44 ---
|
||||
float(2.096220917467E+17)
|
||||
--- testing: -9223372036854775807 / 2147483647 ---
|
||||
float(-4294967298)
|
||||
--- testing: -9223372036854775807 / 9223372036854775807 ---
|
||||
int(-1)
|
||||
--- testing: -9.2233720368548E+18 / 0 ---
|
||||
bool(false)
|
||||
--- testing: -9.2233720368548E+18 / 1 ---
|
||||
float(-9.2233720368548E+18)
|
||||
--- testing: -9.2233720368548E+18 / -1 ---
|
||||
float(9.2233720368548E+18)
|
||||
--- testing: -9.2233720368548E+18 / 7 ---
|
||||
float(-1.3176245766935E+18)
|
||||
--- testing: -9.2233720368548E+18 / 9 ---
|
||||
float(-1.0248191152061E+18)
|
||||
--- testing: -9.2233720368548E+18 / 65 ---
|
||||
float(-1.4189803133623E+17)
|
||||
--- testing: -9.2233720368548E+18 / -44 ---
|
||||
float(2.096220917467E+17)
|
||||
--- testing: -9.2233720368548E+18 / 2147483647 ---
|
||||
float(-4294967298)
|
||||
--- testing: -9.2233720368548E+18 / 9223372036854775807 ---
|
||||
float(-1)
|
||||
--- testing: 0 / 9223372036854775807 ---
|
||||
int(0)
|
||||
--- testing: 0 / -9223372036854775808 ---
|
||||
int(0)
|
||||
--- testing: 0 / 2147483647 ---
|
||||
int(0)
|
||||
--- testing: 0 / -2147483648 ---
|
||||
int(0)
|
||||
--- testing: 0 / 9223372034707292160 ---
|
||||
int(0)
|
||||
--- testing: 0 / -9223372034707292160 ---
|
||||
int(0)
|
||||
--- testing: 0 / 2147483648 ---
|
||||
int(0)
|
||||
--- testing: 0 / -2147483649 ---
|
||||
int(0)
|
||||
--- testing: 0 / 4294967294 ---
|
||||
int(0)
|
||||
--- testing: 0 / 4294967295 ---
|
||||
int(0)
|
||||
--- testing: 0 / 4294967293 ---
|
||||
int(0)
|
||||
--- testing: 0 / 9223372036854775806 ---
|
||||
int(0)
|
||||
--- testing: 0 / 9.2233720368548E+18 ---
|
||||
float(0)
|
||||
--- testing: 0 / -9223372036854775807 ---
|
||||
int(0)
|
||||
--- testing: 0 / -9.2233720368548E+18 ---
|
||||
float(-0)
|
||||
--- testing: 1 / 9223372036854775807 ---
|
||||
float(1.0842021724855E-19)
|
||||
--- testing: 1 / -9223372036854775808 ---
|
||||
float(-1.0842021724855E-19)
|
||||
--- testing: 1 / 2147483647 ---
|
||||
float(4.6566128752458E-10)
|
||||
--- testing: 1 / -2147483648 ---
|
||||
float(-4.6566128730774E-10)
|
||||
--- testing: 1 / 9223372034707292160 ---
|
||||
float(1.0842021727379E-19)
|
||||
--- testing: 1 / -9223372034707292160 ---
|
||||
float(-1.0842021727379E-19)
|
||||
--- testing: 1 / 2147483648 ---
|
||||
float(4.6566128730774E-10)
|
||||
--- testing: 1 / -2147483649 ---
|
||||
float(-4.656612870909E-10)
|
||||
--- testing: 1 / 4294967294 ---
|
||||
float(2.3283064376229E-10)
|
||||
--- testing: 1 / 4294967295 ---
|
||||
float(2.3283064370808E-10)
|
||||
--- testing: 1 / 4294967293 ---
|
||||
float(2.328306438165E-10)
|
||||
--- testing: 1 / 9223372036854775806 ---
|
||||
float(1.0842021724855E-19)
|
||||
--- testing: 1 / 9.2233720368548E+18 ---
|
||||
float(1.0842021724855E-19)
|
||||
--- testing: 1 / -9223372036854775807 ---
|
||||
float(-1.0842021724855E-19)
|
||||
--- testing: 1 / -9.2233720368548E+18 ---
|
||||
float(-1.0842021724855E-19)
|
||||
--- testing: -1 / 9223372036854775807 ---
|
||||
float(-1.0842021724855E-19)
|
||||
--- testing: -1 / -9223372036854775808 ---
|
||||
float(1.0842021724855E-19)
|
||||
--- testing: -1 / 2147483647 ---
|
||||
float(-4.6566128752458E-10)
|
||||
--- testing: -1 / -2147483648 ---
|
||||
float(4.6566128730774E-10)
|
||||
--- testing: -1 / 9223372034707292160 ---
|
||||
float(-1.0842021727379E-19)
|
||||
--- testing: -1 / -9223372034707292160 ---
|
||||
float(1.0842021727379E-19)
|
||||
--- testing: -1 / 2147483648 ---
|
||||
float(-4.6566128730774E-10)
|
||||
--- testing: -1 / -2147483649 ---
|
||||
float(4.656612870909E-10)
|
||||
--- testing: -1 / 4294967294 ---
|
||||
float(-2.3283064376229E-10)
|
||||
--- testing: -1 / 4294967295 ---
|
||||
float(-2.3283064370808E-10)
|
||||
--- testing: -1 / 4294967293 ---
|
||||
float(-2.328306438165E-10)
|
||||
--- testing: -1 / 9223372036854775806 ---
|
||||
float(-1.0842021724855E-19)
|
||||
--- testing: -1 / 9.2233720368548E+18 ---
|
||||
float(-1.0842021724855E-19)
|
||||
--- testing: -1 / -9223372036854775807 ---
|
||||
float(1.0842021724855E-19)
|
||||
--- testing: -1 / -9.2233720368548E+18 ---
|
||||
float(1.0842021724855E-19)
|
||||
--- testing: 7 / 9223372036854775807 ---
|
||||
float(7.5894152073985E-19)
|
||||
--- testing: 7 / -9223372036854775808 ---
|
||||
float(-7.5894152073985E-19)
|
||||
--- testing: 7 / 2147483647 ---
|
||||
float(3.2596290126721E-9)
|
||||
--- testing: 7 / -2147483648 ---
|
||||
float(-3.2596290111542E-9)
|
||||
--- testing: 7 / 9223372034707292160 ---
|
||||
float(7.5894152091656E-19)
|
||||
--- testing: 7 / -9223372034707292160 ---
|
||||
float(-7.5894152091656E-19)
|
||||
--- testing: 7 / 2147483648 ---
|
||||
float(3.2596290111542E-9)
|
||||
--- testing: 7 / -2147483649 ---
|
||||
float(-3.2596290096363E-9)
|
||||
--- testing: 7 / 4294967294 ---
|
||||
float(1.629814506336E-9)
|
||||
--- testing: 7 / 4294967295 ---
|
||||
float(1.6298145059566E-9)
|
||||
--- testing: 7 / 4294967293 ---
|
||||
float(1.6298145067155E-9)
|
||||
--- testing: 7 / 9223372036854775806 ---
|
||||
float(7.5894152073985E-19)
|
||||
--- testing: 7 / 9.2233720368548E+18 ---
|
||||
float(7.5894152073985E-19)
|
||||
--- testing: 7 / -9223372036854775807 ---
|
||||
float(-7.5894152073985E-19)
|
||||
--- testing: 7 / -9.2233720368548E+18 ---
|
||||
float(-7.5894152073985E-19)
|
||||
--- testing: 9 / 9223372036854775807 ---
|
||||
float(9.7578195523695E-19)
|
||||
--- testing: 9 / -9223372036854775808 ---
|
||||
float(-9.7578195523695E-19)
|
||||
--- testing: 9 / 2147483647 ---
|
||||
float(4.1909515877212E-9)
|
||||
--- testing: 9 / -2147483648 ---
|
||||
float(-4.1909515857697E-9)
|
||||
--- testing: 9 / 9223372034707292160 ---
|
||||
float(9.7578195546415E-19)
|
||||
--- testing: 9 / -9223372034707292160 ---
|
||||
float(-9.7578195546415E-19)
|
||||
--- testing: 9 / 2147483648 ---
|
||||
float(4.1909515857697E-9)
|
||||
--- testing: 9 / -2147483649 ---
|
||||
float(-4.1909515838181E-9)
|
||||
--- testing: 9 / 4294967294 ---
|
||||
float(2.0954757938606E-9)
|
||||
--- testing: 9 / 4294967295 ---
|
||||
float(2.0954757933727E-9)
|
||||
--- testing: 9 / 4294967293 ---
|
||||
float(2.0954757943485E-9)
|
||||
--- testing: 9 / 9223372036854775806 ---
|
||||
float(9.7578195523695E-19)
|
||||
--- testing: 9 / 9.2233720368548E+18 ---
|
||||
float(9.7578195523695E-19)
|
||||
--- testing: 9 / -9223372036854775807 ---
|
||||
float(-9.7578195523695E-19)
|
||||
--- testing: 9 / -9.2233720368548E+18 ---
|
||||
float(-9.7578195523695E-19)
|
||||
--- testing: 65 / 9223372036854775807 ---
|
||||
float(7.0473141211558E-18)
|
||||
--- testing: 65 / -9223372036854775808 ---
|
||||
float(-7.0473141211558E-18)
|
||||
--- testing: 65 / 2147483647 ---
|
||||
float(3.0267983689098E-8)
|
||||
--- testing: 65 / -2147483648 ---
|
||||
float(-3.0267983675003E-8)
|
||||
--- testing: 65 / 9223372034707292160 ---
|
||||
float(7.0473141227966E-18)
|
||||
--- testing: 65 / -9223372034707292160 ---
|
||||
float(-7.0473141227966E-18)
|
||||
--- testing: 65 / 2147483648 ---
|
||||
float(3.0267983675003E-8)
|
||||
--- testing: 65 / -2147483649 ---
|
||||
float(-3.0267983660908E-8)
|
||||
--- testing: 65 / 4294967294 ---
|
||||
float(1.5133991844549E-8)
|
||||
--- testing: 65 / 4294967295 ---
|
||||
float(1.5133991841025E-8)
|
||||
--- testing: 65 / 4294967293 ---
|
||||
float(1.5133991848072E-8)
|
||||
--- testing: 65 / 9223372036854775806 ---
|
||||
float(7.0473141211558E-18)
|
||||
--- testing: 65 / 9.2233720368548E+18 ---
|
||||
float(7.0473141211558E-18)
|
||||
--- testing: 65 / -9223372036854775807 ---
|
||||
float(-7.0473141211558E-18)
|
||||
--- testing: 65 / -9.2233720368548E+18 ---
|
||||
float(-7.0473141211558E-18)
|
||||
--- testing: -44 / 9223372036854775807 ---
|
||||
float(-4.7704895589362E-18)
|
||||
--- testing: -44 / -9223372036854775808 ---
|
||||
float(4.7704895589362E-18)
|
||||
--- testing: -44 / 2147483647 ---
|
||||
float(-2.0489096651082E-8)
|
||||
--- testing: -44 / -2147483648 ---
|
||||
float(2.0489096641541E-8)
|
||||
--- testing: -44 / 9223372034707292160 ---
|
||||
float(-4.7704895600469E-18)
|
||||
--- testing: -44 / -9223372034707292160 ---
|
||||
float(4.7704895600469E-18)
|
||||
--- testing: -44 / 2147483648 ---
|
||||
float(-2.0489096641541E-8)
|
||||
--- testing: -44 / -2147483649 ---
|
||||
float(2.0489096632E-8)
|
||||
--- testing: -44 / 4294967294 ---
|
||||
float(-1.0244548325541E-8)
|
||||
--- testing: -44 / 4294967295 ---
|
||||
float(-1.0244548323156E-8)
|
||||
--- testing: -44 / 4294967293 ---
|
||||
float(-1.0244548327926E-8)
|
||||
--- testing: -44 / 9223372036854775806 ---
|
||||
float(-4.7704895589362E-18)
|
||||
--- testing: -44 / 9.2233720368548E+18 ---
|
||||
float(-4.7704895589362E-18)
|
||||
--- testing: -44 / -9223372036854775807 ---
|
||||
float(4.7704895589362E-18)
|
||||
--- testing: -44 / -9.2233720368548E+18 ---
|
||||
float(4.7704895589362E-18)
|
||||
--- testing: 2147483647 / 9223372036854775807 ---
|
||||
float(2.3283064354545E-10)
|
||||
--- testing: 2147483647 / -9223372036854775808 ---
|
||||
float(-2.3283064354545E-10)
|
||||
--- testing: 2147483647 / 2147483647 ---
|
||||
int(1)
|
||||
--- testing: 2147483647 / -2147483648 ---
|
||||
float(-0.99999999953434)
|
||||
--- testing: 2147483647 / 9223372034707292160 ---
|
||||
float(2.3283064359966E-10)
|
||||
--- testing: 2147483647 / -9223372034707292160 ---
|
||||
float(-2.3283064359966E-10)
|
||||
--- testing: 2147483647 / 2147483648 ---
|
||||
float(0.99999999953434)
|
||||
--- testing: 2147483647 / -2147483649 ---
|
||||
float(-0.99999999906868)
|
||||
--- testing: 2147483647 / 4294967294 ---
|
||||
float(0.5)
|
||||
--- testing: 2147483647 / 4294967295 ---
|
||||
float(0.49999999988358)
|
||||
--- testing: 2147483647 / 4294967293 ---
|
||||
float(0.50000000011642)
|
||||
--- testing: 2147483647 / 9223372036854775806 ---
|
||||
float(2.3283064354545E-10)
|
||||
--- testing: 2147483647 / 9.2233720368548E+18 ---
|
||||
float(2.3283064354545E-10)
|
||||
--- testing: 2147483647 / -9223372036854775807 ---
|
||||
float(-2.3283064354545E-10)
|
||||
--- testing: 2147483647 / -9.2233720368548E+18 ---
|
||||
float(-2.3283064354545E-10)
|
||||
--- testing: 9223372036854775807 / 9223372036854775807 ---
|
||||
int(1)
|
||||
--- testing: 9223372036854775807 / -9223372036854775808 ---
|
||||
float(-1)
|
||||
--- testing: 9223372036854775807 / 2147483647 ---
|
||||
float(4294967298)
|
||||
--- testing: 9223372036854775807 / -2147483648 ---
|
||||
float(-4294967296)
|
||||
--- testing: 9223372036854775807 / 9223372034707292160 ---
|
||||
float(1.0000000002328)
|
||||
--- testing: 9223372036854775807 / -9223372034707292160 ---
|
||||
float(-1.0000000002328)
|
||||
--- testing: 9223372036854775807 / 2147483648 ---
|
||||
float(4294967296)
|
||||
--- testing: 9223372036854775807 / -2147483649 ---
|
||||
float(-4294967294)
|
||||
--- testing: 9223372036854775807 / 4294967294 ---
|
||||
float(2147483649)
|
||||
--- testing: 9223372036854775807 / 4294967295 ---
|
||||
float(2147483648.5)
|
||||
--- testing: 9223372036854775807 / 4294967293 ---
|
||||
float(2147483649.5)
|
||||
--- testing: 9223372036854775807 / 9223372036854775806 ---
|
||||
float(1)
|
||||
--- testing: 9223372036854775807 / 9.2233720368548E+18 ---
|
||||
float(1)
|
||||
--- testing: 9223372036854775807 / -9223372036854775807 ---
|
||||
int(-1)
|
||||
--- testing: 9223372036854775807 / -9.2233720368548E+18 ---
|
||||
float(-1)
|
||||
===DONE===
|
||||
@@ -1,33 +0,0 @@
|
||||
<?php
|
||||
|
||||
define("MAX_64Bit", 9223372036854775807);
|
||||
define("MAX_32Bit", 2147483647);
|
||||
define("MIN_64Bit", -9223372036854775807 - 1);
|
||||
define("MIN_32Bit", -2147483647 - 1);
|
||||
|
||||
$longVals = array(
|
||||
MAX_64Bit, MIN_64Bit, MAX_32Bit, MIN_32Bit, MAX_64Bit - MAX_32Bit, MIN_64Bit - MIN_32Bit,
|
||||
MAX_32Bit + 1, MIN_32Bit - 1, MAX_32Bit * 2, (MAX_32Bit * 2) + 1, (MAX_32Bit * 2) - 1,
|
||||
MAX_64Bit -1, MAX_64Bit + 1, MIN_64Bit + 1, MIN_64Bit - 1
|
||||
);
|
||||
|
||||
$otherVals = array(0, 1, -1, 7, 9, 65, -44, MAX_32Bit, MAX_64Bit);
|
||||
|
||||
error_reporting(E_ERROR);
|
||||
|
||||
foreach ($longVals as $longVal) {
|
||||
foreach($otherVals as $otherVal) {
|
||||
echo "--- testing: $longVal % $otherVal ---\n";
|
||||
var_dump($longVal%$otherVal);
|
||||
}
|
||||
}
|
||||
|
||||
foreach ($otherVals as $otherVal) {
|
||||
foreach($longVals as $longVal) {
|
||||
echo "--- testing: $otherVal % $longVal ---\n";
|
||||
var_dump($otherVal%$longVal);
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
===DONE===
|
||||
@@ -1,541 +0,0 @@
|
||||
--- testing: 9223372036854775807 % 0 ---
|
||||
bool(false)
|
||||
--- testing: 9223372036854775807 % 1 ---
|
||||
int(0)
|
||||
--- testing: 9223372036854775807 % -1 ---
|
||||
int(0)
|
||||
--- testing: 9223372036854775807 % 7 ---
|
||||
int(0)
|
||||
--- testing: 9223372036854775807 % 9 ---
|
||||
int(7)
|
||||
--- testing: 9223372036854775807 % 65 ---
|
||||
int(7)
|
||||
--- testing: 9223372036854775807 % -44 ---
|
||||
int(7)
|
||||
--- testing: 9223372036854775807 % 2147483647 ---
|
||||
int(1)
|
||||
--- testing: 9223372036854775807 % 9223372036854775807 ---
|
||||
int(0)
|
||||
--- testing: -9223372036854775808 % 0 ---
|
||||
bool(false)
|
||||
--- testing: -9223372036854775808 % 1 ---
|
||||
int(0)
|
||||
--- testing: -9223372036854775808 % -1 ---
|
||||
int(0)
|
||||
--- testing: -9223372036854775808 % 7 ---
|
||||
int(-1)
|
||||
--- testing: -9223372036854775808 % 9 ---
|
||||
int(-8)
|
||||
--- testing: -9223372036854775808 % 65 ---
|
||||
int(-8)
|
||||
--- testing: -9223372036854775808 % -44 ---
|
||||
int(-8)
|
||||
--- testing: -9223372036854775808 % 2147483647 ---
|
||||
int(-2)
|
||||
--- testing: -9223372036854775808 % 9223372036854775807 ---
|
||||
int(-1)
|
||||
--- testing: 2147483647 % 0 ---
|
||||
bool(false)
|
||||
--- testing: 2147483647 % 1 ---
|
||||
int(0)
|
||||
--- testing: 2147483647 % -1 ---
|
||||
int(0)
|
||||
--- testing: 2147483647 % 7 ---
|
||||
int(1)
|
||||
--- testing: 2147483647 % 9 ---
|
||||
int(1)
|
||||
--- testing: 2147483647 % 65 ---
|
||||
int(62)
|
||||
--- testing: 2147483647 % -44 ---
|
||||
int(23)
|
||||
--- testing: 2147483647 % 2147483647 ---
|
||||
int(0)
|
||||
--- testing: 2147483647 % 9223372036854775807 ---
|
||||
int(2147483647)
|
||||
--- testing: -2147483648 % 0 ---
|
||||
bool(false)
|
||||
--- testing: -2147483648 % 1 ---
|
||||
int(0)
|
||||
--- testing: -2147483648 % -1 ---
|
||||
int(0)
|
||||
--- testing: -2147483648 % 7 ---
|
||||
int(-2)
|
||||
--- testing: -2147483648 % 9 ---
|
||||
int(-2)
|
||||
--- testing: -2147483648 % 65 ---
|
||||
int(-63)
|
||||
--- testing: -2147483648 % -44 ---
|
||||
int(-24)
|
||||
--- testing: -2147483648 % 2147483647 ---
|
||||
int(-1)
|
||||
--- testing: -2147483648 % 9223372036854775807 ---
|
||||
int(-2147483648)
|
||||
--- testing: 9223372034707292160 % 0 ---
|
||||
bool(false)
|
||||
--- testing: 9223372034707292160 % 1 ---
|
||||
int(0)
|
||||
--- testing: 9223372034707292160 % -1 ---
|
||||
int(0)
|
||||
--- testing: 9223372034707292160 % 7 ---
|
||||
int(6)
|
||||
--- testing: 9223372034707292160 % 9 ---
|
||||
int(6)
|
||||
--- testing: 9223372034707292160 % 65 ---
|
||||
int(10)
|
||||
--- testing: 9223372034707292160 % -44 ---
|
||||
int(28)
|
||||
--- testing: 9223372034707292160 % 2147483647 ---
|
||||
int(1)
|
||||
--- testing: 9223372034707292160 % 9223372036854775807 ---
|
||||
int(9223372034707292160)
|
||||
--- testing: -9223372034707292160 % 0 ---
|
||||
bool(false)
|
||||
--- testing: -9223372034707292160 % 1 ---
|
||||
int(0)
|
||||
--- testing: -9223372034707292160 % -1 ---
|
||||
int(0)
|
||||
--- testing: -9223372034707292160 % 7 ---
|
||||
int(-6)
|
||||
--- testing: -9223372034707292160 % 9 ---
|
||||
int(-6)
|
||||
--- testing: -9223372034707292160 % 65 ---
|
||||
int(-10)
|
||||
--- testing: -9223372034707292160 % -44 ---
|
||||
int(-28)
|
||||
--- testing: -9223372034707292160 % 2147483647 ---
|
||||
int(-1)
|
||||
--- testing: -9223372034707292160 % 9223372036854775807 ---
|
||||
int(-9223372034707292160)
|
||||
--- testing: 2147483648 % 0 ---
|
||||
bool(false)
|
||||
--- testing: 2147483648 % 1 ---
|
||||
int(0)
|
||||
--- testing: 2147483648 % -1 ---
|
||||
int(0)
|
||||
--- testing: 2147483648 % 7 ---
|
||||
int(2)
|
||||
--- testing: 2147483648 % 9 ---
|
||||
int(2)
|
||||
--- testing: 2147483648 % 65 ---
|
||||
int(63)
|
||||
--- testing: 2147483648 % -44 ---
|
||||
int(24)
|
||||
--- testing: 2147483648 % 2147483647 ---
|
||||
int(1)
|
||||
--- testing: 2147483648 % 9223372036854775807 ---
|
||||
int(2147483648)
|
||||
--- testing: -2147483649 % 0 ---
|
||||
bool(false)
|
||||
--- testing: -2147483649 % 1 ---
|
||||
int(0)
|
||||
--- testing: -2147483649 % -1 ---
|
||||
int(0)
|
||||
--- testing: -2147483649 % 7 ---
|
||||
int(-3)
|
||||
--- testing: -2147483649 % 9 ---
|
||||
int(-3)
|
||||
--- testing: -2147483649 % 65 ---
|
||||
int(-64)
|
||||
--- testing: -2147483649 % -44 ---
|
||||
int(-25)
|
||||
--- testing: -2147483649 % 2147483647 ---
|
||||
int(-2)
|
||||
--- testing: -2147483649 % 9223372036854775807 ---
|
||||
int(-2147483649)
|
||||
--- testing: 4294967294 % 0 ---
|
||||
bool(false)
|
||||
--- testing: 4294967294 % 1 ---
|
||||
int(0)
|
||||
--- testing: 4294967294 % -1 ---
|
||||
int(0)
|
||||
--- testing: 4294967294 % 7 ---
|
||||
int(2)
|
||||
--- testing: 4294967294 % 9 ---
|
||||
int(2)
|
||||
--- testing: 4294967294 % 65 ---
|
||||
int(59)
|
||||
--- testing: 4294967294 % -44 ---
|
||||
int(2)
|
||||
--- testing: 4294967294 % 2147483647 ---
|
||||
int(0)
|
||||
--- testing: 4294967294 % 9223372036854775807 ---
|
||||
int(4294967294)
|
||||
--- testing: 4294967295 % 0 ---
|
||||
bool(false)
|
||||
--- testing: 4294967295 % 1 ---
|
||||
int(0)
|
||||
--- testing: 4294967295 % -1 ---
|
||||
int(0)
|
||||
--- testing: 4294967295 % 7 ---
|
||||
int(3)
|
||||
--- testing: 4294967295 % 9 ---
|
||||
int(3)
|
||||
--- testing: 4294967295 % 65 ---
|
||||
int(60)
|
||||
--- testing: 4294967295 % -44 ---
|
||||
int(3)
|
||||
--- testing: 4294967295 % 2147483647 ---
|
||||
int(1)
|
||||
--- testing: 4294967295 % 9223372036854775807 ---
|
||||
int(4294967295)
|
||||
--- testing: 4294967293 % 0 ---
|
||||
bool(false)
|
||||
--- testing: 4294967293 % 1 ---
|
||||
int(0)
|
||||
--- testing: 4294967293 % -1 ---
|
||||
int(0)
|
||||
--- testing: 4294967293 % 7 ---
|
||||
int(1)
|
||||
--- testing: 4294967293 % 9 ---
|
||||
int(1)
|
||||
--- testing: 4294967293 % 65 ---
|
||||
int(58)
|
||||
--- testing: 4294967293 % -44 ---
|
||||
int(1)
|
||||
--- testing: 4294967293 % 2147483647 ---
|
||||
int(2147483646)
|
||||
--- testing: 4294967293 % 9223372036854775807 ---
|
||||
int(4294967293)
|
||||
--- testing: 9223372036854775806 % 0 ---
|
||||
bool(false)
|
||||
--- testing: 9223372036854775806 % 1 ---
|
||||
int(0)
|
||||
--- testing: 9223372036854775806 % -1 ---
|
||||
int(0)
|
||||
--- testing: 9223372036854775806 % 7 ---
|
||||
int(6)
|
||||
--- testing: 9223372036854775806 % 9 ---
|
||||
int(6)
|
||||
--- testing: 9223372036854775806 % 65 ---
|
||||
int(6)
|
||||
--- testing: 9223372036854775806 % -44 ---
|
||||
int(6)
|
||||
--- testing: 9223372036854775806 % 2147483647 ---
|
||||
int(0)
|
||||
--- testing: 9223372036854775806 % 9223372036854775807 ---
|
||||
int(9223372036854775806)
|
||||
--- testing: 9.2233720368548E+18 % 0 ---
|
||||
bool(false)
|
||||
--- testing: 9.2233720368548E+18 % 1 ---
|
||||
int(0)
|
||||
--- testing: 9.2233720368548E+18 % -1 ---
|
||||
int(0)
|
||||
--- testing: 9.2233720368548E+18 % 7 ---
|
||||
int(-1)
|
||||
--- testing: 9.2233720368548E+18 % 9 ---
|
||||
int(-8)
|
||||
--- testing: 9.2233720368548E+18 % 65 ---
|
||||
int(-8)
|
||||
--- testing: 9.2233720368548E+18 % -44 ---
|
||||
int(-8)
|
||||
--- testing: 9.2233720368548E+18 % 2147483647 ---
|
||||
int(-2)
|
||||
--- testing: 9.2233720368548E+18 % 9223372036854775807 ---
|
||||
int(-1)
|
||||
--- testing: -9223372036854775807 % 0 ---
|
||||
bool(false)
|
||||
--- testing: -9223372036854775807 % 1 ---
|
||||
int(0)
|
||||
--- testing: -9223372036854775807 % -1 ---
|
||||
int(0)
|
||||
--- testing: -9223372036854775807 % 7 ---
|
||||
int(0)
|
||||
--- testing: -9223372036854775807 % 9 ---
|
||||
int(-7)
|
||||
--- testing: -9223372036854775807 % 65 ---
|
||||
int(-7)
|
||||
--- testing: -9223372036854775807 % -44 ---
|
||||
int(-7)
|
||||
--- testing: -9223372036854775807 % 2147483647 ---
|
||||
int(-1)
|
||||
--- testing: -9223372036854775807 % 9223372036854775807 ---
|
||||
int(0)
|
||||
--- testing: -9.2233720368548E+18 % 0 ---
|
||||
bool(false)
|
||||
--- testing: -9.2233720368548E+18 % 1 ---
|
||||
int(0)
|
||||
--- testing: -9.2233720368548E+18 % -1 ---
|
||||
int(0)
|
||||
--- testing: -9.2233720368548E+18 % 7 ---
|
||||
int(-1)
|
||||
--- testing: -9.2233720368548E+18 % 9 ---
|
||||
int(-8)
|
||||
--- testing: -9.2233720368548E+18 % 65 ---
|
||||
int(-8)
|
||||
--- testing: -9.2233720368548E+18 % -44 ---
|
||||
int(-8)
|
||||
--- testing: -9.2233720368548E+18 % 2147483647 ---
|
||||
int(-2)
|
||||
--- testing: -9.2233720368548E+18 % 9223372036854775807 ---
|
||||
int(-1)
|
||||
--- testing: 0 % 9223372036854775807 ---
|
||||
int(0)
|
||||
--- testing: 0 % -9223372036854775808 ---
|
||||
int(0)
|
||||
--- testing: 0 % 2147483647 ---
|
||||
int(0)
|
||||
--- testing: 0 % -2147483648 ---
|
||||
int(0)
|
||||
--- testing: 0 % 9223372034707292160 ---
|
||||
int(0)
|
||||
--- testing: 0 % -9223372034707292160 ---
|
||||
int(0)
|
||||
--- testing: 0 % 2147483648 ---
|
||||
int(0)
|
||||
--- testing: 0 % -2147483649 ---
|
||||
int(0)
|
||||
--- testing: 0 % 4294967294 ---
|
||||
int(0)
|
||||
--- testing: 0 % 4294967295 ---
|
||||
int(0)
|
||||
--- testing: 0 % 4294967293 ---
|
||||
int(0)
|
||||
--- testing: 0 % 9223372036854775806 ---
|
||||
int(0)
|
||||
--- testing: 0 % 9.2233720368548E+18 ---
|
||||
int(0)
|
||||
--- testing: 0 % -9223372036854775807 ---
|
||||
int(0)
|
||||
--- testing: 0 % -9.2233720368548E+18 ---
|
||||
int(0)
|
||||
--- testing: 1 % 9223372036854775807 ---
|
||||
int(1)
|
||||
--- testing: 1 % -9223372036854775808 ---
|
||||
int(1)
|
||||
--- testing: 1 % 2147483647 ---
|
||||
int(1)
|
||||
--- testing: 1 % -2147483648 ---
|
||||
int(1)
|
||||
--- testing: 1 % 9223372034707292160 ---
|
||||
int(1)
|
||||
--- testing: 1 % -9223372034707292160 ---
|
||||
int(1)
|
||||
--- testing: 1 % 2147483648 ---
|
||||
int(1)
|
||||
--- testing: 1 % -2147483649 ---
|
||||
int(1)
|
||||
--- testing: 1 % 4294967294 ---
|
||||
int(1)
|
||||
--- testing: 1 % 4294967295 ---
|
||||
int(1)
|
||||
--- testing: 1 % 4294967293 ---
|
||||
int(1)
|
||||
--- testing: 1 % 9223372036854775806 ---
|
||||
int(1)
|
||||
--- testing: 1 % 9.2233720368548E+18 ---
|
||||
int(1)
|
||||
--- testing: 1 % -9223372036854775807 ---
|
||||
int(1)
|
||||
--- testing: 1 % -9.2233720368548E+18 ---
|
||||
int(1)
|
||||
--- testing: -1 % 9223372036854775807 ---
|
||||
int(-1)
|
||||
--- testing: -1 % -9223372036854775808 ---
|
||||
int(-1)
|
||||
--- testing: -1 % 2147483647 ---
|
||||
int(-1)
|
||||
--- testing: -1 % -2147483648 ---
|
||||
int(-1)
|
||||
--- testing: -1 % 9223372034707292160 ---
|
||||
int(-1)
|
||||
--- testing: -1 % -9223372034707292160 ---
|
||||
int(-1)
|
||||
--- testing: -1 % 2147483648 ---
|
||||
int(-1)
|
||||
--- testing: -1 % -2147483649 ---
|
||||
int(-1)
|
||||
--- testing: -1 % 4294967294 ---
|
||||
int(-1)
|
||||
--- testing: -1 % 4294967295 ---
|
||||
int(-1)
|
||||
--- testing: -1 % 4294967293 ---
|
||||
int(-1)
|
||||
--- testing: -1 % 9223372036854775806 ---
|
||||
int(-1)
|
||||
--- testing: -1 % 9.2233720368548E+18 ---
|
||||
int(-1)
|
||||
--- testing: -1 % -9223372036854775807 ---
|
||||
int(-1)
|
||||
--- testing: -1 % -9.2233720368548E+18 ---
|
||||
int(-1)
|
||||
--- testing: 7 % 9223372036854775807 ---
|
||||
int(7)
|
||||
--- testing: 7 % -9223372036854775808 ---
|
||||
int(7)
|
||||
--- testing: 7 % 2147483647 ---
|
||||
int(7)
|
||||
--- testing: 7 % -2147483648 ---
|
||||
int(7)
|
||||
--- testing: 7 % 9223372034707292160 ---
|
||||
int(7)
|
||||
--- testing: 7 % -9223372034707292160 ---
|
||||
int(7)
|
||||
--- testing: 7 % 2147483648 ---
|
||||
int(7)
|
||||
--- testing: 7 % -2147483649 ---
|
||||
int(7)
|
||||
--- testing: 7 % 4294967294 ---
|
||||
int(7)
|
||||
--- testing: 7 % 4294967295 ---
|
||||
int(7)
|
||||
--- testing: 7 % 4294967293 ---
|
||||
int(7)
|
||||
--- testing: 7 % 9223372036854775806 ---
|
||||
int(7)
|
||||
--- testing: 7 % 9.2233720368548E+18 ---
|
||||
int(7)
|
||||
--- testing: 7 % -9223372036854775807 ---
|
||||
int(7)
|
||||
--- testing: 7 % -9.2233720368548E+18 ---
|
||||
int(7)
|
||||
--- testing: 9 % 9223372036854775807 ---
|
||||
int(9)
|
||||
--- testing: 9 % -9223372036854775808 ---
|
||||
int(9)
|
||||
--- testing: 9 % 2147483647 ---
|
||||
int(9)
|
||||
--- testing: 9 % -2147483648 ---
|
||||
int(9)
|
||||
--- testing: 9 % 9223372034707292160 ---
|
||||
int(9)
|
||||
--- testing: 9 % -9223372034707292160 ---
|
||||
int(9)
|
||||
--- testing: 9 % 2147483648 ---
|
||||
int(9)
|
||||
--- testing: 9 % -2147483649 ---
|
||||
int(9)
|
||||
--- testing: 9 % 4294967294 ---
|
||||
int(9)
|
||||
--- testing: 9 % 4294967295 ---
|
||||
int(9)
|
||||
--- testing: 9 % 4294967293 ---
|
||||
int(9)
|
||||
--- testing: 9 % 9223372036854775806 ---
|
||||
int(9)
|
||||
--- testing: 9 % 9.2233720368548E+18 ---
|
||||
int(9)
|
||||
--- testing: 9 % -9223372036854775807 ---
|
||||
int(9)
|
||||
--- testing: 9 % -9.2233720368548E+18 ---
|
||||
int(9)
|
||||
--- testing: 65 % 9223372036854775807 ---
|
||||
int(65)
|
||||
--- testing: 65 % -9223372036854775808 ---
|
||||
int(65)
|
||||
--- testing: 65 % 2147483647 ---
|
||||
int(65)
|
||||
--- testing: 65 % -2147483648 ---
|
||||
int(65)
|
||||
--- testing: 65 % 9223372034707292160 ---
|
||||
int(65)
|
||||
--- testing: 65 % -9223372034707292160 ---
|
||||
int(65)
|
||||
--- testing: 65 % 2147483648 ---
|
||||
int(65)
|
||||
--- testing: 65 % -2147483649 ---
|
||||
int(65)
|
||||
--- testing: 65 % 4294967294 ---
|
||||
int(65)
|
||||
--- testing: 65 % 4294967295 ---
|
||||
int(65)
|
||||
--- testing: 65 % 4294967293 ---
|
||||
int(65)
|
||||
--- testing: 65 % 9223372036854775806 ---
|
||||
int(65)
|
||||
--- testing: 65 % 9.2233720368548E+18 ---
|
||||
int(65)
|
||||
--- testing: 65 % -9223372036854775807 ---
|
||||
int(65)
|
||||
--- testing: 65 % -9.2233720368548E+18 ---
|
||||
int(65)
|
||||
--- testing: -44 % 9223372036854775807 ---
|
||||
int(-44)
|
||||
--- testing: -44 % -9223372036854775808 ---
|
||||
int(-44)
|
||||
--- testing: -44 % 2147483647 ---
|
||||
int(-44)
|
||||
--- testing: -44 % -2147483648 ---
|
||||
int(-44)
|
||||
--- testing: -44 % 9223372034707292160 ---
|
||||
int(-44)
|
||||
--- testing: -44 % -9223372034707292160 ---
|
||||
int(-44)
|
||||
--- testing: -44 % 2147483648 ---
|
||||
int(-44)
|
||||
--- testing: -44 % -2147483649 ---
|
||||
int(-44)
|
||||
--- testing: -44 % 4294967294 ---
|
||||
int(-44)
|
||||
--- testing: -44 % 4294967295 ---
|
||||
int(-44)
|
||||
--- testing: -44 % 4294967293 ---
|
||||
int(-44)
|
||||
--- testing: -44 % 9223372036854775806 ---
|
||||
int(-44)
|
||||
--- testing: -44 % 9.2233720368548E+18 ---
|
||||
int(-44)
|
||||
--- testing: -44 % -9223372036854775807 ---
|
||||
int(-44)
|
||||
--- testing: -44 % -9.2233720368548E+18 ---
|
||||
int(-44)
|
||||
--- testing: 2147483647 % 9223372036854775807 ---
|
||||
int(2147483647)
|
||||
--- testing: 2147483647 % -9223372036854775808 ---
|
||||
int(2147483647)
|
||||
--- testing: 2147483647 % 2147483647 ---
|
||||
int(0)
|
||||
--- testing: 2147483647 % -2147483648 ---
|
||||
int(2147483647)
|
||||
--- testing: 2147483647 % 9223372034707292160 ---
|
||||
int(2147483647)
|
||||
--- testing: 2147483647 % -9223372034707292160 ---
|
||||
int(2147483647)
|
||||
--- testing: 2147483647 % 2147483648 ---
|
||||
int(2147483647)
|
||||
--- testing: 2147483647 % -2147483649 ---
|
||||
int(2147483647)
|
||||
--- testing: 2147483647 % 4294967294 ---
|
||||
int(2147483647)
|
||||
--- testing: 2147483647 % 4294967295 ---
|
||||
int(2147483647)
|
||||
--- testing: 2147483647 % 4294967293 ---
|
||||
int(2147483647)
|
||||
--- testing: 2147483647 % 9223372036854775806 ---
|
||||
int(2147483647)
|
||||
--- testing: 2147483647 % 9.2233720368548E+18 ---
|
||||
int(2147483647)
|
||||
--- testing: 2147483647 % -9223372036854775807 ---
|
||||
int(2147483647)
|
||||
--- testing: 2147483647 % -9.2233720368548E+18 ---
|
||||
int(2147483647)
|
||||
--- testing: 9223372036854775807 % 9223372036854775807 ---
|
||||
int(0)
|
||||
--- testing: 9223372036854775807 % -9223372036854775808 ---
|
||||
int(9223372036854775807)
|
||||
--- testing: 9223372036854775807 % 2147483647 ---
|
||||
int(1)
|
||||
--- testing: 9223372036854775807 % -2147483648 ---
|
||||
int(2147483647)
|
||||
--- testing: 9223372036854775807 % 9223372034707292160 ---
|
||||
int(2147483647)
|
||||
--- testing: 9223372036854775807 % -9223372034707292160 ---
|
||||
int(2147483647)
|
||||
--- testing: 9223372036854775807 % 2147483648 ---
|
||||
int(2147483647)
|
||||
--- testing: 9223372036854775807 % -2147483649 ---
|
||||
int(1)
|
||||
--- testing: 9223372036854775807 % 4294967294 ---
|
||||
int(1)
|
||||
--- testing: 9223372036854775807 % 4294967295 ---
|
||||
int(2147483647)
|
||||
--- testing: 9223372036854775807 % 4294967293 ---
|
||||
int(2147483650)
|
||||
--- testing: 9223372036854775807 % 9223372036854775806 ---
|
||||
int(1)
|
||||
--- testing: 9223372036854775807 % 9.2233720368548E+18 ---
|
||||
int(9223372036854775807)
|
||||
--- testing: 9223372036854775807 % -9223372036854775807 ---
|
||||
int(0)
|
||||
--- testing: 9223372036854775807 % -9.2233720368548E+18 ---
|
||||
int(9223372036854775807)
|
||||
===DONE===
|
||||
@@ -1,8 +0,0 @@
|
||||
<?php
|
||||
|
||||
error_reporting(E_ALL);
|
||||
|
||||
$arr = array('foo' => 'bar');
|
||||
echo "$arr['foo']";
|
||||
|
||||
?>
|
||||
@@ -1 +0,0 @@
|
||||
Parse error: %s error, %s(T_STRING)%s(T_VARIABLE)%s(T_NUM_STRING)%sin %sbug21820.php on line %d
|
||||
@@ -1,5 +0,0 @@
|
||||
<?php
|
||||
|
||||
var_dump (func_get_arg(0));
|
||||
|
||||
?>
|
||||
@@ -1,2 +0,0 @@
|
||||
HipHop Warning: %a
|
||||
bool(false)
|
||||
@@ -1,5 +0,0 @@
|
||||
<?php
|
||||
|
||||
var_dump(func_get_args());
|
||||
|
||||
?>
|
||||
@@ -1,2 +0,0 @@
|
||||
HipHop Warning: .+
|
||||
bool\(false\)
|
||||
@@ -1,5 +0,0 @@
|
||||
<?php
|
||||
|
||||
var_dump(func_num_args());
|
||||
|
||||
?>
|
||||
@@ -1,2 +0,0 @@
|
||||
HipHop Warning: %a
|
||||
int(-1)
|
||||
@@ -1,18 +0,0 @@
|
||||
<?php
|
||||
|
||||
var_dump(func_get_arg(1,2,3));
|
||||
var_dump(func_get_arg(1));
|
||||
var_dump(func_get_arg());
|
||||
|
||||
function bar() {
|
||||
var_dump(func_get_arg(1));
|
||||
}
|
||||
|
||||
function foo() {
|
||||
bar(func_get_arg(1));
|
||||
}
|
||||
|
||||
foo(1,2);
|
||||
|
||||
echo "Done\n";
|
||||
?>
|
||||
@@ -1,9 +0,0 @@
|
||||
HipHop Warning: %a
|
||||
NULL
|
||||
HipHop Warning: %a
|
||||
bool(false)
|
||||
HipHop Warning: %a
|
||||
NULL
|
||||
HipHop Warning: %a
|
||||
bool(false)
|
||||
Done
|
||||
@@ -1,11 +0,0 @@
|
||||
<?php
|
||||
$a = new stdClass;
|
||||
$a->x0 = new stdClass;
|
||||
$a->x0->y0 = 'a';
|
||||
$a->x0->y1 =& $a->x0;
|
||||
$a->x0->y2 =& $a->x0;
|
||||
$a->x0->y0 = 'b';
|
||||
var_dump($a);
|
||||
$a->x0->y1 = "ok\n";
|
||||
echo $a->x0;
|
||||
?>
|
||||
@@ -1,12 +0,0 @@
|
||||
object(stdClass)#%d (1) {
|
||||
["x0"]=>
|
||||
&object(stdClass)#%d (3) {
|
||||
["y0"]=>
|
||||
string(1) "b"
|
||||
["y1"]=>
|
||||
*RECURSION*
|
||||
["y2"]=>
|
||||
*RECURSION*
|
||||
}
|
||||
}
|
||||
ok
|
||||
@@ -1,10 +0,0 @@
|
||||
<?php
|
||||
function my_errorhandler($errno,$errormsg) {
|
||||
global $my_var;
|
||||
$my_var = 0;
|
||||
echo "EROOR: $errormsg\n";
|
||||
}
|
||||
set_error_handler("my_errorhandler");
|
||||
$my_var = str_repeat("A",$my_var[0]->errormsg = "xyz");
|
||||
echo "ok\n";
|
||||
?>
|
||||
@@ -1,2 +0,0 @@
|
||||
EROOR: Creating default object from empty value
|
||||
ok
|
||||
@@ -1,4 +0,0 @@
|
||||
<?php
|
||||
function f(callable $c) {}
|
||||
f();
|
||||
?>
|
||||
@@ -1 +0,0 @@
|
||||
Catchable fatal error: Argument 1 passed to f() must be callable, none given, called in hphp/test/zend/bad/zend/bug55705.php on line 3 and defined in hphp/test/zend/bad/zend/bug55705.php on line %d
|
||||
@@ -1,16 +0,0 @@
|
||||
<?php
|
||||
|
||||
class bar {
|
||||
function baz() {}
|
||||
static function foo() {}
|
||||
}
|
||||
function foo(callable $bar) {
|
||||
var_dump($bar);
|
||||
}
|
||||
$closure = function () {};
|
||||
|
||||
foo("strpos");
|
||||
foo("foo");
|
||||
foo(array("bar", "baz"));
|
||||
foo(array("bar", "foo"));
|
||||
foo($closure);
|
||||
@@ -1,18 +0,0 @@
|
||||
string(6) "strpos"
|
||||
string(3) "foo"
|
||||
|
||||
Strict Standards: Non-static method bar::baz() should not be called statically in %scallable_type_hint_001.php on line %d
|
||||
array(2) {
|
||||
[0]=>
|
||||
string(3) "bar"
|
||||
[1]=>
|
||||
string(3) "baz"
|
||||
}
|
||||
array(2) {
|
||||
[0]=>
|
||||
string(3) "bar"
|
||||
[1]=>
|
||||
string(3) "foo"
|
||||
}
|
||||
object(Closure)#%d (0) {
|
||||
}
|
||||
@@ -1,12 +0,0 @@
|
||||
<?php
|
||||
|
||||
function foo(callable $a, $b, callable $c) {
|
||||
var_dump($a, $b, $c);
|
||||
}
|
||||
function bar(callable $a = null) {
|
||||
var_dump($a);
|
||||
}
|
||||
|
||||
foo("strpos", 123, "strpos");
|
||||
bar("substr");
|
||||
?>
|
||||
@@ -1,4 +0,0 @@
|
||||
string(6) "strpos"
|
||||
int(123)
|
||||
string(6) "strpos"
|
||||
string(6) "substr"
|
||||
@@ -0,0 +1,2 @@
|
||||
Test::{closure}()
|
||||
HipHop Fatal error: %a
|
||||
@@ -1,17 +0,0 @@
|
||||
<?php
|
||||
|
||||
require_once 'nowdoc.inc';
|
||||
|
||||
print <<<ENDOFHEREDOC
|
||||
This is heredoc test #s $a, $b, $c['c'], and $d->d.
|
||||
|
||||
ENDOFHEREDOC;
|
||||
|
||||
$x = <<<ENDOFHEREDOC
|
||||
This is heredoc test #s $a, $b, $c['c'], and $d->d.
|
||||
|
||||
ENDOFHEREDOC;
|
||||
|
||||
print "{$x}";
|
||||
|
||||
?>
|
||||
@@ -1 +0,0 @@
|
||||
Parse error: %s in %sheredoc_005.php on line 6
|
||||
Alguns arquivos não foram exibidos porque demasiados arquivos foram alterados neste diff Mostrar Mais
Referência em uma Nova Issue
Bloquear um usuário