Migrate to new phan

Bug: T216908
Change-Id: I28faf3638dfbc20b84ba78d476b02f7bbc8cbd6a
这个提交包含在:
Matěj Suchánek 2019-03-17 16:42:15 +01:00
父节点 999417afea
当前提交 89c61833c2
共有 6 个文件被更改,包括 12 次插入9 次删除

1
.gitignore vendored
查看文件

@ -21,4 +21,3 @@ project.index
## Sublime
sublime-*
sftp-config.json
tests/phan/issues

3
.phan/config.php 普通文件
查看文件

@ -0,0 +1,3 @@
<?php
return require __DIR__ . '/../vendor/mediawiki/mediawiki-phan-config/src/config.php';

查看文件

@ -4,7 +4,7 @@
"jakub-onderka/php-console-highlighter": "0.3.2",
"mediawiki/mediawiki-codesniffer": "24.0.0",
"mediawiki/minus-x": "0.3.1",
"mediawiki/mediawiki-phan-config": "0.3.0"
"mediawiki/mediawiki-phan-config": "0.5.0"
},
"scripts": {
"fix": [

查看文件

@ -30,6 +30,7 @@ class CategoryTree {
public $mOptions = [];
/**
* @suppress PhanTypeInvalidDimOffset
* @param array $options
*/
public function __construct( array $options ) {
@ -320,6 +321,7 @@ class CategoryTree {
/**
* Custom tag implementation. This is called by CategoryTreeHooks::parserHook, which is used to
* load CategoryTreeFunctions.php on demand.
* @suppress PhanParamReqAfterOpt $parser is not optional but nullable
* @param Parser|null $parser
* @param string $category
* @param bool $hideroot
@ -707,6 +709,7 @@ class CategoryTree {
/**
* Create a string which format the page, subcat and file counts of a category
* @suppress PhanParamReqAfterOpt $cat is not optional but nullable
* @param IContextSource $context
* @param Category|null $cat
* @param int $countMode
@ -791,6 +794,7 @@ class CategoryTree {
/**
* Internal function to cap depth
* @suppress PhanPluginDuplicateConditionalNullCoalescing until PHP7 is required
* @param string $mode
* @param int $depth
* @return int|mixed

查看文件

@ -138,6 +138,7 @@ class CategoryTreeHooks {
/**
* Entry point for the <categorytree> tag parser hook.
* This loads CategoryTreeFunctions.php and calls CategoryTree::getTag()
* @suppress PhanUndeclaredProperty ParserOutput->mCategoryTreeTag
* @param string $cat
* @param array $argv
* @param Parser|null $parser
@ -177,6 +178,7 @@ class CategoryTreeHooks {
* Hook callback that injects messages and things into the <head> tag,
* if needed in the current page.
* Does nothing if $parserOutput->mCategoryTreeTag is not set
* @suppress PhanUndeclaredProperty ParserOutput->mCategoryTreeTag
* @param OutputPage $outputPage
* @param ParserOutput $parserOutput
*/
@ -256,6 +258,7 @@ class CategoryTreeHooks {
/**
* Hook handler for the SpecialTrackingCategories::preprocess hook
* @suppress PhanUndeclaredProperty SpecialPage->categoryTreeCategories
* @param SpecialPage $specialPage SpecialTrackingCategories object
* @param array $trackingCategories [ 'msg' => Title, 'cats' => Title[] ]
*/
@ -286,6 +289,7 @@ class CategoryTreeHooks {
/**
* Hook handler for the SpecialTrackingCategories::generateCatLink hook
* @suppress PhanUndeclaredProperty SpecialPage->categoryTreeCategories
* @param SpecialPage $specialPage SpecialTrackingCategories object
* @param Title $catTitle Title object of the linked category
* @param string &$html Result html

查看文件

@ -1,7 +0,0 @@
<?php
$cfg = require __DIR__ . '/../../vendor/mediawiki/mediawiki-phan-config/src/config.php';
// SpecialPage->categoryTreeCategories
$cfg['suppress_issue_types'][] = 'PhanUndeclaredProperty';
return $cfg;