[PHP-DEV] Bug #14244 Updated: A bug about integer operation /

2001-11-28 Thread poolshark

ID: 14244
User updated by: [EMAIL PROTECTED]
Reported By: [EMAIL PROTECTED]
Status: Bogus
Bug Type: Variables related
Operating System: linux
PHP Version: 4.0.6
New Comment:

 Ignoring my bug report ***
It is my wrong.

Previous Comments:


[2001-11-27 04:11:08] [EMAIL PROTECTED]

Yes, did you read the part in ?  Obviously not.

If either operand is a floating-point value, or the operation results in a 
non-integer value, a floating-point value is returned.

The operation 13/10 will result in 1.3 which is a float, so a floating point value is 
returned.

-Chris



[2001-11-27 04:08:33] [EMAIL PROTECTED]

Again:

If either operand is a
floating-point value, or the operation results in a non-integer value, a
floating-point value is returned.

The division returns a floatingpoint value.



[2001-11-27 02:17:50] [EMAIL PROTECTED]

Bug Database [EMAIL PROTECTED] 

Did you see my program?,and dir you run them?
obviously, the two operands are ***integers ***.



[2001-11-27 01:16:50] [EMAIL PROTECTED]

RTM http://www.php.net/manual/en/language.operators.php

The division operator (/) returns an integer value (the result of an integer 
division) if the two operands are integers (or strings that get converted to integers) 
and the quotient is an integer. If either operand is a floating-point value, or 
the operation results in a non-integer value, a floating-point value is returned.

-Chris



[2001-11-27 01:06:51] [EMAIL PROTECTED]

Here is a short test program :
?
#test.php of integer operation by /
  $total=13;
  printf (total %d  type %sBR,$total,gettype($total));
  $each=10;
  printf (each %d  type %sBR,$each,gettype($each));
  $page=$total/$each;
  print (Page is $page);
?

The output is 1.3
not as the expect 1
-
configure command

./configure --with-apache=/home/zlq/bin/apache_1.3.22
--with-mysql=/mysql
--with-xml
--with-charset=gb2312
--disable-debug
--enable-ftp


---
INIT_VERSION :sysinit-2.78
HOSTTYPE:i386






Edit this bug report at http://bugs.php.net/?id=14244edit=1


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] Bug #14244 Updated: A bug about integer operation /

2001-11-27 Thread poolshark

ID: 14244
User updated by: [EMAIL PROTECTED]
Reported By: [EMAIL PROTECTED]
Status: Bogus
Bug Type: Variables related
Operating System: linux
PHP Version: 4.0.6
New Comment:

Bug Database [EMAIL PROTECTED] 

Did you see my program?,and dir you run them?
obviously, the two operands are ***integers ***.

Previous Comments:


[2001-11-27 01:16:50] [EMAIL PROTECTED]

RTM http://www.php.net/manual/en/language.operators.php

The division operator (/) returns an integer value (the result of an integer 
division) if the two operands are integers (or strings that get converted to integers) 
and the quotient is an integer. If either operand is a floating-point value, or 
the operation results in a non-integer value, a floating-point value is returned.

-Chris



[2001-11-27 01:06:51] [EMAIL PROTECTED]

Here is a short test program :
?
#test.php of integer operation by /
  $total=13;
  printf (total %d  type %sBR,$total,gettype($total));
  $each=10;
  printf (each %d  type %sBR,$each,gettype($each));
  $page=$total/$each;
  print (Page is $page);
?

The output is 1.3
not as the expect 1
-
configure command

./configure --with-apache=/home/zlq/bin/apache_1.3.22
--with-mysql=/mysql
--with-xml
--with-charset=gb2312
--disable-debug
--enable-ftp


---
INIT_VERSION :sysinit-2.78
HOSTTYPE:i386






Edit this bug report at http://bugs.php.net/?id=14244edit=1


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] Bug #14244: A bug about integer operation /

2001-11-26 Thread poolshark

From: [EMAIL PROTECTED]
Operating system: linux
PHP version:  4.0.6
PHP Bug Type: Variables related
Bug description:  A bug about integer operation /

Here is a short test program :
?
#test.php of integer operation by /
  $total=13;
  printf (total %d  type %sBR,$total,gettype($total));
  $each=10;
  printf (each %d  type %sBR,$each,gettype($each));
  $page=$total/$each;
  print (Page is $page);
?

The output is 1.3
not as the expect 1
-
configure command

./configure --with-apache=/home/zlq/bin/apache_1.3.22
--with-mysql=/mysql
--with-xml
--with-charset=gb2312
--disable-debug
--enable-ftp


---
INIT_VERSION :sysinit-2.78
HOSTTYPE:i386

-- 
Edit bug report at: http://bugs.php.net/?id=14244edit=1


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]