optionalTypeArgs top-level constant

Object const optionalTypeArgs

Annotation on type arguments that can safely be omitted.

Used to annotate a class, mixin, extension, function, method, or typedef declaration. Indicates that any type arguments of the declaration are optional.

Tools such as the analyzer and linter can use this information to suppress warnings that would otherwise require type arguments to be provided. The language itself always allows omitting type arguments, this annotation only affects optional and opt-in warnings about omitting type arguments.

Implementation

const Object optionalTypeArgs = _OptionalTypeArgs();