From d14faa6bedf8cb5e400f910860e05a6f98709d01 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Thiemo=20M=C3=A4ttig?= Date: Wed, 5 Jul 2017 12:42:09 +0200 Subject: [PATCH] Remove auto-generated "Constructor" documentation on constructors Having such comments is worse than not having them. They add zero information. But you must read the text to understand there is nothing you don't already know from the class and the method name. Change-Id: I994d11e05f202b880390723e148d79c72cca29f0 --- includes/MergeHistory.php | 1 - includes/StubObject.php | 2 -- includes/actions/Action.php | 2 -- includes/cache/LinkBatch.php | 1 - includes/cache/localisation/LocalisationCache.php | 1 - includes/content/WikiTextStructure.php | 1 - includes/diff/DairikiDiff.php | 1 - includes/filerepo/file/LocalFile.php | 1 - includes/installer/CliInstaller.php | 2 -- includes/installer/LocalSettingsGenerator.php | 2 -- includes/installer/WebInstaller.php | 2 -- includes/libs/GenericArrayObject.php | 1 - includes/libs/MemoizedCallable.php | 2 -- includes/libs/xmp/XMP.php | 2 -- includes/logging/LogEntry.php | 2 -- includes/logging/LogEventsList.php | 1 - includes/search/PerRowAugmentor.php | 1 - includes/search/SearchIndexFieldDefinition.php | 1 - includes/site/MediaWikiSite.php | 2 -- includes/site/Site.php | 2 -- includes/user/UserRightsProxy.php | 2 -- includes/utils/FileContentsHasher.php | 3 --- 22 files changed, 35 deletions(-) diff --git a/includes/MergeHistory.php b/includes/MergeHistory.php index cc589c9811..48ff97bdf1 100644 --- a/includes/MergeHistory.php +++ b/includes/MergeHistory.php @@ -60,7 +60,6 @@ class MergeHistory { protected $revisionsMerged; /** - * MergeHistory constructor. * @param Title $source Page from which history will be merged * @param Title $dest Page to which history will be merged * @param string|bool $timestamp Timestamp up to which history from the source will be merged diff --git a/includes/StubObject.php b/includes/StubObject.php index 0210ed9d6a..5208b8f1fa 100644 --- a/includes/StubObject.php +++ b/includes/StubObject.php @@ -55,8 +55,6 @@ class StubObject { protected $params; /** - * Constructor. - * * @param string $global Name of the global variable. * @param string|callable $class Name of the class of the real object * or a factory function to call diff --git a/includes/actions/Action.php b/includes/actions/Action.php index 844a0d6048..88382b694f 100644 --- a/includes/actions/Action.php +++ b/includes/actions/Action.php @@ -259,8 +259,6 @@ abstract class Action implements MessageLocalizer { } /** - * Constructor. - * * Only public since 1.21 * * @param Page $page diff --git a/includes/cache/LinkBatch.php b/includes/cache/LinkBatch.php index 57d4581a55..d8e3c38176 100644 --- a/includes/cache/LinkBatch.php +++ b/includes/cache/LinkBatch.php @@ -43,7 +43,6 @@ class LinkBatch { protected $caller; /** - * LinkBatch constructor. * @param LinkTarget[] $arr Initial items to be added to the batch */ public function __construct( $arr = [] ) { diff --git a/includes/cache/localisation/LocalisationCache.php b/includes/cache/localisation/LocalisationCache.php index d499340d0e..58a67adb8e 100644 --- a/includes/cache/localisation/LocalisationCache.php +++ b/includes/cache/localisation/LocalisationCache.php @@ -183,7 +183,6 @@ class LocalisationCache { private $mergeableKeys = null; /** - * Constructor. * For constructor parameters, see the documentation in DefaultSettings.php * for $wgLocalisationCacheConf. * diff --git a/includes/content/WikiTextStructure.php b/includes/content/WikiTextStructure.php index afa03b8f14..aeb96b6531 100644 --- a/includes/content/WikiTextStructure.php +++ b/includes/content/WikiTextStructure.php @@ -59,7 +59,6 @@ class WikiTextStructure { ]; /** - * WikiTextStructure constructor. * @param ParserOutput $parserOutput */ public function __construct( ParserOutput $parserOutput ) { diff --git a/includes/diff/DairikiDiff.php b/includes/diff/DairikiDiff.php index a08bd9ed9b..d76af31aea 100644 --- a/includes/diff/DairikiDiff.php +++ b/includes/diff/DairikiDiff.php @@ -211,7 +211,6 @@ class Diff { protected $bailoutComplexity = 0; /** - * Constructor. * Computes diff between sequences of strings. * * @param string[] $from_lines An array of strings. diff --git a/includes/filerepo/file/LocalFile.php b/includes/filerepo/file/LocalFile.php index f71e1dc273..33177d3f6f 100644 --- a/includes/filerepo/file/LocalFile.php +++ b/includes/filerepo/file/LocalFile.php @@ -215,7 +215,6 @@ class LocalFile extends File { } /** - * Constructor. * Do not call this except from inside a repo class. * @param Title $title * @param FileRepo $repo diff --git a/includes/installer/CliInstaller.php b/includes/installer/CliInstaller.php index af55dbb2ba..6ac78c40bc 100644 --- a/includes/installer/CliInstaller.php +++ b/includes/installer/CliInstaller.php @@ -47,8 +47,6 @@ class CliInstaller extends Installer { ]; /** - * Constructor. - * * @param string $siteName * @param string $admin * @param array $option diff --git a/includes/installer/LocalSettingsGenerator.php b/includes/installer/LocalSettingsGenerator.php index a9710eb9f6..bdaeaca86c 100644 --- a/includes/installer/LocalSettingsGenerator.php +++ b/includes/installer/LocalSettingsGenerator.php @@ -41,8 +41,6 @@ class LocalSettingsGenerator { protected $installer; /** - * Constructor. - * * @param Installer $installer */ public function __construct( Installer $installer ) { diff --git a/includes/installer/WebInstaller.php b/includes/installer/WebInstaller.php index c94f0bfaa4..a311ce96ed 100644 --- a/includes/installer/WebInstaller.php +++ b/includes/installer/WebInstaller.php @@ -130,8 +130,6 @@ class WebInstaller extends Installer { protected $currentPageName; /** - * Constructor. - * * @param WebRequest $request */ public function __construct( WebRequest $request ) { diff --git a/includes/libs/GenericArrayObject.php b/includes/libs/GenericArrayObject.php index 76e23cfd50..f76d9a2e8d 100644 --- a/includes/libs/GenericArrayObject.php +++ b/includes/libs/GenericArrayObject.php @@ -67,7 +67,6 @@ abstract class GenericArrayObject extends ArrayObject { } /** - * Constructor. * @see ArrayObject::__construct * * @since 1.20 diff --git a/includes/libs/MemoizedCallable.php b/includes/libs/MemoizedCallable.php index 12a5cadb99..6b4281fb96 100644 --- a/includes/libs/MemoizedCallable.php +++ b/includes/libs/MemoizedCallable.php @@ -46,8 +46,6 @@ class MemoizedCallable { private $callableName; /** - * Constructor. - * * @throws InvalidArgumentException if $callable is not a callable. * @param callable $callable Function or method to memoize. * @param int $ttl TTL in seconds. Defaults to 3600 (1hr). Capped at 86400 (24h). diff --git a/includes/libs/xmp/XMP.php b/includes/libs/xmp/XMP.php index debe869e7e..e12766a2ad 100644 --- a/includes/libs/xmp/XMP.php +++ b/includes/libs/xmp/XMP.php @@ -130,8 +130,6 @@ class XMPReader implements LoggerAwareInterface { private $logger; /** - * Constructor. - * * Primary job is to initialize the XMLParser */ function __construct( LoggerInterface $logger = null ) { diff --git a/includes/logging/LogEntry.php b/includes/logging/LogEntry.php index e7095f0b39..fa94fe5b23 100644 --- a/includes/logging/LogEntry.php +++ b/includes/logging/LogEntry.php @@ -437,8 +437,6 @@ class ManualLogEntry extends LogEntryBase { protected $legacy = false; /** - * Constructor. - * * @since 1.19 * @param string $type * @param string $subtype diff --git a/includes/logging/LogEventsList.php b/includes/logging/LogEventsList.php index a9679bf384..22e5b45cf1 100644 --- a/includes/logging/LogEventsList.php +++ b/includes/logging/LogEventsList.php @@ -55,7 +55,6 @@ class LogEventsList extends ContextSource { private $linkRenderer; /** - * Constructor. * The first two parameters used to be $skin and $out, but now only a context * is needed, that's why there's a second unused parameter. * diff --git a/includes/search/PerRowAugmentor.php b/includes/search/PerRowAugmentor.php index 8eb8b17c11..a3979f7b71 100644 --- a/includes/search/PerRowAugmentor.php +++ b/includes/search/PerRowAugmentor.php @@ -12,7 +12,6 @@ class PerRowAugmentor implements ResultSetAugmentor { private $rowAugmentor; /** - * PerRowAugmentor constructor. * @param ResultAugmentor $augmentor Per-result augmentor to use. */ public function __construct( ResultAugmentor $augmentor ) { diff --git a/includes/search/SearchIndexFieldDefinition.php b/includes/search/SearchIndexFieldDefinition.php index e3e01e8b60..87d6344bea 100644 --- a/includes/search/SearchIndexFieldDefinition.php +++ b/includes/search/SearchIndexFieldDefinition.php @@ -39,7 +39,6 @@ abstract class SearchIndexFieldDefinition implements SearchIndexField { private $mergeCallback; /** - * SearchIndexFieldDefinition constructor. * @param string $name Field name * @param int $type Index type */ diff --git a/includes/site/MediaWikiSite.php b/includes/site/MediaWikiSite.php index 6734d5f70c..f31a77d3a4 100644 --- a/includes/site/MediaWikiSite.php +++ b/includes/site/MediaWikiSite.php @@ -40,8 +40,6 @@ class MediaWikiSite extends Site { const PATH_PAGE = 'page_path'; /** - * Constructor. - * * @since 1.21 * * @param string $type diff --git a/includes/site/Site.php b/includes/site/Site.php index 28f19f9abf..31e1590933 100644 --- a/includes/site/Site.php +++ b/includes/site/Site.php @@ -122,8 +122,6 @@ class Site implements Serializable { protected $internalId = null; /** - * Constructor. - * * @since 1.21 * * @param string $type diff --git a/includes/user/UserRightsProxy.php b/includes/user/UserRightsProxy.php index 4df73f7328..98586e76c7 100644 --- a/includes/user/UserRightsProxy.php +++ b/includes/user/UserRightsProxy.php @@ -29,8 +29,6 @@ use Wikimedia\Rdbms\IDatabase; class UserRightsProxy { /** - * Constructor. - * * @see newFromId() * @see newFromName() * @param IDatabase $db Db connection diff --git a/includes/utils/FileContentsHasher.php b/includes/utils/FileContentsHasher.php index c74b04de2d..afe9c0a0f0 100644 --- a/includes/utils/FileContentsHasher.php +++ b/includes/utils/FileContentsHasher.php @@ -27,9 +27,6 @@ class FileContentsHasher { /** @var FileContentsHasher */ private static $instance; - /** - * Constructor. - */ public function __construct() { $this->cache = ObjectCache::getLocalServerInstance( 'hash' ); } -- 2.20.1