Dart Analyze logoDart Analyze/
DRT-W1674

Invalid name in show combinator for imported libraryDRT-W1674

Major severityMajor
Bug Risk categoryBug Risk

The analyzer produces this diagnostic when a show combinator includes a name that isn't defined by the library being imported.

Example

The following code produces this diagnostic because dart:math doesn't define the name String:

import 'dart:math' show min, String;

var x = min(0, 1);

Common fixes

If a different name should be shown, then correct the name. Otherwise, remove the name from the list:

import 'dart:math' show min;

var x = min(0, 1);