Skip to content

Commit

Permalink
Fix "the the" typo
Browse files Browse the repository at this point in the history
Closes #59926

GitOrigin-RevId: cb37bca
Change-Id: I6827241b22e99db455945afcdfbaee0450999ce9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/404923
Reviewed-by: Devon Carew <[email protected]>
Commit-Queue: Devon Carew <[email protected]>
Reviewed-by: Brian Wilkerson <[email protected]>
Reviewed-by: Johnni Winther <[email protected]>
  • Loading branch information
mabdelaal86 authored and Commit Queue committed Jan 21, 2025
1 parent e1eade6 commit 9b7bb9d
Show file tree
Hide file tree
Showing 23 changed files with 31 additions and 31 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ enum ConstraintGenerationSource {
/// `GenericInferrer.constrainGenericFunctionInContext` method.
genericFunctionInContext(description: 'GENERIC FUNCTION IN CONTEXT'),

/// The source of the constraint is the the context of the invocation whose
/// The source of the constraint is the context of the invocation whose
/// type is being inferred, being matched against the return type in function
/// or method being invoked.
returnType(description: 'RETURN TYPE');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2568,7 +2568,7 @@ abstract class TypeAnalyzerErrors<

/// Called for variable that is assigned more than once.
///
/// Returns an error object that is passed on the the caller.
/// Returns an error object that is passed on to the caller.
Error duplicateAssignmentPatternVariable({
required Variable variable,
required Pattern original,
Expand Down
2 changes: 1 addition & 1 deletion pkg/analysis_server/lib/src/analysis_server.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1120,7 +1120,7 @@ abstract class CommonServerContextManagerCallbacks
// If the removed file doesn't have an overlay, we need to clear any
// previous results.
if (!resourceProvider.hasOverlay(file)) {
// Clear the cached errors in the the notification manager so we don't
// Clear the cached errors in the notification manager so we don't
// re-send stale results if a plugin sends an update and we merge it with
// previous results.
analysisServer.notificationManager.errors.clearResultsForFile(file);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ class PercentileCalculator {
/// Return a map that can be encoded as JSON that represents the state of this
/// calculator.
Map<String, Object> toJson() {
// It's important the the encoded form of the list of percentile values be
// It's important that the encoded form of the list of percentile values be
// less than 100 characters long.
return {
'count': _valueCount,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -847,7 +847,7 @@ CompileTimeErrorCode.INCONSISTENT_LANGUAGE_VERSION_OVERRIDE:
CompileTimeErrorCode.INCONSISTENT_PATTERN_VARIABLE_LOGICAL_OR:
status: noFix
notes: |-
We cannot figure out the the user's intent here, and so cannot generate a
We cannot figure out the user's intent here, and so cannot generate a
fix that would be right.
CompileTimeErrorCode.INITIALIZER_FOR_NON_EXISTENT_FIELD:
status: needsFix
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -246,8 +246,8 @@ class PubspecFixGenerator {
? prevEntry.value.span.end.offset
: (currentEntry.key as YamlNode).span.start.offset;
// If nextEntry is null, this is the last entry in the
// dev_dependencies section, and also dev_dependencies is the the
// last section in the pubspec file. So delete till the end of the
// dev_dependencies section, and also dev_dependencies is the last
// section in the pubspec file. So delete till the end of the
// section.
var endOffset =
nextEntry == null
Expand Down
2 changes: 1 addition & 1 deletion pkg/analysis_server/tool/lsp_spec/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ Direction: Client -> Server
Params: `{ uri: Uri }`
Returns: `{ content: string | undefined }`

Returns the content of the the virtual document with `uri`. This is intended for generated files (such as those generated by macros) and is not supported for 'file' URIs.
Returns the content of the virtual document with `uri`. This is intended for generated files (such as those generated by macros) and is not supported for 'file' URIs.

### dart/textDocumentContentDidChange Notification

Expand Down
2 changes: 1 addition & 1 deletion pkg/dart2wasm/lib/param_info.dart
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class ParameterInfo {
final List<Constant?> positional;

/// Default values of named parameters. Similar to [positional], `null` means
/// the the parameter is not optional.
/// the parameter is not optional.
final Map<String, Constant?> named;

final bool takesContextOrReceiver;
Expand Down
2 changes: 1 addition & 1 deletion pkg/dartdev/lib/src/commands/compile.dart
Original file line number Diff line number Diff line change
Expand Up @@ -871,7 +871,7 @@ class CompileWasmCommand extends CompileSubcommandCommand {
flags.removeWhere((option) => option == '--no-$name');
flags.removeWhere((option) => option == '--$name');

// Explicitly use the the flag value, irrespective of -O settings.
// Explicitly use the flag value, irrespective of -O settings.
value ? flags.add('--$name') : flags.add('--no-$name');
}

Expand Down
2 changes: 1 addition & 1 deletion pkg/dartdev/lib/src/resident_frontend_utils.dart
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ Future<bool> isFileAppJitSnapshot(final File file) async {
}

Future<bool> isFileAotSnapshot(final File file) async {
// Check for any of the the magic numbers that can be found at the start of an
// Check for any of the magic numbers that can be found at the start of an
// AOT snapshot.

final bytes = await file.openRead(0, 4).expand((i) => i).toList();
Expand Down
10 changes: 5 additions & 5 deletions pkg/dds/lib/src/dap_handler.dart
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,10 @@ class DapHandler {
final message = parameters['message'].asString;

// TODO(dantup): If/when DAP needs to care about ordering (eg. it handles
// both requests and events), this will need to be changed to have the
// caller provide a "responseWriter" function so the the result can be
// written directly to the stream synchronously, to avoid future events
// being able to be inserted before the response (eg. initializedEvent).
// both requests and events), this will need to be changed to have the
// caller provide a "responseWriter" function so the result can be written
// directly to the stream synchronously, to avoid future events being able
// to be inserted before the response (eg. initializedEvent).
final responseCompleter = Completer<Response>();
adapter.handleMessage(message, responseCompleter.complete);
final result = await responseCompleter.future;
Expand Down Expand Up @@ -70,7 +70,7 @@ class DapHandler {
// Each DAP request has a `seq` number (essentially a message ID) which
// should be unique.
//
// We send a few requsets to initialize the adapter, but these are not
// We send a few requests to initialize the adapter, but these are not
// visible to the DDS client so if we start at 1, the IDs will be
// reused.
//
Expand Down
2 changes: 1 addition & 1 deletion pkg/dtd_impl/dtd_protocol.md
Original file line number Diff line number Diff line change
Expand Up @@ -661,7 +661,7 @@ If _uri_ does not have a 'file' scheme, the 143 (File scheme expected on uri)

### IDE Workspace Roots

The IDE workspace roots are used to ensure the the `FileSystem` service methods
The IDE workspace roots are used to ensure the `FileSystem` service methods
do not perform file operations in areas outside of the IDE workspace roots.

When the Dart Tooling Daemon is started, a secret is generated and presented to
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# 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.

# If changing the the entry and marking the previous entry as changed but where
# If changing the entry and marking the previous entry as changed but where
# the previous entry is no longer used (and reference another library only that
# one uses) we have come into a situation where we'll keep something we
# shouldn't, which (on top of being bad in itself) can lead to problems if we
Expand Down
2 changes: 1 addition & 1 deletion pkg/front_end/tool/benchmarker.dart
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ void main(List<String> args) {
}

if (warnings.scalingInEffect) {
print("Be aware the the above was with scaling in effect.");
print("Be aware that the above was with scaling in effect.");
print("As such the results are likely useless.");
print("Possibly some other process is using the hardware counters.");
print("Running this tool");
Expand Down
4 changes: 2 additions & 2 deletions pkg/linter/messages.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -286,7 +286,7 @@ LintCode:
const int quux = 20;
```
NOTE: Using the the `@optionalTypeArgs` annotation in the `meta` package, API
NOTE: Using the `@optionalTypeArgs` annotation in the `meta` package, API
authors can special-case type parameters whose type needs to be dynamic but whose
declaration should be treated as optional. For example, suppose you have a
`Key` object whose type parameter you'd like to treat as optional. Using the
Expand Down Expand Up @@ -4692,7 +4692,7 @@ LintCode:
it's possible, or open an issue asking the package authors to make it part
of the public API.
deprecatedDetails: |-
From the the [pub package layout doc](https://dart.dev/tools/pub/package-layout#implementation-files):
From the [pub package layout doc](https://dart.dev/tools/pub/package-layout#implementation-files):
**DON'T** import implementation files from another package.
Expand Down
6 changes: 3 additions & 3 deletions pkg/linter/tool/machine/rules.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@
],
"sets": [],
"fixStatus": "hasFix",
"details": "From the [style guide for the flutter repo](https://flutter.dev/style-guide/):\n\n**DO** specify type annotations.\n\nAvoid `var` when specifying that a type is unknown and short-hands that elide\ntype annotations. Use `dynamic` if you are being explicit that the type is\nunknown. Use `Object` if you are being explicit that you want an object that\nimplements `==` and `hashCode`.\n\n**BAD:**\n```dart\nvar foo = 10;\nfinal bar = Bar();\nconst quux = 20;\n```\n\n**GOOD:**\n```dart\nint foo = 10;\nfinal Bar bar = Bar();\nString baz = 'hello';\nconst int quux = 20;\n```\n\nNOTE: Using the the `@optionalTypeArgs` annotation in the `meta` package, API\nauthors can special-case type parameters whose type needs to be dynamic but whose\ndeclaration should be treated as optional. For example, suppose you have a\n`Key` object whose type parameter you'd like to treat as optional. Using the\n`@optionalTypeArgs` would look like this:\n\n```dart\nimport 'package:meta/meta.dart';\n\n@optionalTypeArgs\nclass Key<T> {\n ...\n}\n\nvoid main() {\n Key s = Key(); // OK!\n}\n```",
"details": "From the [style guide for the flutter repo](https://flutter.dev/style-guide/):\n\n**DO** specify type annotations.\n\nAvoid `var` when specifying that a type is unknown and short-hands that elide\ntype annotations. Use `dynamic` if you are being explicit that the type is\nunknown. Use `Object` if you are being explicit that you want an object that\nimplements `==` and `hashCode`.\n\n**BAD:**\n```dart\nvar foo = 10;\nfinal bar = Bar();\nconst quux = 20;\n```\n\n**GOOD:**\n```dart\nint foo = 10;\nfinal Bar bar = Bar();\nString baz = 'hello';\nconst int quux = 20;\n```\n\nNOTE: Using the `@optionalTypeArgs` annotation in the `meta` package, API\nauthors can special-case type parameters whose type needs to be dynamic but whose\ndeclaration should be treated as optional. For example, suppose you have a\n`Key` object whose type parameter you'd like to treat as optional. Using the\n`@optionalTypeArgs` would look like this:\n\n```dart\nimport 'package:meta/meta.dart';\n\n@optionalTypeArgs\nclass Key<T> {\n ...\n}\n\nvoid main() {\n Key s = Key(); // OK!\n}\n```",
"sinceDartSdk": "2.0"
},
{
Expand Down Expand Up @@ -1117,7 +1117,7 @@
"incompatible": [],
"sets": [],
"fixStatus": "noFix",
"details": "From the the [pub package layout doc](https://dart.dev/tools/pub/package-layout#implementation-files):\n\n**DON'T** import implementation files from another package.\n\nThe libraries inside `lib` are publicly visible: other packages are free to\nimport them. But much of a package's code is internal implementation libraries\nthat should only be imported and used by the package itself. Those go inside a\nsubdirectory of `lib` called `src`. You can create subdirectories in there if\nit helps you organize things.\n\nYou are free to import libraries that live in `lib/src` from within other Dart\ncode in the same package (like other libraries in `lib`, scripts in `bin`,\nand tests) but you should never import from another package's `lib/src`\ndirectory. Those files are not part of the package's public API, and they\nmight change in ways that could break your code.\n\n**BAD:**\n```dart\n// In 'road_runner'\nimport 'package:acme/src/internals.dart';\n```",
"details": "From the [pub package layout doc](https://dart.dev/tools/pub/package-layout#implementation-files):\n\n**DON'T** import implementation files from another package.\n\nThe libraries inside `lib` are publicly visible: other packages are free to\nimport them. But much of a package's code is internal implementation libraries\nthat should only be imported and used by the package itself. Those go inside a\nsubdirectory of `lib` called `src`. You can create subdirectories in there if\nit helps you organize things.\n\nYou are free to import libraries that live in `lib/src` from within other Dart\ncode in the same package (like other libraries in `lib`, scripts in `bin`,\nand tests) but you should never import from another package's `lib/src`\ndirectory. Those files are not part of the package's public API, and they\nmight change in ways that could break your code.\n\n**BAD:**\n```dart\n// In 'road_runner'\nimport 'package:acme/src/internals.dart';\n```",
"sinceDartSdk": "2.0"
},
{
Expand Down Expand Up @@ -3263,4 +3263,4 @@
"details": "**DON'T** assign to `void`.\n\n**BAD:**\n```dart\nclass A<T> {\n T value;\n void test(T arg) { }\n}\n\nvoid main() {\n A<void> a = A<void>();\n a.value = 1; // LINT\n a.test(1); // LINT\n}\n```",
"sinceDartSdk": "2.0"
}
]
]
2 changes: 1 addition & 1 deletion pkg/vm_service/example/vm_service_tester.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// 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.

/// An example of using the the libraries provided by `package:vm_service`.
/// An example of using the libraries provided by `package:vm_service`.
library;

import 'dart:async';
Expand Down
2 changes: 1 addition & 1 deletion runtime/docs/contributing_to_dart_ffi.md
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ Running the CFE on a Dart file can be done with the following configuration.
You can read more about kernel format in the [VM readme](https://github.com/dart-lang/sdk/blob/main/runtime/docs/README.md).


# Contributing to the the Dart FFI implementation in the VM
# Contributing to the Dart FFI implementation in the VM

In order to be able to work on the VM implementation of Dart FFI, you first need to familiarize yourself with the Dart VM:

Expand Down
2 changes: 1 addition & 1 deletion sdk/lib/_internal/js_dev_runtime/private/js_helper.dart
Original file line number Diff line number Diff line change
Expand Up @@ -973,7 +973,7 @@ rti.Rti getRtiForRecord(Object? record) {
///
/// Care needs to taken to ensure that the runtime does not get caught telling
/// lies. Generally, a class's `runtimeType` lies by returning an abstract
/// supertype of the class. Since both the the marker interface and `get
/// supertype of the class. Since both the marker interface and `get
/// runtimeType` are inherited, there should be no way in which a user can
/// extend the class or implement interface of the class.
// TODO(48585): Move this class back to the dart:_rti library when old DDC
Expand Down
2 changes: 1 addition & 1 deletion sdk/lib/_internal/js_runtime/lib/js_helper.dart
Original file line number Diff line number Diff line change
Expand Up @@ -3564,7 +3564,7 @@ void Function(T)? wrapZoneUnaryCallback<T>(void Function(T)? callback) {
///
/// Care needs to taken to ensure that the runtime does not get caught telling
/// lies. Generally, a class's `runtimeType` lies by returning an abstract
/// supertype of the class. Since both the the marker interface and `get
/// supertype of the class. Since both the marker interface and `get
/// runtimeType` are inherited, there should be no way in which a user can
/// extend the class or implement interface of the class.
// TODO(48585): Move this class back to the dart:_rti library when old DDC
Expand Down
2 changes: 1 addition & 1 deletion sdk/lib/developer/developer.dart
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
/// final someInterestingValue = 1000;
/// while (true) {
/// if (counter == someInterestingValue) {
/// // Trigger a breakpoint in the the debugger.
/// // Trigger a breakpoint in the debugger.
/// debugger();
/// }
/// counter++;
Expand Down
2 changes: 1 addition & 1 deletion tests/lib/js/static_interop_test/js_array_impl_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -472,7 +472,7 @@ void main() {
runAllTests();
}

// Will swap the first and last items in a list, while leaving the the middle
// Will swap the first and last items in a list, while leaving the middle
// elements in place because they will be swapped and then swapped back as
// shuffle iterates through the list.
class MockRandom implements Random {
Expand Down
2 changes: 1 addition & 1 deletion tests/lib/js/static_interop_test/js_types_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ void syncTests() {
dartArr = arr.toDart;
dartArrN = arrN.toDart;
if (isJSBackend) {
// A cast-list should not be introduced if the the array is already the
// A cast-list should not be introduced if the array is already the
// right list type.
expect(dartArr, listN);
expect(dartArrN, listN);
Expand Down

0 comments on commit 9b7bb9d

Please sign in to comment.