1
0
mirror of https://github.com/danog/psalm.git synced 2025-01-22 05:41:20 +01:00

Merge pull request #6902 from orklah/forbidEcho

deprecate forbidEcho
This commit is contained in:
orklah 2022-01-14 19:37:24 +01:00 committed by GitHub
commit cdbaf0e14f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 2 deletions

View File

@ -67,7 +67,13 @@
<xs:attribute name="findUnusedCode" type="xs:boolean" default="false" />
<xs:attribute name="findUnusedVariablesAndParams" type="xs:boolean" default="false" />
<xs:attribute name="findUnusedPsalmSuppress" type="xs:boolean" default="false" />
<xs:attribute name="forbidEcho" type="xs:boolean" default="false" />
<xs:attribute name="forbidEcho" type="xs:boolean" default="false">
<xs:annotation>
<xs:documentation xml:lang="en">
Deprecated. Will be replaced by adding echo to forbiddenFunctions in Psalm 5.
</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="hideExternalErrors" type="xs:boolean" default="false" />
<xs:attribute name="hoistConstants" type="xs:boolean" default="false" />
<xs:attribute name="ignoreInternalFunctionFalseReturn" type="xs:boolean" default="true" />

View File

@ -1,7 +1,7 @@
# ForbiddenEcho
Emitted when Psalm encounters an echo statement and the `forbidEcho` flag in your config is set to `true`
This issue is deprecated and will be removed in Psalm 5. Adding echo to forbiddenFunctions in config will result in ForbiddenCode issue instead
```php
<?php

View File

@ -792,6 +792,7 @@ class Config
$deprecated_attributes = [
'allowCoercionFromStringToClassConst',
'allowPhpStormGenerics',
'forbidEcho'
];
$deprecated_elements = [