dynamic x;
x = (String a) => a.length; // should be OK
One common use case is Stream#listen's onError callback with StackTrace:
stream.listen(
(event) => ...,
onError: (dynamic e, StackTrace stackTrace) => ...
// ^^^^^^^^^^
// avoid_types_on_closure_parameters
+1, along with https://github.com/dart-lang/linter/issues/2131 I think this would make it match omit_local_variable_types, which seems desirable.
Most helpful comment
One common use case is
Stream#listen'sonErrorcallback withStackTrace: