Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F2891554
ArcanistPhutilXHPASTLinterStandard.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Advanced/Developer...
View Handle
View Hovercard
Size
1 KB
Referenced Files
None
Subscribers
None
ArcanistPhutilXHPASTLinterStandard.php
View Options
<?php
final
class
ArcanistPhutilXHPASTLinterStandard
extends
ArcanistLinterStandard
{
public
function
getKey
(
)
{
return
'phutil.xhpast'
;
}
public
function
getName
(
)
{
return
pht
(
'Phutil XHPAST'
)
;
}
public
function
getDescription
(
)
{
return
pht
(
'PHP Coding Standards for Phutil libraries.'
)
;
}
public
function
supportsLinter
(
ArcanistLinter
$linter
)
{
return
$linter
instanceof
ArcanistXHPASTLinter
;
}
public
function
getLinterConfiguration
(
)
{
return
array
(
'xhpast.blacklisted.function'
=>
array
(
'eval'
=>
pht
(
'The `%s` function should be avoided. It is potentially unsafe '
.
'and makes debugging more difficult.'
,
'eval'
)
,
)
,
'xhpast.php-version'
=>
'5.2.3'
,
'xhpast.php-version.windows'
=>
'5.3.0'
,
'xhpast.dynamic-string.classes'
=>
array
(
'ExecFuture'
=>
0
,
)
,
'xhpast.dynamic-string.functions'
=>
array
(
'pht'
=>
0
,
'hsprintf'
=>
0
,
'jsprintf'
=>
0
,
'hgsprintf'
=>
0
,
'csprintf'
=>
0
,
'vcsprintf'
=>
0
,
'execx'
=>
0
,
'exec_manual'
=>
0
,
'phutil_passthru'
=>
0
,
'qsprintf'
=>
1
,
'vqsprintf'
=>
1
,
'queryfx'
=>
1
,
'queryfx_all'
=>
1
,
'queryfx_one'
=>
1
,
)
,
)
;
}
public
function
getLinterSeverityMap
(
)
{
$advice
=
ArcanistLintSeverity
::
SEVERITY_ADVICE
;
$error
=
ArcanistLintSeverity
::
SEVERITY_ERROR
;
$warning
=
ArcanistLintSeverity
::
SEVERITY_WARNING
;
return
array
(
ArcanistTodoCommentXHPASTLinterRule
::
ID
=>
$advice
,
ArcanistCommentSpacingXHPASTLinterRule
::
ID
=>
$error
,
ArcanistRaggedClassTreeEdgeXHPASTLinterRule
::
ID
=>
$warning
,
)
;
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Sun, Jan 19, 15:21 (3 w, 1 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1121041
Default Alt Text
ArcanistPhutilXHPASTLinterStandard.php (1 KB)
Attached To
Mode
rARC Arcanist
Attached
Detach File
Event Timeline
Log In to Comment