mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-22 06:42:42 +01:00
Link interfaces as classes
Summary: We link classes from `extends` and `instanceof` (which can be both interface and class) and from `implements` (which is always interface). We don't need to split these two because they share the same namespace. If we decide to then we will need to: - Fix [[ https://secure.phabricator.com/diffusion/P/browse/master/src/applications/diffusion/controller/DiffusionSymbolController.php;66a300768a62bbc9$79 | DiffusionSymbolController ]] - Fix [[ https://secure.phabricator.com/diffusion/P/browse/master/webroot/rsrc/js/application/repository/repository-crossreference.js;66a300768a62bbc9$24 | repository-crossreference ]] - Allow more types in `DiffusionSymbolController`. Test Plan: Ran the script on secure.phabricator.com, clicked on `ArcanistLintRenderer` symbol. Reviewers: epriestley, alanh Reviewed By: epriestley CC: aran, Korvin Differential Revision: https://secure.phabricator.com/D3382
This commit is contained in:
parent
8d7f5eefae
commit
a44de4f76c
1 changed files with 2 additions and 1 deletions
|
@ -63,7 +63,8 @@ foreach (Futures($futures)->limit(8) as $file => $future) {
|
||||||
$interfaces = $root->selectDescendantsOfType('n_INTERFACE_DECLARATION');
|
$interfaces = $root->selectDescendantsOfType('n_INTERFACE_DECLARATION');
|
||||||
foreach ($interfaces as $interface) {
|
foreach ($interfaces as $interface) {
|
||||||
$interface_name = $interface->getChildByIndex(1);
|
$interface_name = $interface->getChildByIndex(1);
|
||||||
print_symbol($file, 'interface', $interface_name);
|
// We don't differentiate classes and interfaces in highlighters.
|
||||||
|
print_symbol($file, 'class', $interface_name);
|
||||||
$scopes[] = array($interface, $interface_name);
|
$scopes[] = array($interface, $interface_name);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue