note 102192 added to datetime.sub
| From: | Anonymous at osu1 dot php dot net | Date: | Tue, 01 Feb 2011 22:15:05 +0000 |
| Subject: | note 102192 added to datetime.sub | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-176576@lists.php.net to get a copy of this message | ||
Note that the sub() and add() methods will modify the value of the object you're calling the
method on! This is very untypical for a method that returns a value of its own type. You could
misunderstand it that the method would return a new instance with the modified value, but in fact it
modifies itself! This is undocumented here. (Only a side note on procedural style mentions it, but
it obviously does not apply to object oriented style.)
----
Server IP: 217.160.235.204
Probable Submitter: 83.171.172.168
----
Manual Page -- http://www.php.net/manual/en/datetime.sub.php
Edit -- https://master.php.net/note/edit/102192
Del: integrated -- https://master.php.net/note/delete/102192/integrated
Del: useless -- https://master.php.net/note/delete/102192/useless
Del: bad code -- https://master.php.net/note/delete/102192/bad+code
Del: spam -- https://master.php.net/note/delete/102192/spam
Del: non-english -- https://master.php.net/note/delete/102192/non-english
Del: in docs -- https://master.php.net/note/delete/102192/in+docs
Del: other reasons-- https://master.php.net/note/delete/102192
Reject -- https://master.php.net/note/reject/102192
Search -- https://master.php.net/manage/user-notes.php