2004-02-18 02:15:00 +00:00
|
|
|
<?php
|
2004-09-02 23:28:24 +00:00
|
|
|
/**
|
2020-01-05 22:22:48 +00:00
|
|
|
* See docs/magicword.md.
|
2012-05-12 20:33:02 +00:00
|
|
|
*
|
|
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
|
|
|
* (at your option) any later version.
|
|
|
|
|
*
|
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
|
*
|
|
|
|
|
* You should have received a copy of the GNU General Public License along
|
|
|
|
|
* with this program; if not, write to the Free Software Foundation, Inc.,
|
|
|
|
|
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
|
|
|
|
* http://www.gnu.org/copyleft/gpl.html
|
2008-03-12 17:37:03 +00:00
|
|
|
*
|
WARNING: HUGE COMMIT
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.
2008-05-20 17:13:28 +00:00
|
|
|
* @file
|
|
|
|
|
* @ingroup Parser
|
2004-09-02 23:28:24 +00:00
|
|
|
*/
|
2003-08-31 09:46:37 +00:00
|
|
|
|
2022-12-09 12:28:41 +00:00
|
|
|
namespace MediaWiki\Parser;
|
|
|
|
|
|
|
|
|
|
use Language;
|
2018-07-24 16:44:09 +00:00
|
|
|
use MediaWiki\MediaWikiServices;
|
2022-12-09 12:28:41 +00:00
|
|
|
use MWException;
|
|
|
|
|
use StringUtils;
|
2018-07-24 16:44:09 +00:00
|
|
|
|
2004-09-02 23:28:24 +00:00
|
|
|
/**
|
2012-07-10 12:48:06 +00:00
|
|
|
* This class encapsulates "magic words" such as "#redirect", __NOTOC__, etc.
|
2012-02-01 20:53:38 +00:00
|
|
|
*
|
|
|
|
|
* @par Usage:
|
|
|
|
|
* @code
|
2018-07-24 16:44:09 +00:00
|
|
|
* if ( $magicWordFactory->get( 'redirect' )->match( $text ) ) {
|
2012-02-01 20:53:38 +00:00
|
|
|
* // some code
|
|
|
|
|
* }
|
|
|
|
|
* @endcode
|
2006-01-07 13:09:30 +00:00
|
|
|
*
|
|
|
|
|
* Please avoid reading the data out of one of these objects and then writing
|
2004-09-02 23:28:24 +00:00
|
|
|
* special case code. If possible, add another match()-like function here.
|
2004-09-03 23:00:01 +00:00
|
|
|
*
|
2012-01-18 17:43:08 +00:00
|
|
|
* To add magic words in an extension, use $magicWords in a file listed in
|
|
|
|
|
* $wgExtensionMessagesFiles[].
|
2012-07-10 12:48:06 +00:00
|
|
|
*
|
2012-02-01 20:53:38 +00:00
|
|
|
* @par Example:
|
|
|
|
|
* @code
|
2016-09-12 10:06:37 +00:00
|
|
|
* $magicWords = [];
|
2012-01-18 17:43:08 +00:00
|
|
|
*
|
2016-09-12 10:06:37 +00:00
|
|
|
* $magicWords['en'] = [
|
2017-02-25 21:53:36 +00:00
|
|
|
* 'magicwordkey' => [ 0, 'case_insensitive_magic_word' ],
|
|
|
|
|
* 'magicwordkey2' => [ 1, 'CASE_sensitive_magic_word2' ],
|
2016-09-12 10:06:37 +00:00
|
|
|
* ];
|
2012-02-01 20:53:38 +00:00
|
|
|
* @endcode
|
2012-01-18 17:43:08 +00:00
|
|
|
*
|
2020-06-10 16:28:20 +00:00
|
|
|
* For magic words which name Parser double underscore names, add a
|
|
|
|
|
* GetDoubleUnderscoreIDs hook. Use string keys.
|
|
|
|
|
*
|
|
|
|
|
* For magic words which name Parser magic variables, add a GetMagicVariableIDs
|
2006-07-14 16:36:35 +00:00
|
|
|
* hook. Use string keys.
|
|
|
|
|
*
|
WARNING: HUGE COMMIT
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.
2008-05-20 17:13:28 +00:00
|
|
|
* @ingroup Parser
|
2004-09-02 23:28:24 +00:00
|
|
|
*/
|
2003-08-31 09:46:37 +00:00
|
|
|
class MagicWord {
|
2019-08-05 17:00:00 +00:00
|
|
|
/** #@- */
|
2014-05-12 14:42:51 +00:00
|
|
|
|
2023-07-25 11:09:42 +00:00
|
|
|
/** @var string|null Potentially null for a short time before {@see load} is called */
|
2014-05-12 14:42:51 +00:00
|
|
|
public $mId;
|
|
|
|
|
|
2017-10-02 11:52:17 +00:00
|
|
|
/** @var string[] */
|
2014-05-12 14:42:51 +00:00
|
|
|
public $mSynonyms;
|
|
|
|
|
|
|
|
|
|
/** @var bool */
|
|
|
|
|
public $mCaseSensitive;
|
|
|
|
|
|
|
|
|
|
/** @var string */
|
|
|
|
|
private $mRegex = '';
|
|
|
|
|
|
|
|
|
|
/** @var string */
|
|
|
|
|
private $mRegexStart = '';
|
|
|
|
|
|
|
|
|
|
/** @var string */
|
|
|
|
|
private $mRegexStartToEnd = '';
|
|
|
|
|
|
|
|
|
|
/** @var string */
|
|
|
|
|
private $mBaseRegex = '';
|
|
|
|
|
|
2018-07-26 12:21:31 +00:00
|
|
|
/** @var Language */
|
|
|
|
|
private $contLang;
|
|
|
|
|
|
2019-08-05 17:00:00 +00:00
|
|
|
/** #@- */
|
2004-01-07 02:51:47 +00:00
|
|
|
|
2017-10-02 11:52:17 +00:00
|
|
|
/**
|
|
|
|
|
* Create a new MagicWord object
|
|
|
|
|
*
|
2018-07-24 16:44:09 +00:00
|
|
|
* Use factory instead: MagicWordFactory::get
|
2017-10-02 11:52:17 +00:00
|
|
|
*
|
2018-06-26 21:14:43 +00:00
|
|
|
* @param string|null $id The internal name of the magic word
|
2017-10-02 11:52:17 +00:00
|
|
|
* @param string[]|string $syn synonyms for the magic word
|
|
|
|
|
* @param bool $cs If magic word is case sensitive
|
2018-07-26 12:21:31 +00:00
|
|
|
* @param Language|null $contLang Content language
|
2017-10-02 11:52:17 +00:00
|
|
|
*/
|
2018-07-26 12:21:31 +00:00
|
|
|
public function __construct( $id = null, $syn = [], $cs = false, Language $contLang = null ) {
|
2003-08-31 09:46:37 +00:00
|
|
|
$this->mId = $id;
|
|
|
|
|
$this->mSynonyms = (array)$syn;
|
|
|
|
|
$this->mCaseSensitive = $cs;
|
2019-04-15 08:48:13 +00:00
|
|
|
$this->contLang = $contLang ?: MediaWikiServices::getInstance()->getContentLanguage();
|
2003-08-31 09:46:37 +00:00
|
|
|
}
|
|
|
|
|
|
2011-05-21 19:55:05 +00:00
|
|
|
/**
|
|
|
|
|
* Initialises this object with an ID
|
|
|
|
|
*
|
2017-10-02 11:52:17 +00:00
|
|
|
* @param string $id
|
2012-08-04 23:47:23 +00:00
|
|
|
* @throws MWException
|
2011-05-21 19:55:05 +00:00
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function load( $id ) {
|
2003-08-31 09:46:37 +00:00
|
|
|
$this->mId = $id;
|
2018-07-26 12:21:31 +00:00
|
|
|
$this->contLang->getMagic( $this );
|
2006-10-02 17:04:13 +00:00
|
|
|
if ( !$this->mSynonyms ) {
|
2012-06-05 22:58:54 +00:00
|
|
|
throw new MWException( "Error: invalid magic word '$id'" );
|
2006-10-02 17:04:13 +00:00
|
|
|
}
|
2003-08-31 09:46:37 +00:00
|
|
|
}
|
2006-01-07 13:31:29 +00:00
|
|
|
|
2004-09-02 23:28:24 +00:00
|
|
|
/**
|
|
|
|
|
* Preliminary initialisation
|
2020-06-26 12:14:23 +00:00
|
|
|
* @internal
|
2004-09-02 23:28:24 +00:00
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function initRegex() {
|
2011-02-16 07:24:36 +00:00
|
|
|
// Sort the synonyms by length, descending, so that the longest synonym
|
|
|
|
|
// matches in precedence to the shortest
|
|
|
|
|
$synonyms = $this->mSynonyms;
|
2023-10-04 15:19:14 +00:00
|
|
|
usort( $synonyms, static fn ( $a, $b ) => strlen( $b ) <=> strlen( $a ) );
|
2008-04-14 07:45:50 +00:00
|
|
|
|
2016-02-17 09:09:32 +00:00
|
|
|
$escSyn = [];
|
2013-04-20 22:49:30 +00:00
|
|
|
foreach ( $synonyms as $synonym ) {
|
2006-01-08 04:25:43 +00:00
|
|
|
// In case a magic word contains /, like that's going to happen;)
|
|
|
|
|
$escSyn[] = preg_quote( $synonym, '/' );
|
2013-04-20 22:49:30 +00:00
|
|
|
}
|
2004-08-22 17:24:50 +00:00
|
|
|
$this->mBaseRegex = implode( '|', $escSyn );
|
2008-04-14 07:45:50 +00:00
|
|
|
|
2006-10-08 13:00:42 +00:00
|
|
|
$case = $this->mCaseSensitive ? '' : 'iu';
|
2003-08-31 09:46:37 +00:00
|
|
|
$this->mRegex = "/{$this->mBaseRegex}/{$case}";
|
2005-05-04 07:49:42 +00:00
|
|
|
$this->mRegexStart = "/^(?:{$this->mBaseRegex})/{$case}";
|
2013-12-17 18:14:15 +00:00
|
|
|
$this->mRegexStartToEnd = "/^(?:{$this->mBaseRegex})$/{$case}";
|
2003-08-31 09:46:37 +00:00
|
|
|
}
|
2006-01-07 13:31:29 +00:00
|
|
|
|
2004-09-02 23:28:24 +00:00
|
|
|
/**
|
|
|
|
|
* Gets a regex representing matching the word
|
2011-05-21 19:55:05 +00:00
|
|
|
*
|
|
|
|
|
* @return string
|
2004-09-02 23:28:24 +00:00
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function getRegex() {
|
2013-02-03 20:05:24 +00:00
|
|
|
if ( $this->mRegex == '' ) {
|
2003-08-31 09:46:37 +00:00
|
|
|
$this->initRegex();
|
|
|
|
|
}
|
|
|
|
|
return $this->mRegex;
|
|
|
|
|
}
|
|
|
|
|
|
2006-01-08 05:35:03 +00:00
|
|
|
/**
|
|
|
|
|
* Gets the regexp case modifier to use, i.e. i or nothing, to be used if
|
|
|
|
|
* one is using MagicWord::getBaseRegex(), otherwise it'll be included in
|
|
|
|
|
* the complete expression
|
2011-05-21 19:55:05 +00:00
|
|
|
*
|
|
|
|
|
* @return string
|
2006-01-08 05:35:03 +00:00
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function getRegexCase() {
|
2013-04-20 22:49:30 +00:00
|
|
|
if ( $this->mRegex === '' ) {
|
2006-01-08 05:35:03 +00:00
|
|
|
$this->initRegex();
|
2013-04-20 22:49:30 +00:00
|
|
|
}
|
2006-01-08 05:35:03 +00:00
|
|
|
|
2006-10-08 13:00:42 +00:00
|
|
|
return $this->mCaseSensitive ? '' : 'iu';
|
2006-01-08 05:35:03 +00:00
|
|
|
}
|
|
|
|
|
|
2004-09-02 23:28:24 +00:00
|
|
|
/**
|
|
|
|
|
* Gets a regex matching the word, if it is at the string start
|
2011-05-21 19:55:05 +00:00
|
|
|
*
|
|
|
|
|
* @return string
|
2004-09-02 23:28:24 +00:00
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function getRegexStart() {
|
2013-02-03 20:05:24 +00:00
|
|
|
if ( $this->mRegex == '' ) {
|
2003-08-31 09:46:37 +00:00
|
|
|
$this->initRegex();
|
|
|
|
|
}
|
|
|
|
|
return $this->mRegexStart;
|
|
|
|
|
}
|
2004-01-12 00:55:01 +00:00
|
|
|
|
2013-12-17 18:14:15 +00:00
|
|
|
/**
|
|
|
|
|
* Gets a regex matching the word from start to end of a string
|
|
|
|
|
*
|
|
|
|
|
* @return string
|
|
|
|
|
* @since 1.23
|
|
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function getRegexStartToEnd() {
|
2013-12-17 18:14:15 +00:00
|
|
|
if ( $this->mRegexStartToEnd == '' ) {
|
|
|
|
|
$this->initRegex();
|
|
|
|
|
}
|
|
|
|
|
return $this->mRegexStartToEnd;
|
|
|
|
|
}
|
|
|
|
|
|
2004-09-02 23:28:24 +00:00
|
|
|
/**
|
|
|
|
|
* regex without the slashes and what not
|
2011-05-21 19:55:05 +00:00
|
|
|
*
|
|
|
|
|
* @return string
|
2004-09-02 23:28:24 +00:00
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function getBaseRegex() {
|
2013-02-03 20:05:24 +00:00
|
|
|
if ( $this->mRegex == '' ) {
|
2003-08-31 09:46:37 +00:00
|
|
|
$this->initRegex();
|
|
|
|
|
}
|
|
|
|
|
return $this->mBaseRegex;
|
|
|
|
|
}
|
2006-01-07 13:31:29 +00:00
|
|
|
|
2004-09-02 23:28:24 +00:00
|
|
|
/**
|
2010-01-12 07:24:25 +00:00
|
|
|
* Returns true if the text contains the word
|
2011-05-21 19:55:05 +00:00
|
|
|
*
|
2014-04-22 11:07:02 +00:00
|
|
|
* @param string $text
|
2011-05-21 19:55:05 +00:00
|
|
|
*
|
2010-01-12 07:24:25 +00:00
|
|
|
* @return bool
|
2004-09-02 23:28:24 +00:00
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function match( $text ) {
|
2010-01-12 07:24:25 +00:00
|
|
|
return (bool)preg_match( $this->getRegex(), $text );
|
2003-08-31 09:46:37 +00:00
|
|
|
}
|
|
|
|
|
|
2013-12-17 18:14:15 +00:00
|
|
|
/**
|
|
|
|
|
* Returns true if the text matched the word
|
|
|
|
|
*
|
2014-04-22 11:07:02 +00:00
|
|
|
* @param string $text
|
2013-12-17 18:14:15 +00:00
|
|
|
*
|
|
|
|
|
* @return bool
|
|
|
|
|
* @since 1.23
|
|
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function matchStartToEnd( $text ) {
|
2013-12-17 18:14:15 +00:00
|
|
|
return (bool)preg_match( $this->getRegexStartToEnd(), $text );
|
|
|
|
|
}
|
|
|
|
|
|
2004-09-02 23:28:24 +00:00
|
|
|
/**
|
|
|
|
|
* Returns true if the text matches the word, and alters the
|
|
|
|
|
* input string, removing all instances of the word
|
2011-05-21 19:55:05 +00:00
|
|
|
*
|
2017-08-11 00:23:16 +00:00
|
|
|
* @param string &$text
|
2011-05-21 19:55:05 +00:00
|
|
|
*
|
|
|
|
|
* @return bool
|
2004-09-02 23:28:24 +00:00
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function matchAndRemove( &$text ) {
|
2023-10-04 15:19:14 +00:00
|
|
|
$text = preg_replace( $this->getRegex(), '', $text, -1, $count );
|
|
|
|
|
return (bool)$count;
|
2003-08-31 09:46:37 +00:00
|
|
|
}
|
|
|
|
|
|
2011-05-21 19:55:05 +00:00
|
|
|
/**
|
2017-08-11 00:23:16 +00:00
|
|
|
* @param string &$text
|
2011-05-21 19:55:05 +00:00
|
|
|
* @return bool
|
|
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function matchStartAndRemove( &$text ) {
|
2023-10-04 15:19:14 +00:00
|
|
|
$text = preg_replace( $this->getRegexStart(), '', $text, -1, $count );
|
|
|
|
|
return (bool)$count;
|
2006-07-14 16:36:35 +00:00
|
|
|
}
|
2004-03-20 15:03:26 +00:00
|
|
|
|
2004-09-02 23:28:24 +00:00
|
|
|
/**
|
|
|
|
|
* Replaces the word with something else
|
2011-05-21 19:55:05 +00:00
|
|
|
*
|
2014-04-22 11:07:02 +00:00
|
|
|
* @param string $replacement
|
|
|
|
|
* @param string $subject
|
|
|
|
|
* @param int $limit
|
2011-05-21 19:55:05 +00:00
|
|
|
*
|
|
|
|
|
* @return string
|
|
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function replace( $replacement, $subject, $limit = -1 ) {
|
2014-05-12 14:42:51 +00:00
|
|
|
$res = preg_replace(
|
|
|
|
|
$this->getRegex(),
|
|
|
|
|
StringUtils::escapeRegexReplacement( $replacement ),
|
|
|
|
|
$subject,
|
|
|
|
|
$limit
|
|
|
|
|
);
|
2004-01-07 02:51:47 +00:00
|
|
|
return $res;
|
2003-09-21 13:10:10 +00:00
|
|
|
}
|
|
|
|
|
|
2004-09-02 23:28:24 +00:00
|
|
|
/**
|
|
|
|
|
* Accesses the synonym list directly
|
2011-05-21 19:55:05 +00:00
|
|
|
*
|
2014-04-22 11:07:02 +00:00
|
|
|
* @param int $i
|
2011-05-21 19:55:05 +00:00
|
|
|
*
|
|
|
|
|
* @return string
|
2004-09-02 23:28:24 +00:00
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function getSynonym( $i ) {
|
2003-09-21 13:10:10 +00:00
|
|
|
return $this->mSynonyms[$i];
|
|
|
|
|
}
|
2004-01-07 02:51:47 +00:00
|
|
|
|
2011-05-21 19:55:05 +00:00
|
|
|
/**
|
2017-10-02 11:52:17 +00:00
|
|
|
* @return string[]
|
2011-05-21 19:55:05 +00:00
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function getSynonyms() {
|
2006-07-02 17:47:24 +00:00
|
|
|
return $this->mSynonyms;
|
|
|
|
|
}
|
|
|
|
|
|
2011-05-21 19:55:05 +00:00
|
|
|
/**
|
|
|
|
|
* @return bool
|
|
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function isCaseSensitive() {
|
2006-07-03 08:57:29 +00:00
|
|
|
return $this->mCaseSensitive;
|
|
|
|
|
}
|
Basic integrated audio/video support, with Ogg implementation.
* JavaScript video player based loosely on Greg Maxwell's player
* Image page text snippet customisation
* Abstraction of transform parameters in the parser. Introduced Linker::makeImageLink2().
* Made canRender(), mustRender() depend on file, not just on handler. Moved width=0, height=0 checking to ImageHandler::canRender(), since audio streams have width=height=0 but should be rendered.
Also:
* Automatic upgrade for oldimage rows on image page view, allows media handler selection based on oi_*_mime
* oi_*_mime unconditionally referenced, REQUIRES SCHEMA UPGRADE
* Don't destroy file info for missing files on upgrade
* Simple, centralised extension message file handling
* Made MessageCache::loadAllMessages non-static, optimised for repeated-call case due to abuse in User.php
* Support for lightweight parser output hooks, with callback whitelist for security
* Moved Linker::formatSize() to Language, to join the new formatTimePeriod() and formatBitrate()
* Introduced MagicWordArray, regex capture trick requires that magic word IDs DO NOT CONTAIN HYPHENS.
2007-08-15 10:50:09 +00:00
|
|
|
|
2011-05-21 19:55:05 +00:00
|
|
|
/**
|
2017-10-02 11:52:17 +00:00
|
|
|
* @return string
|
2011-05-21 19:55:05 +00:00
|
|
|
*/
|
2016-03-01 10:56:04 +00:00
|
|
|
public function getId() {
|
Basic integrated audio/video support, with Ogg implementation.
* JavaScript video player based loosely on Greg Maxwell's player
* Image page text snippet customisation
* Abstraction of transform parameters in the parser. Introduced Linker::makeImageLink2().
* Made canRender(), mustRender() depend on file, not just on handler. Moved width=0, height=0 checking to ImageHandler::canRender(), since audio streams have width=height=0 but should be rendered.
Also:
* Automatic upgrade for oldimage rows on image page view, allows media handler selection based on oi_*_mime
* oi_*_mime unconditionally referenced, REQUIRES SCHEMA UPGRADE
* Don't destroy file info for missing files on upgrade
* Simple, centralised extension message file handling
* Made MessageCache::loadAllMessages non-static, optimised for repeated-call case due to abuse in User.php
* Support for lightweight parser output hooks, with callback whitelist for security
* Moved Linker::formatSize() to Language, to join the new formatTimePeriod() and formatBitrate()
* Introduced MagicWordArray, regex capture trick requires that magic word IDs DO NOT CONTAIN HYPHENS.
2007-08-15 10:50:09 +00:00
|
|
|
return $this->mId;
|
|
|
|
|
}
|
2003-08-31 09:46:37 +00:00
|
|
|
}
|
2022-12-09 12:28:41 +00:00
|
|
|
|
2023-08-28 18:39:35 +00:00
|
|
|
/**
|
|
|
|
|
* @deprecated since 1.40
|
|
|
|
|
*/
|
2022-12-09 12:28:41 +00:00
|
|
|
class_alias( MagicWord::class, 'MagicWord' );
|