Doc #54390 [NEW]: Please remove the Singleton Pattern from the Docs
| From: | gordon at onlinehome dot de | Date: | Sat, 26 Mar 2011 12:18:59 +0000 |
| Subject: | Doc #54390 [NEW]: Please remove the Singleton Pattern from the Docs | ||
| Groups: | php.doc.bugs | ||
| Request: | Send a blank email to doc-bugs+get-6150@lists.php.net to get a copy of this message | ||
From:
Operating system:
PHP version: Irrelevant
Package: Documentation problem
Bug Type: Documentation Problem
Bug description:Please remove the Singleton Pattern from the Docs
Description:
------------
The [chapter on Design Patterns in the Manual][1] starts with:
> Patterns are ways to describe best practices and good designs. They show
a flexible solution to common programming problems.
and then goes on to show a Singleton Pattern. The problems Singletons solve
do not exist in PHP. And even Erich Gamma thinks it's a Code Smell nowadays
in general. Consequently, I think we should not educate people about this
pattern and suggest removal.
[1]: http://www.php.net/manual/en/language.oop5.patterns.php
--
Edit bug report at http://bugs.php.net/bug.php?id=54390&edit=1
--
Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=54390&r=trysnapshot52
Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=54390&r=trysnapshot53
Try a snapshot (trunk): http://bugs.php.net/fix.php?id=54390&r=trysnapshottrunk
Fixed in SVN: http://bugs.php.net/fix.php?id=54390&r=fixed
Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=54390&r=needdocs
Fixed in release: http://bugs.php.net/fix.php?id=54390&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=54390&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=54390&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=54390&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=54390&r=support
Expected behavior: http://bugs.php.net/fix.php?id=54390&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=54390&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=54390&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=54390&r=globals
PHP 4 support discontinued: http://bugs.php.net/fix.php?id=54390&r=php4
Daylight Savings: http://bugs.php.net/fix.php?id=54390&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=54390&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=54390&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=54390&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=54390&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=54390&r=mysqlcfg