incompatible_ lint
The rule '{0}' is incompatible with '{1}'.
The rule '{0}' is incompatible with {1}, which is included from {2} file{3}.
The rule '{0}' is incompatible with {1}.
Description
#The analyzer produces this diagnostic when two specified lint rules are incompatible, such as when they enforce opposite styles.
Example
#
The following code produces this diagnostic because the rules
prefer_single_quotes and prefer_double_quotes are incompatible with
each other:
// %uri="analysis_options.yaml"
linter:
rules:
- prefer_single_quotes
- prefer_double_quotes
Common fixes
#Remove all but one of the incompatible rules:
// %uri="analysis_options.yaml"
linter:
rules:
- prefer_single_quotes
Unless stated otherwise, the documentation on this site reflects Dart 3.10.3. Page last updated on 2025-12-5. View source or report an issue.