Date: 09/29/01
- Next message: Zeev Suraski: "Re: [PHP-DEV] why does exit() print its argument?"
- Previous message: mike: "[PHP-DEV] [Fwd: Segfault on writing to shared memory block]"
- In reply to: Sander Steffann: "Re: [PHP-DEV] why does exit() print its argument?"
- Next in thread: Derick Rethans: "Re: [PHP-DEV] why does exit() print its argument?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
I wouldn't be surprised if it broke lots of code. I, for once, have been
using it a lot, even though I'm primarily a C coder. Considering PHP is a
Web scripting language, I think that the chances of people expecting this
to have something to do with processes is very small, since in the vast
majority of PHP installation, that's completely meaningless.
We must not break compatibility unless there's a very good reason to do it,
and there simply isn't.
Zeev
At 20:53 29-09-01, Sander Steffann wrote:
>Hi,
>
> > How about if we overload it a bit. I think anybody who does exit(1) is
> > expecting 1 to be set as the return status
>
>True, exit is the 'expected' name for this behaviour IMHO.
>
> > whereas someone who does
> > exit('something bad happened') is expecting the string to be shown a-la
> > die(). So let's just check the arg and do the appropriate thing. I would
> > be very surprised if that broke anything.
>
>You could do this, but I don't think it is ..realy.. needed. It would make
>the function a little more complicated to understand, but it wouldn't break
>backwards compatibility as much.
>
>I am for changing exit() to do the 'expected' thing, and break a 'little'
>backwards compatibility.
>
>Usualy I am very much against breaking backwards compatibility, but in this
>case I think it's the best thing to do... Because:
>- It's already documented that way
>- It's the 'expected' behaviour (from other languages, and from the docs)
>
>As Rasmus said: It would be surprising if this broke a lot of (or even any)
>code.
>Sander.
>
>
>
>
>--
>PHP Development Mailing List <http://www.php.net/>
>To unsubscribe, e-mail: php-dev-unsubscribe <email protected>
>For additional commands, e-mail: php-dev-help <email protected>
>To contact the list administrators, e-mail: php-list-admin <email protected>
-- PHP Development Mailing List <http://www.php.net/> To unsubscribe, e-mail: php-dev-unsubscribe <email protected> For additional commands, e-mail: php-dev-help <email protected> To contact the list administrators, e-mail: php-list-admin <email protected>
- Next message: Zeev Suraski: "Re: [PHP-DEV] why does exit() print its argument?"
- Previous message: mike: "[PHP-DEV] [Fwd: Segfault on writing to shared memory block]"
- In reply to: Sander Steffann: "Re: [PHP-DEV] why does exit() print its argument?"
- Next in thread: Derick Rethans: "Re: [PHP-DEV] why does exit() print its argument?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

