---
title: "lint/operators/no-error-suppression"
pagination: false
---

{/* Generated by scripts/gen-rule-docs.py. Edit mapping.toml, not this file. */}

<RuleId id="lint/operators/no-error-suppression" />

In the [`code-quality`](/docs/rules/sets/code-quality) set. Unsafe fix: it can change behaviour. Intent: suspicious.

## What it does

Error control operator should be added to deprecation notices and/or removed from other cases.

## Configuration

```toml title="pun.toml"
[lint.rules]
"operators/no-error-suppression" = "error"
```

To skip it in some files, add an [override](/docs/configuration/pun-toml#lint) or a [`@pun-ignore-file`](/docs/configuration/ignore-comments) comment.

## Options

| Name | Type | Allowed values | Default | Upstream name |
| --- | --- | --- | --- | --- |
| `mute-deprecation-error` | `bool` | Any | `true` | `mute_deprecation_error` |
| `noise-remaining-usages` | `bool` | Any | `false` | `noise_remaining_usages` |
| `noise-remaining-usages-exclude` | `list` | Any | `[]` | `noise_remaining_usages_exclude` |

## Replaces

- [`error_suppression`](https://cs.symfony.com/doc/rules/language_construct/error_suppression.html) (php-cs-fixer, risky)
- [`no-error-control-operator`](https://mago.carthage.software/1.61.0/en/tools/linter/rules/#no-error-control-operator) (mago-linter)

[More lint/operators rules](/docs/rules/lint/operators) · [Edit this page](https://github.com/shipfastlabs/pun/edit/main/crates/pun-config/rules/mapping.toml)
