It's unreasonable to expect newbies to know that "bug 12345" means "Task T14345"
except where it doesn't, so let's just standardise on the real numbers.
Change-Id: I6f59febaf8fc96e80f8cfc11f4356283f461142a
Most of these are simply changing annotations to reflect
reality. If a function can return false to indicate failure
the @return should indicate it.
Some are fixing preg_match calls, preg match returns 1, 0 or false,
but the functions all claim to return booleans.
This is far from all the incorrect return types in mediawiki, there
are around 250 detected by phan, but have to start somewhere.
Change-Id: I1bbdfee6190747bde460f8a7084212ccafe169ef
This is more consistent with LoadBalancer, modern, and inclusive
of master/master mysql, NDB cluster, and MariaDB galera cluster.
The old constant is an alias now.
Change-Id: I0b37299ecb439cc446ffbe8c341365d1eef45849
wfSuppressWarnings() and wfRestoreWarnings() were split out into a
separate library. All usages in core were replaced with the new
functions, and the wf* global functions are marked as deprecated.
Additionally, some uses of @ were replaced due to composer's autoloader
being loaded even earlier.
Ie1234f8c12693408de9b94bf6f84480a90bd4f8e adds the library to
mediawiki/vendor.
Bug: T100923
Change-Id: I5c35079a0a656180852be0ae6b1262d40f6534c4
Change Ia9baaf0b changed the visibility of member variables (many of which are not
otherwise exposed, e.g. by a method) and by that introduced a major API change
breaking extensions.
This patch explicitly marks affected variables as public again, keeping the intent
of the original patch of making phpcs-strict pass on includes/ directory.
Bug: 67522
Bug: 67984
Change-Id: I498512b2a1e615365bb477c1fd210aaa3241ca03
- Swap "$variable type" to "type $variable"
- Added missing types
- Fixed spacing inside docs
- Makes beginning of @param/@return/@var/@throws in capital
- Changed some types to match the more common spelling
Change-Id: I783e4dbfe5f6f98b32b9a03ccf6439e13e132bcc
This follows-up bebcf2c583, which only fixed DiffHistoryBlob.
MediaWiki will fail to load some revisions if the following properties
do not unserialize correctly:
* HistoryBlobStub::$mOldId
* HistoryBlobStub::$mHash
* HistoryBlobCurStub::$mCurId
Visibility of HistoryBlobStub::$mRef is also restored; though the
property's value does not appear to be used after unserialization,
the property is nevertheless a serialized property.
Bug: 65665
Change-Id: I2724d15f9206d66d615d020117e60bb772048c19
Swapped some "$var type" to "type $var" or added missing types
before the $var. Changed some other types to match the more common
spelling. Makes beginning of some text in captial.
Also added some missing @param.
Change-Id: I0056b4a8df243cfc0c5f25378de48f7a35170aca
It is $wgLegacySchemaConversion = true that causes these to be
inserted into the text table when upgrading from 1.4 or earlier,
and this is the only occurrence of $wgFastSchemaUpgrades even on
the REL1_5 branch.
Change-Id: I57634343d3515a4fb982c648e22ad23c2af0f2f6
Checking for the mhash extension is pointless in PHP 5.3+ because
it only exists as B/C functions that are part of the hash extension.
From ext/hash/config.m4:
if test "$PHP_MHASH" != "no"; then
if test "$PHP_HASH" = "no"; then
PHP_HASH="yes"
fi
AC_DEFINE(PHP_MHASH_BC, 1, [ ])
fi
So if mhash() is compiled in, hash() must also be compiled in.
Change-Id: Ic376f4c438aaf701ebb4f1394ab6e4c1803fb8b8
Doxygen expects parameter types to come before the
parameter name in @param tags. Used a quick regex
to switch everything around where possible. This
only fixes cases where a primitve variable (or a
primitive followed by other types) is the variable
type. Other cases will need to be fixed manually.
Change-Id: Ic59fd20856eb0489d70f3469a56ebce0efb3db13
Added/removed spaces around logical/arithmetic operator
Reduced multiple empty lines to one empty line
Removed wrong tabs before comments at end of line
Removed too many spaces in assigments
Change-Id: I2bba4e72f9b5f88c53324d7b70e6042f1aad8f6b
* Tweaked blob_tracking indexes now that I know what I'm doing with them
* Standardised isHappy() on no arguments. Use an uncompressed size limit instead of the weird things I did originally.
Looks cool, but this changes the return type of ConcatenatedGzipHistoryBlob::addItem() from a stub object to a hash value, which will break its usages in ConcatenatedGzipHistoryBlob::setText() and maintenance/storage/compressOld.inc.
* Fixed documentation in HistoryBlob.php, removed "todo document" for methods that are adequately documented in the interface.
* Added testCompression.php for testing concatenated object compression ratio
Doxygen documentation update:
* Changed alls @addtogroup to @ingroup. @addtogroup adds the comment to the group description, but doesn't add the file, class, function, ... to the group like @ingroup does. See for example http://svn.wikimedia.org/doc/group__SpecialPage.html where it's impossible to see related files, classes, ... that should belong to that group.
* Added @file to file description, it seems that it should be explicitely decalred for file descriptions, otherwise doxygen will think that the comment document the first class, variabled, function, ... that is in that file.
* Removed some empty comments
* Removed some ?>
Added following groups:
* ExternalStorage
* JobQueue
* MaintenanceLanguage
One more thing: there are still a lot of warnings when generating the doc.