Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions PHPCompatibilitySymfonyPolyfillPHP85/ruleset.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
Detection for the DelayedTargetValidation and NoDiscard attributes is incomplete in PHPCompatibility 10.0.0-alpha1.
This section should be filled out once the detection implementation is known.
-->
<exclude name="PHPCompatibility.Classes.NewClasses.filter_filterexceptionFound"/>
<exclude name="PHPCompatibility.Classes.NewClasses.filter_filterfailedexceptionFound"/>
</rule>

<!-- Prevent false positives being thrown when run over the code of polyfill-php84 itself. -->
Expand All @@ -27,6 +29,10 @@
<exclude-pattern>/polyfill-php85/Resources/stubs/NoDiscard\.php$</exclude-pattern>
</rule>

<rule ref="PHPCompatibility.Namespaces.ReservedNames.filterFound">
<exclude-pattern>/polyfill-php85/Resources/stubs/Filter/Filter*Exception\.php$</exclude-pattern>
</rule>

<!-- This is fine as the autoloading for this file should only ever be triggered when on PHP 8.0 or higher. -->
<rule ref="PHPCompatibility.Classes.NewTypedProperties.Found">
<exclude-pattern>/polyfill-php85/Resources/stubs/NoDiscard\.php$</exclude-pattern>
Expand Down
3 changes: 3 additions & 0 deletions Test/SymfonyPolyfillPHP85Test.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,6 @@
#[NoDiscard]
function dummy() {}
*/

try {
} catch (Filter\FilterException | Filter\FilterFailedException $e) {}
Loading