Fixed bug #64248 #282

Closed
wants to merge 1 commit into
from

Conversation

Projects
None yet
5 participants
@bwoebi
Contributor

bwoebi commented Feb 19, 2013

This little patch enables unset() to behave as a normal expr. This has for result that unset now returns a random int. While a good alternative for the (mt_)rand() functions, an idea would be to make unset return true if the variable has existed else false?

@MartinZottmann

This comment has been minimized.

Show comment Hide comment
@MartinZottmann

MartinZottmann Feb 20, 2013

[...] an idea would be to make unset return true if the variable has existed else false?

+1

[...] an idea would be to make unset return true if the variable has existed else false?

+1

@laruence

This comment has been minimized.

Show comment Hide comment
@laruence

laruence Feb 20, 2013

Member

this definitely need a RFC

Member

laruence commented Feb 20, 2013

this definitely need a RFC

@lstrojny

This comment has been minimized.

Show comment Hide comment
@lstrojny

lstrojny Feb 20, 2013

Contributor

For more information on what an RFC is, refer to https://wiki.php.net/rfc

Contributor

lstrojny commented Feb 20, 2013

For more information on what an RFC is, refer to https://wiki.php.net/rfc

@lstrojny

This comment has been minimized.

Show comment Hide comment
@lstrojny

lstrojny Feb 20, 2013

Contributor

Otherwise I'll like it but the patch needs tests and making it return a boolean return value is a good idea as well.

Contributor

lstrojny commented Feb 20, 2013

Otherwise I'll like it but the patch needs tests and making it return a boolean return value is a good idea as well.

@bwoebi

This comment has been minimized.

Show comment Hide comment
@bwoebi

bwoebi Feb 20, 2013

Contributor

I've requested a php-wiki account for creating a rfc. I'll now change the unset language construct and rebase it to PHP-5.5 as you don't consider it as a bug fix only.

Contributor

bwoebi commented Feb 20, 2013

I've requested a php-wiki account for creating a rfc. I'll now change the unset language construct and rebase it to PHP-5.5 as you don't consider it as a bug fix only.

@bwoebi bwoebi closed this Feb 23, 2013

@RyanNerd

This comment has been minimized.

Show comment Hide comment
@RyanNerd

RyanNerd Jan 28, 2017

Why is this closed? This would be very useful.

Why is this closed? This would be very useful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment