== Why is this an issue?

Overriding a method just to call the overridden function from the base class without performing any other actions can be useless and misleading.


There are cases when it is justified because redeclaring the function allows some side effects:

* if a type (return type or a parameter type) is not exactly the same as the super member
* if the covariant keyword is added to one of the parameters
* if documentation comments are present on the member
* if the member has annotations other than `@override`
* if the member is not annotated with `@protected`, and the super member is

=== Noncompliant code example

[source,dart,diff-id=1,diff-type=noncompliant]
----
class Child extends Parent {
  @override
  void foo() {
    super.foo();
  }
}
----

=== Compliant solution

[source,dart,diff-id=1,diff-type=compliant]
----
class Child extends Parent {
  @override
  void foo() {
    bar();
  }
}
----

== Resources

* Dart Docs - https://dart.dev/tools/linter-rules/unnecessary_overrides[Dart Linter rule - unnecessary_overrides]

ifdef::env-github,rspecator-view[]

'''
== Implementation Specification
(visible only on this page)

=== Message

* Unnecessary override.

=== Highlighting

The identifier of the overridden method.

'''
== Comments And Links
(visible only on this page)

endif::env-github,rspecator-view[]
