Skip to content

Commit 56cb8de

Browse files
keertipCommit Queue
authored and
Commit Queue
committed
Make ParsedUnitResult and ParsedLibraryResult superclasses of ResolvedUnitResult and ResolvedLibraryResult respectively.
Change-Id: I00a8c07b8487c27c22997523803028fd01b4293a Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/306909 Reviewed-by: Brian Wilkerson <[email protected]> Commit-Queue: Keerti Parthasarathy <[email protected]>
1 parent 03b2abf commit 56cb8de

File tree

1 file changed

+3
-13
lines changed

1 file changed

+3
-13
lines changed

pkg/analyzer/lib/dart/analysis/results.dart

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -234,21 +234,17 @@ abstract class ParseStringResult {
234234
///
235235
/// Clients may not extend, implement or mix-in this class.
236236
abstract class ResolvedLibraryResult
237-
implements SomeResolvedLibraryResult, AnalysisResult {
237+
implements ParsedLibraryResult, SomeResolvedLibraryResult {
238238
/// The element representing this library.
239239
LibraryElement get element;
240240

241241
/// The type provider used when resolving the library.
242242
TypeProvider get typeProvider;
243243

244244
/// The resolved units of the library.
245+
@override
245246
List<ResolvedUnitResult> get units;
246247

247-
/// Return the declaration of the [element], or `null` if the [element]
248-
/// is synthetic. Throw [ArgumentError] if the [element] is not defined in
249-
/// this library.
250-
ElementDeclarationResult? getElementDeclaration(Element element);
251-
252248
/// Return the resolved unit corresponding to the [path], or `null` if there
253249
/// is no such unit.
254250
ResolvedUnitResult? unitWithPath(String path);
@@ -259,10 +255,7 @@ abstract class ResolvedLibraryResult
259255
///
260256
/// Clients may not extend, implement or mix-in this class.
261257
abstract class ResolvedUnitResult
262-
implements SomeResolvedUnitResult, AnalysisResultWithErrors {
263-
/// The content of the file that was scanned, parsed and resolved.
264-
String get content;
265-
258+
implements ParsedUnitResult, SomeResolvedUnitResult {
266259
/// Return `true` if the file exists.
267260
bool get exists;
268261

@@ -274,9 +267,6 @@ abstract class ResolvedUnitResult
274267

275268
/// The type system used when resolving the compilation [unit].
276269
TypeSystem get typeSystem;
277-
278-
/// The fully resolved compilation unit for the [content].
279-
CompilationUnit get unit;
280270
}
281271

282272
/// The result of computing all of the errors contained in a single file, both

0 commit comments

Comments
 (0)