Page Menu
Home
Sealhub
Search
Configure Global Search
Log In
Files
F22395417
ArcanistPHPCloseTagXHPASTLinterRule.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Authored By
Unknown
Size
544 B
Referenced Files
None
Subscribers
None
ArcanistPHPCloseTagXHPASTLinterRule.php
View Options
<?php
final
class
ArcanistPHPCloseTagXHPASTLinterRule
extends
ArcanistXHPASTLinterRule
{
const
ID
=
8
;
public
function
getLintName
()
{
return
pht
(
'Use of Close Tag "%s"'
,
'?>'
);
}
public
function
process
(
XHPASTNode
$root
)
{
$inline_html
=
$root
->
selectDescendantsOfType
(
'n_INLINE_HTML'
);
if
(
$inline_html
)
{
return
;
}
foreach
(
$root
->
selectTokensOfType
(
'T_CLOSE_TAG'
)
as
$token
)
{
$this
->
raiseLintAtToken
(
$token
,
pht
(
'Do not use the PHP closing tag, "%s".'
,
'?>'
));
}
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Fri, Nov 27, 16:26 (1 d, 20 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1223760
Default Alt Text
ArcanistPHPCloseTagXHPASTLinterRule.php (544 B)
Attached To
Mode
R118 Arcanist - fork
Attached
Detach File
Event Timeline