Skip to content

Commit

Permalink
Remove cross-export warning.
Browse files Browse the repository at this point in the history
  • Loading branch information
srawlins committed Nov 1, 2023
1 parent ab845cb commit a212e99
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 21 deletions.
13 changes: 0 additions & 13 deletions lib/src/model/model_element.dart
Original file line number Diff line number Diff line change
Expand Up @@ -538,19 +538,6 @@ abstract class ModelElement extends Canonicalization
};
}).toList(growable: true);

// Avoid claiming canonicalization for elements outside of this element's
// defining package.
// TODO(jcollins-g): Make the else block unconditional.
if (candidateLibraries.isNotEmpty &&
!candidateLibraries.any((l) => l.package == definingLibrary.package)) {
warn(PackageWarning.reexportedPrivateApiAcrossPackages,
message: definingLibrary.package.fullyQualifiedName,
referredFrom: candidateLibraries);
} else {
candidateLibraries
.removeWhere((l) => l.package != definingLibrary.package);
}

if (candidateLibraries.isEmpty) {
return null;
}
Expand Down
1 change: 0 additions & 1 deletion lib/src/model/package_graph.dart
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,6 @@ class PackageGraph with CommentReferable, Nameable, ModelBuilder {
PackageWarning.ambiguousDocReference ||
PackageWarning.ignoredCanonicalFor ||
PackageWarning.packageOrderGivesMissingPackageName ||
PackageWarning.reexportedPrivateApiAcrossPackages ||
PackageWarning.unresolvedDocReference ||
PackageWarning.unknownMacro ||
PackageWarning.unknownHtmlFragment ||
Expand Down
7 changes: 0 additions & 7 deletions lib/src/warnings.dart
Original file line number Diff line number Diff line change
Expand Up @@ -181,13 +181,6 @@ enum PackageWarning implements Comparable<PackageWarning> {
'The category-order flag on the command line was given the name of a '
'nonexistent package',
),
reexportedPrivateApiAcrossPackages(
'reexported-private-api-across-packages',
'private API of {0} is reexported by libraries in other packages: ',
shortHelp:
'One or more libraries reexports private API members from outside its '
'own package',
),
unresolvedDocReference(
'unresolved-doc-reference',
'unresolved doc reference [{0}]',
Expand Down

0 comments on commit a212e99

Please sign in to comment.