Re: RFC for Adding __toString to DateTime
| From: | Sherif Ramadan | Date: | Sun, 02 Sep 2012 23:12:25 +0000 |
| Subject: | Re: RFC for Adding __toString to DateTime | ||
| References: | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-62699@lists.php.net to get a copy of this message | ||
On Sun, Sep 2, 2012 at 7:11 PM, Sherif Ramadan <theanomaly.is@gmail.com> wrote:
>>
>> It is problematic because that is what we choose to make it. Right now, a
>> catchable fatal error is produced. That is problematic. ISO8601 is not
>> lossy nor is UTC. It can be taken by any other language and converted based
>> on the format itself.
>>
I don't understand why that's problematic? The user wants to output a
formated date they should provide a format by calling
DateTime::format()... why do we have to assume the user will find
*any* standards we propose to be acceptable? As you can see everyone
here that uses it expects something slightly different. This request
makes no sense. Sorry.
>> We have standards for a reason. I agree that changing that should not be
>> allowed. I will remove the set/get pattern functions and only print a
>> standard format. Printing an ISO standard format, which includes the TZ
>> based on UTC, or even the UTC format itself is a better solution than a
>> catchable fatal error.
>>
>>>
>>>
>>> --
>>> Lester Caine - G8HFL
>>> -----------------------------
>>> Contact - http://lsces.co.uk/wiki/?page=contact
>>> L.S.Caine Electronic Services - http://lsces.co.uk
>>> EnquirySolve - http://enquirysolve.com/
>>> Model Engineers Digital Workshop - http://medw.co.uk
>>> Rainbow Digital Media -
>>> http://rainbowdigitalmedia.co.uk
>>>
>>>
>>>
>>> --
>>> PHP Internals - PHP Runtime Development Mailing List
>>> To unsubscribe, visit: http://www.php.net/unsub.php
>>>