Skip to content

Commit

Permalink
Fix comment references in miscellaneous _fe_analyzer_shared code.
Browse files Browse the repository at this point in the history
Fix bracketed references in doc comments that previously pointed to
nowhere, in the following source files:
- pkg/_fe_analyzer_shared/lib/src/testing/id_testing.dart
- pkg/_fe_analyzer_shared/lib/src/util/colors.dart
- pkg/_fe_analyzer_shared/lib/src/util/options.dart
- pkg/_fe_analyzer_shared/lib/src/util/value_kind.dart

This is part of a larger effort to clean up _fe_analyzer_shared to the
point where the `comment_references` lint can be enabled.

Change-Id: I3008246560e551819f836a02d8881eb1389077f9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/375202
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
  • Loading branch information
stereotype441 authored and Commit Queue committed Jul 16, 2024
1 parent bc3b3ae commit cee1a76
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
5 changes: 1 addition & 4 deletions pkg/_fe_analyzer_shared/lib/src/testing/id_testing.dart
Original file line number Diff line number Diff line change
Expand Up @@ -241,9 +241,6 @@ void computeExpectedMap(Uri sourceUri, String filename, AnnotatedCode code,
///
/// If [testFile] is a file, use that directly. If it's a directory include
/// everything in that directory.
///
/// If [testLibDirectory] is not `null`, files in [testLibDirectory] with the
/// [testFile] name as a prefix are included.
TestData computeTestData(FileSystemEntity testFile,
{required Iterable<String> supportedMarkers,
required Uri createTestUri(Uri uri, String fileName),
Expand Down Expand Up @@ -491,7 +488,7 @@ String withAnnotations(String sourceCode, Map<int, List<String>> annotations) {
}

/// Checks [compiledData] against the expected data in [expectedMaps] derived
/// from [code].
/// from [testData].code.
Future<TestResult<T>> checkCode<T>(
MarkerOptions markerOptions,
String marker,
Expand Down
2 changes: 1 addition & 1 deletion pkg/_fe_analyzer_shared/lib/src/util/colors.dart
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ void Function(String) printEnableColorsReason = (_) {};
/// `true`.
///
/// Note: do not call this method directly, as it is expensive to
/// compute. Instead, use [CompilerContext.enableColors].
/// compute. Instead, use [enableColors].
bool _computeEnableColors() {
if (!stdout.supportsAnsiEscapes) {
printEnableColorsReason(
Expand Down
2 changes: 1 addition & 1 deletion pkg/_fe_analyzer_shared/lib/src/util/options.dart
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ class ParsedOptions {
/// arguments; anything following is treated as arguments (even if starting
/// with, for example, a `-`).
///
/// If an option isn't found in [specification], an error is thrown.
/// If an option isn't found in [options], an error is thrown.
///
/// Boolean options do not require an option value, but an optional value can
/// be provided using the forms `--option=value` where `value` can be `true`
Expand Down
3 changes: 3 additions & 0 deletions pkg/_fe_analyzer_shared/lib/src/util/value_kind.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.

/// @docImport '../parser/stack_listener.dart';
library;

import 'null_value.dart' show NullValue;

/// [ValueKind] is used in [StackListener.checkState] to document and check the
Expand Down

0 comments on commit cee1a76

Please sign in to comment.