Spelling pkg analyzer lib

Closes https://github.com/dart-lang/sdk/pull/50860

GitOrigin-RevId: b27066c37f93c8c6d1123d6ebd6a4c0afcf59844
Change-Id: I15fa4aea1dad45daf168e34d1c4450320ec9b40a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/277742
Commit-Queue: Alexander Thomas <athom@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
This commit is contained in:
Josh Soref 2023-01-25 14:08:27 +00:00 committed by Commit Queue
parent cb6e9fdf11
commit ef42a0b110
57 changed files with 87 additions and 87 deletions

View file

@ -7478,7 +7478,7 @@ Patch release, resolves three issues:
- A stack overflow caused by a transformer being run multiple times on the
package that defines it has been fixed.
- A transformer that tries to read a non-existent asset in another package
- A transformer that tries to read a nonexistent asset in another package
will now be re-run if that asset is later created.
[package spec proposal]: https://github.com/lrhn/dep-pkgspec

View file

@ -138,7 +138,7 @@ version of the version reported by tools in that SDK.** This means that:
Internally in the Dart SDK repo, the source of truth for the SDK version number
is `tools/VERSION`. That file gets updated during the release process when
various branches are cut and releases shipped. We could calculate the language
version from that using the above rule, but we're worried that that means the
version from that using the above rule, but we're worried that means the
language version could change inadvertently as a consequence of release
administrivia. Instead, the repo stores the language version explicitly in
`tools/experimental_features.yaml`.

View file

@ -175,7 +175,7 @@ class ContextBuilderImpl implements ContextBuilder {
}
}
/// Return the SDK that that should be used to analyze code.
/// Return the SDK that should be used to analyze code.
DartSdk _createSdk({
required Workspace workspace,
String? sdkPath,

View file

@ -1722,7 +1722,7 @@ class NodeLocator extends UnifyingAstVisitor<void> {
@override
void visitConstructorDeclaration(ConstructorDeclaration node) {
// Names do not have AstNodes but offsets at the end should be treated as
// part of the decleration (not parameter list).
// part of the declaration (not parameter list).
if (_startOffset == _endOffset &&
_startOffset == (node.name ?? node.returnType).end) {
_foundNode = node;
@ -1735,7 +1735,7 @@ class NodeLocator extends UnifyingAstVisitor<void> {
@override
void visitFunctionDeclaration(FunctionDeclaration node) {
// Names do not have AstNodes but offsets at the end should be treated as
// part of the decleration (not parameter list).
// part of the declaration (not parameter list).
if (_startOffset == _endOffset && _startOffset == node.name.end) {
_foundNode = node;
return;
@ -1747,7 +1747,7 @@ class NodeLocator extends UnifyingAstVisitor<void> {
@override
void visitMethodDeclaration(MethodDeclaration node) {
// Names do not have AstNodes but offsets at the end should be treated as
// part of the decleration (not parameter list).
// part of the declaration (not parameter list).
if (_startOffset == _endOffset && _startOffset == node.name.end) {
_foundNode = node;
return;
@ -1852,7 +1852,7 @@ class NodeLocator2 extends UnifyingAstVisitor<void> {
@override
void visitConstructorDeclaration(ConstructorDeclaration node) {
// Names do not have AstNodes but offsets at the end should be treated as
// part of the decleration (not parameter list).
// part of the declaration (not parameter list).
if (_startOffset == _endOffset &&
_startOffset == (node.name ?? node.returnType).end) {
_foundNode = node;
@ -1865,7 +1865,7 @@ class NodeLocator2 extends UnifyingAstVisitor<void> {
@override
void visitFunctionDeclaration(FunctionDeclaration node) {
// Names do not have AstNodes but offsets at the end should be treated as
// part of the decleration (not parameter list).
// part of the declaration (not parameter list).
if (_startOffset == _endOffset && _startOffset == node.name.end) {
_foundNode = node;
return;
@ -1877,7 +1877,7 @@ class NodeLocator2 extends UnifyingAstVisitor<void> {
@override
void visitMethodDeclaration(MethodDeclaration node) {
// Names do not have AstNodes but offsets at the end should be treated as
// part of the decleration (not parameter list).
// part of the declaration (not parameter list).
if (_startOffset == _endOffset && _startOffset == node.name.end) {
_foundNode = node;
return;

View file

@ -409,7 +409,7 @@ abstract class AbstractClassElementImpl extends _ExistingElementImpl
}
/// Return an iterable containing all of the implementations of a getter with
/// the given [getterName] that are defined in this class any any superclass
/// the given [getterName] that are defined in this class and any superclass
/// of this class (but not in interfaces).
///
/// The getters that are returned are not filtered in any way. In particular,
@ -439,7 +439,7 @@ abstract class AbstractClassElementImpl extends _ExistingElementImpl
}
/// Return an iterable containing all of the implementations of a method with
/// the given [methodName] that are defined in this class any any superclass
/// the given [methodName] that are defined in this class and any superclass
/// of this class (but not in interfaces).
///
/// The methods that are returned are not filtered in any way. In particular,
@ -468,7 +468,7 @@ abstract class AbstractClassElementImpl extends _ExistingElementImpl
}
/// Return an iterable containing all of the implementations of a setter with
/// the given [setterName] that are defined in this class any any superclass
/// the given [setterName] that are defined in this class and any superclass
/// of this class (but not in interfaces).
///
/// The setters that are returned are not filtered in any way. In particular,
@ -4829,7 +4829,7 @@ class MixinElementImpl extends ClassOrMixinElementImpl implements MixinElement {
@override
set supertype(InterfaceType? supertype) {
throw StateError('Attempt to set a supertype for a mixin declaratio.');
throw StateError('Attempt to set a supertype for a mixin declaration.');
}
@override

View file

@ -459,21 +459,21 @@ class GenericInferrer {
}
// Only report unique constraint origins.
Iterable<_TypeConstraint> isSatisified(bool expected) => constraintsByOrigin
Iterable<_TypeConstraint> isSatisfied(bool expected) => constraintsByOrigin
.values
.where((l) =>
l.every((c) => c.isSatisfiedBy(_typeSystem, inferred)) == expected)
.expand((i) => i);
String unsatisified = _formatConstraints(isSatisified(false));
String satisified = _formatConstraints(isSatisified(true));
String unsatisfied = _formatConstraints(isSatisfied(false));
String satisfied = _formatConstraints(isSatisfied(true));
assert(unsatisified.isNotEmpty);
if (satisified.isNotEmpty) {
satisified = "\nThe type '$inferredStr' was inferred from:\n$satisified";
assert(unsatisfied.isNotEmpty);
if (satisfied.isNotEmpty) {
satisfied = "\nThe type '$inferredStr' was inferred from:\n$satisfied";
}
return '\n\n$intro\n$unsatisified$satisified\n\n'
return '\n\n$intro\n$unsatisfied$satisfied\n\n'
'Consider passing explicit type argument(s) to the generic.\n\n';
}

View file

@ -1409,7 +1409,7 @@ class TypeSystemImpl implements TypeSystem {
}
}
/// Given two lists of type parameters, check that that they have the same
/// Given two lists of type parameters, check that they have the same
/// number of elements, and their bounds are equal.
///
/// The return value will be a new list of fresh type parameters, that can

View file

@ -188,7 +188,7 @@ class HintCode extends AnalyzerErrorCode {
"directory.",
);
/// It is a bad practice for a source file ouside a package "lib" directory
/// It is a bad practice for a source file outside a package "lib" directory
/// hierarchy to traverse into that directory hierarchy. For example, a source
/// file in the "web" directory should not contain a directive such as
/// `import '../lib/some.dart'` which references a file inside the lib

View file

@ -5028,7 +5028,7 @@ class CompileTimeErrorCode extends AnalyzerErrorCode {
);
/// Parameters:
/// 0: the URI pointing to a non-existent file
/// 0: the URI pointing to a nonexistent file
static const CompileTimeErrorCode URI_DOES_NOT_EXIST = CompileTimeErrorCode(
'URI_DOES_NOT_EXIST',
"Target of URI doesn't exist: '{0}'.",
@ -5039,7 +5039,7 @@ class CompileTimeErrorCode extends AnalyzerErrorCode {
);
/// Parameters:
/// 0: the URI pointing to a non-existent file
/// 0: the URI pointing to a nonexistent file
static const CompileTimeErrorCode URI_HAS_NOT_BEEN_GENERATED =
CompileTimeErrorCode(
'URI_HAS_NOT_BEEN_GENERATED',

View file

@ -67,7 +67,7 @@ class DeadCodeVerifier extends RecursiveAstVisitor<void> {
final importElement = node.element;
if (importElement != null) {
// The element is null when the URI is invalid, but not when the URI is
// valid but refers to a non-existent file.
// valid but refers to a nonexistent file.
LibraryElement? library = importElement.importedLibrary;
if (library != null && !library.isSynthetic) {
for (Combinator combinator in node.combinators) {

View file

@ -129,7 +129,7 @@ class NonExistingSource extends Source {
///
/// If the instances that implement this API are the system of record, then they
/// will typically be unique. In that case, sources that are created that
/// represent non-existent files must also be retained so that if those files
/// represent nonexistent files must also be retained so that if those files
/// are created at a later date the long-lived sources representing those files
/// will know that they now exist.
abstract class Source {

View file

@ -19,7 +19,7 @@ class TopLevelDeclarations {
return analysisContext as DriverBasedAnalysisContext;
}
/// Return the first public library that that exports (but does not necessary
/// Return the first public library that exports (but does not necessary
/// declare) [element].
Future<LibraryElement?> publiclyExporting(Element element,
{Map<Element, LibraryElement?>? resultCache}) async {

View file

@ -15262,7 +15262,7 @@ CompileTimeErrorCode:
hasPublishedDocs: true
comment: |-
Parameters:
0: the URI pointing to a non-existent file
0: the URI pointing to a nonexistent file
documentation: |-
#### Description
@ -15289,7 +15289,7 @@ CompileTimeErrorCode:
hasPublishedDocs: true
comment: |-
Parameters:
0: the URI pointing to a non-existent file
0: the URI pointing to a nonexistent file
documentation: |-
#### Description
@ -18145,7 +18145,7 @@ HintCode:
problemMessage: "A file outside the 'lib' directory shouldn't reference a file inside the 'lib' directory using a relative path."
correctionMessage: "Try using a 'package:' URI instead."
comment: |-
It is a bad practice for a source file ouside a package "lib" directory
It is a bad practice for a source file outside a package "lib" directory
hierarchy to traverse into that directory hierarchy. For example, a source
file in the "web" directory should not contain a directive such as
`import '../lib/some.dart'` which references a file inside the lib

View file

@ -261,7 +261,7 @@ import 'field_initializing_formal_not_assignable_test.dart'
as field_initializing_formal_not_assignable;
import 'field_must_be_external_in_struct_test.dart'
as field_must_be_external_in_struct;
import 'final_initialized_in_delcaration_and_constructor_test.dart'
import 'final_initialized_in_declaration_and_constructor_test.dart'
as final_initialized_in_declaration_and_constructor;
import 'final_not_initialized_constructor_test.dart'
as final_not_initialized_constructor;

View file

@ -38,8 +38,8 @@ class WrongNumberOfParametersForOperatorTest extends PubPackageResolutionTest {
test_compound_assignment_ok_in_legacy_code() async {
// Prior to the fix for https://github.com/dart-lang/sdk/issues/46569,
// attempting to use a binary operator with no args as part of a compound
// assignment would crash the analyzer. Check that that doesn't happen
// anymore.
// assignment would crash the analyzer. Check that the crash no longer
// occurs.
noSoundNullSafety = false;
await assertErrorsInCode('''
// @dart=2.9

View file

@ -321,7 +321,7 @@ class NativeBasicData {
}
/// Returns `true` if [element] or any of its superclasses is native. Supports
/// nullable element for checks on non-existent enclosing class of top-level
/// nullable element for checks on nonexistent enclosing class of top-level
/// functions.
bool isNativeOrExtendsNative(ClassEntity? element) {
if (element == null) return false;

View file

@ -424,7 +424,7 @@ class JsBackendStrategy {
/// the serialized data.
///
/// The needed members include members computed on demand during non-modular
/// code generation, such as constructor bodies and and generator bodies.
/// code generation, such as constructor bodies and generator bodies.
EntityWriter forEachCodegenMember(void Function(MemberEntity member) f) {
int earlyMemberIndexLimit = _elementMap.prepareForCodegenSerialization();
ClosedEntityWriter entityWriter = ClosedEntityWriter(earlyMemberIndexLimit);

View file

@ -69,7 +69,7 @@ Future runTests(Process process) {
process.stdin.writeln('--no-sound-null-safety --out="$outFile" "$inFile"');
process.stdin.writeln('--no-sound-null-safety --out="$outFile2" "$inFile"');
process.stdin.writeln('too many arguments');
process.stdin.writeln(r'"non existing file.dart"');
process.stdin.writeln(r'"nonexistent file.dart"');
process.stdin.close();
Future<String> output = process.stdout.transform(utf8.decoder).join();
Future<String> errorOut = process.stderr.transform(utf8.decoder).join();

View file

@ -98,7 +98,7 @@ Future<void> testDisabledSuperMixins() async {
}
/// Check that in an abstract class an error is reported only for a
/// super-invocation that targets an non-existent method, a super-invocation
/// super-invocation that targets an nonexistent method, a super-invocation
/// that targets an abstract member of the super-class should not be reported.
/// In non-abstract class we should report both cases as an error.
Future<void> testEnabledSuperMixins() async {

View file

@ -82,7 +82,7 @@ Future<void> throwOnInsufficientUriToSource(Component component,
if (uri == null) continue;
if (!uri.isScheme("org-dartlang-test")) continue;
// The file system doesn't have the sources for any modules.
// For now assume that that is always what's going on.
// For now assume that is always what's going on.
if (!await fileSystem.entityForUri(uri).exists()) continue;
List<int> expected = await fileSystem.entityForUri(uri).readAsBytes();
List<int> actual = component.uriToSource[uri]!.source;

View file

@ -3,7 +3,7 @@
# BSD-style license that can be found in the LICENSE.md file.
main.dart.patch: |
// Test that that isolate support works
// Test that isolate support works
main(arguments) { print(
<<<< "Hello, Isolated World!"
'Hello, Isolated World!'

View file

@ -636,7 +636,7 @@ void main() async {
count += 1;
} else {
expect(count, 3);
// Third request is to 'compile' non-existent file, that should fail.
// Third request is to 'compile' nonexistent file, that should fail.
expect(result.errorsCount, greaterThan(0));
frontendServer.quit();
@ -1935,7 +1935,7 @@ void main(List<String> arguments, SendPort sendPort) {
expect(await starter(args), 0);
}, skip: 'https://github.com/dart-lang/sdk/issues/43959');
test('compile to JavaScript weak null safety then non-existent file',
test('compile to JavaScript weak null safety then nonexistent file',
() async {
var file = File('${tempDir.path}/foo.dart')..createSync();
file.writeAsStringSync("main() {\n}\n");
@ -1981,7 +1981,7 @@ void main(List<String> arguments, SendPort sendPort) {
frontendServer.compile('foo.bar');
} else {
expect(count, 2);
// Second request is to 'compile' non-existent file, that should fail.
// Second request is to 'compile' nonexistent file, that should fail.
expect(result.errorsCount, greaterThan(0));
frontendServer.quit();
}
@ -2565,7 +2565,7 @@ e() {
count += 1;
} else {
expect(count, 3);
// Fourth request is to 'compile' non-existent file, that should fail.
// Fourth request is to 'compile' nonexistent file, that should fail.
expect(result.errorsCount, greaterThan(0));
frontendServer.quit();

View file

@ -852,7 +852,7 @@ class TypeCheckingVisitor
}
assert(
result != null,
"Encountered RecordNameGet with non-existent name key: "
"Encountered RecordNameGet with nonexistent name key: "
"'${node.name}'.");
return result!;
}

View file

@ -136,7 +136,7 @@ void _attachDependencies(
final module = modules[name];
if (module == null) {
_invalidTest(
"declared dependencies for a non existing module named '$name'");
"declared dependencies for a nonexistent module named '$name'");
}
if (module.dependencies.isNotEmpty) {
_invalidTest("Module dependencies have already been declared on $name.");
@ -144,7 +144,7 @@ void _attachDependencies(
moduleDependencies.forEach((dependencyName) {
final moduleDependency = modules[dependencyName];
if (moduleDependency == null) {
_invalidTest("'$name' declares a dependency on a non existing module "
_invalidTest("'$name' declares a dependency on a nonexistent module "
"named '$dependencyName'");
}
module.dependencies.add(moduleDependency);

View file

@ -1,3 +1,3 @@
# This expectation file is generated by loader_test.dart
Invalid test: 'main' declares a dependency on a non existing module named 'foo'
Invalid test: 'main' declares a dependency on a nonexistent module named 'foo'

View file

@ -1,3 +1,3 @@
# This expectation file is generated by loader_test.dart
Invalid test: declared dependencies for a non existing module named 'foo'
Invalid test: declared dependencies for a nonexistent module named 'foo'

View file

@ -2201,7 +2201,7 @@ LayoutTests/fast/dom/HTMLLabelElement/click-label_t01: RuntimeError # Please tri
LayoutTests/fast/dom/HTMLLabelElement/form/test1_t01: RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/link-and-subresource-test_t01: Skip # Times out. Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/link-beforeload-recursive_t01: Skip # Times out. Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/link-onerror-stylesheet-with-existent-and-non-existent-import_t01: Pass, RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/link-onerror-stylesheet-with-existent-and-nonexistent-import_t01: Pass, RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/prefetch-onerror_t01: Skip # Times out. Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/prefetch-onload_t01: Skip # Times out. Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/prefetch_t01: Skip # Times out. Please triage this failure
@ -2221,7 +2221,7 @@ LayoutTests/fast/dom/HTMLScriptElement/remove-in-beforeload_t01: RuntimeError #
LayoutTests/fast/dom/HTMLScriptElement/remove-source_t01: RuntimeError # Issue 18128
LayoutTests/fast/dom/HTMLScriptElement/script-set-src_t01: Pass, RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLSelectElement/change-multiple-preserve-selection_t01: RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLStyleElement/style-onerror-with-existent-and-non-existent-import_t01: Pass, RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLStyleElement/style-onerror-with-existent-and-nonexistent-import_t01: Pass, RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLTableElement/cellpadding-attribute_t01: RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLTemplateElement/custom-element-wrapper-gc_t01: RuntimeError # Issue 18250
LayoutTests/fast/dom/HTMLTemplateElement/cycles-in-shadow_t01: RuntimeError # Please triage this failure
@ -4905,8 +4905,8 @@ LayoutTests/fast/dom/HTMLLabelElement/label-control_t01: RuntimeError # Please t
LayoutTests/fast/dom/HTMLLinkElement/link-and-subresource-test-nonexistent_t01: Skip # Times out. Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/link-and-subresource-test_t01: Skip # Times out. Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/link-beforeload-recursive_t01: Skip # Times out. Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/link-onerror-stylesheet-with-existent-and-non-existent-import_t01: RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/link-onerror-stylesheet-with-non-existent-import_t01: RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/link-onerror-stylesheet-with-existent-and-nonexistent-import_t01: RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/link-onerror-stylesheet-with-nonexistent-import_t01: RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/link-onerror_t01: RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/link-onload-before-page-load_t01: RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLLinkElement/link-onload-stylesheet-with-import_t01: RuntimeError # Please triage this failure
@ -4944,7 +4944,7 @@ LayoutTests/fast/dom/HTMLSelectElement/named-options_t01: RuntimeError # Please
LayoutTests/fast/dom/HTMLSelectElement/selected-index-preserved-when-option-text-changes_t01: RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLStyleElement/programmatically-add-style-with-onerror-handler_t01: Skip # Times out. Please triage this failure
LayoutTests/fast/dom/HTMLStyleElement/programmatically-add-style-with-onload-handler_t01: Skip # Times out. Please triage this failure
LayoutTests/fast/dom/HTMLStyleElement/style-onerror-with-existent-and-non-existent-import_t01: RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLStyleElement/style-onerror-with-existent-and-nonexistent-import_t01: RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLStyleElement/style-onerror_t01: RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLStyleElement/style-onload-before-page-load_t01: RuntimeError # Please triage this failure
LayoutTests/fast/dom/HTMLStyleElement/style-onload2_t01: RuntimeError # Please triage this failure

View file

@ -290,7 +290,7 @@ Set<String> _findAllRelativeImports(Path topLibrary) {
if (match == null) continue;
var relativePath = match.group(3)!;
// If a multitest deliberately imports a non-existent file, don't try to
// If a multitest deliberately imports a nonexistent file, don't try to
// include it.
if (relativePath.contains("nonexistent")) continue;

View file

@ -29,7 +29,7 @@ class InferredType {
// Each component may be null if that particular type argument was not
// inferred.
//
// Otherwise, a non-null type argument indicates that that particular type
// Otherwise, a non-null type argument indicates that particular type
// argument (in the runtime type) is always exactly a particular `DartType`.
final List<DartType?>? exactTypeArguments;

View file

@ -9,7 +9,7 @@ import 'common/test_helper.dart';
var tests = <VMTest>[
(VmService vm) async {
// Invoke a non-existent RPC.
// Invoke a nonexistent RPC.
try {
final res = await vm.callMethod('foo');
fail('Expected RPCError, got $res');

View file

@ -168,7 +168,7 @@ int RunAnalyzer(int argc, char** argv) {
const char* script_name = nullptr;
script_name = inputs.GetArgument(0);
// Dart_LoadELF will crash on nonexistant file non-gracefully
// Dart_LoadELF will crash on nonexistent file non-gracefully
// even though it should return `nullptr`.
File* const file = File::Open(/*namespc=*/nullptr, script_name, File::kRead);
if (file == nullptr) {

View file

@ -64,7 +64,7 @@ VM_UNIT_TEST_CASE(CircularLinkedList) {
list.Rotate();
EXPECT(list.head() == 1);
// Test: Remove non-existent element leaves list un-changed.
// Test: Remove nonexistent element leaves list un-changed.
list.Remove(4242);
EXPECT(list.head() == 1);
@ -75,7 +75,7 @@ VM_UNIT_TEST_CASE(CircularLinkedList) {
list.Remove(10);
EXPECT(!list.HasHead());
// Test: Remove non-existent element from empty list works.
// Test: Remove nonexistent element from empty list works.
list.Remove(4242);
}

View file

@ -257,7 +257,7 @@ class PriorityQueue {
//
// Deletion operations can be performed by replacing the minimum element
// (first entry) by the last entry (bottom right) and bubbling it down until
// the tree invariant is satisified again.
// the tree invariant is satisfied again.
Entry* min_heap_;
intptr_t min_heap_size_;
intptr_t size_;

View file

@ -395,7 +395,7 @@ bool FastFixedDtoa(double v,
buffer[*length] = '\0';
if ((*length) == 0) {
// The string is empty and the decimal_point thus has no importance. Mimic
// Gay's dtoa and and set it to -fractional_count.
// Gay's dtoa and set it to -fractional_count.
*decimal_point = -fractional_count;
}
return true;

View file

@ -3159,7 +3159,7 @@ class StoreOptimizer : public LivenessAnalysis {
// still load from all places.
live_in->CopyFrom(all_places);
} else {
// If we are oustide of try-catch block, instructions that "may
// If we are outside of try-catch block, instructions that "may
// throw" only "load from escaping places".
// If we are inside of try-catch block, instructions that "may
// throw" also "load from all places".

View file

@ -151,7 +151,7 @@ static intptr_t CountFinalizedSubclasses(Thread* thread, const Class& cls) {
Class& direct_subclass = Class::Handle(thread->zone());
for (intptr_t i = 0; i < cls_direct_subclasses.Length(); i++) {
direct_subclass ^= cls_direct_subclasses.At(i);
// Unfinalized classes are treated as non-existent for CHA purposes,
// Unfinalized classes are treated as nonexistent for CHA purposes,
// as that means that no instance of that class exists at runtime.
if (!direct_subclass.is_finalized()) {
continue;
@ -206,7 +206,7 @@ bool CHA::HasOverride(const Class& cls,
Class& direct_subclass = Class::Handle(thread_->zone());
for (intptr_t i = 0; i < cls_direct_subclasses.Length(); i++) {
direct_subclass ^= cls_direct_subclasses.At(i);
// Unfinalized classes are treated as non-existent for CHA purposes,
// Unfinalized classes are treated as nonexistent for CHA purposes,
// as that means that no instance of that class exists at runtime.
if (!direct_subclass.is_finalized()) {
continue;

View file

@ -190,7 +190,7 @@ class Heap {
static const char* GCTypeToString(GCType type);
static const char* GCReasonToString(GCReason reason);
// Associate a peer with an object. A non-existent peer is equal to NULL.
// Associate a peer with an object. A nonexistent peer is equal to NULL.
void SetPeer(ObjectPtr raw_obj, void* peer) {
SetWeakEntry(raw_obj, kPeers, reinterpret_cast<intptr_t>(peer));
}
@ -200,7 +200,7 @@ class Heap {
int64_t PeerCount() const;
#if !defined(HASH_IN_OBJECT_HEADER)
// Associate an identity hashCode with an object. An non-existent hashCode
// Associate an identity hashCode with an object. An nonexistent hashCode
// is equal to 0.
intptr_t SetHashIfNotSet(ObjectPtr raw_obj, intptr_t hash) {
return SetWeakEntryIfNonExistent(raw_obj, kIdentityHashes, hash);

View file

@ -2372,7 +2372,7 @@ static void UpdateBoundsCheck(intptr_t index, intptr_t* checked_up_to) {
// do the test for that character first. We do this in separate passes. The
// 'preloaded' argument indicates that we are doing such a 'pass'. If such a
// pass has been performed then subsequent passes will have true in
// first_element_checked to indicate that that character does not need to be
// first_element_checked to indicate that character does not need to be
// checked again.
//
// In addition to all this we are passed a Trace, which can

View file

@ -2146,7 +2146,7 @@ class _BigIntImpl implements BigInt {
resultDigits[resultUsed++] = 0;
}
// Negate y so we can later use _mulAdd instead of non-existent _mulSub.
// Negate y so we can later use _mulAdd instead of nonexistent _mulSub.
var nyDigits = Uint16List(yUsed + 2);
nyDigits[yUsed] = 1;
_absSub(nyDigits, yUsed + 1, yDigits, yUsed, nyDigits);

View file

@ -1999,7 +1999,7 @@ class _BigIntImpl implements BigInt {
resultDigits[resultUsed++] = 0;
}
// Negate y so we can later use _mulAdd instead of non-existent _mulSub.
// Negate y so we can later use _mulAdd instead of nonexistent _mulSub.
var nyDigits = new Uint16List(yUsed + 2);
nyDigits[yUsed] = 1;
_absSub(nyDigits, yUsed + 1, yDigits, yUsed, nyDigits);

View file

@ -1427,7 +1427,7 @@ class _BigIntImpl implements BigInt {
if (resultUsed.isOdd) {
resultDigits[resultUsed] = 0; // Leading zero for 64-bit processing.
}
// Negate y so we can later use _mulAdd instead of non-existent _mulSub.
// Negate y so we can later use _mulAdd instead of nonexistent _mulSub.
var nyDigits = _newDigits(yUsed + 2);
nyDigits[yUsed] = 1;
_absSub(nyDigits, yUsed + 1, yDigits, yUsed, nyDigits);

View file

@ -99,7 +99,7 @@ class Object {
/// mainly for debugging or logging.
external String toString();
/// Invoked when a non-existent method or property is accessed.
/// Invoked when a nonexistent method or property is accessed.
///
/// A dynamic member invocation can attempt to call a member which
/// doesn't exist on the receiving object. Example:

View file

@ -55,7 +55,7 @@ class DomName {
}
/**
* Metadata that specifies that that member is editable through generated
* Metadata that specifies that member is editable through generated
* files.
*/
class DocsEditable {

View file

@ -81,7 +81,7 @@ part of dart.io;
/// void main() async {
/// final myDir = Directory('dir');
/// var isThere = await myDir.exists();
/// print(isThere ? 'exists' : 'non-existent');
/// print(isThere ? 'exists' : 'nonexistent');
/// }
/// ```
///

View file

@ -216,7 +216,7 @@ FileStat: type $type
/// Here's the exists method in action:
/// ```dart
/// var isThere = await entity.exists();
/// print(isThere ? 'exists' : 'non-existent');
/// print(isThere ? 'exists' : 'nonexistent');
/// ```
///
/// ## Other resources

View file

@ -115,7 +115,7 @@ class _Evaluator {
final buildScope =
Message._fromJsonRpcRequest(_message.client!, buildScopeParams);
// Decode the JSON and and insert it into the map. The map key
// Decode the JSON and insert it into the map. The map key
// is the request Uri.
return _isolate.routeRequest(_service, buildScope);
}

View file

@ -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.
// Extreme values from int_modulo_arith_test. Test cases that that have
// Extreme values from int_modulo_arith_test. Test cases that have
// intermediate values that overflow the precision of 'int'.
import "package:expect/expect.dart";

View file

@ -4,7 +4,7 @@
// @dart = 2.9
// Extreme values from int_modulo_arith_test. Test cases that that have
// Extreme values from int_modulo_arith_test. Test cases that have
// intermediate values that overflow the precision of 'int'.
import "package:expect/expect.dart";

View file

@ -10,7 +10,7 @@ void main() {
Expect.equals('B._foo', D0().foo);
// When mixin application is in the same library as the declaration,
// private symbol from the mixin delaration `B._foo` overrides `A._foo`.
// private symbol from the mixin declaration `B._foo` overrides `A._foo`.
Expect.equals('B._foo', C()._foo);
Expect.equals('B._foo', D()._foo);
// Getter `foo` returns `B._foo` that is coming from the mixin declaration.

View file

@ -12,7 +12,7 @@ void main() {
Expect.equals('B._foo', D0().foo);
// When mixin application is in the same library as the declaration,
// private symbol from the mixin delaration `B._foo` overrides `A._foo`.
// private symbol from the mixin declaration `B._foo` overrides `A._foo`.
Expect.equals('B._foo', C()._foo);
Expect.equals('B._foo', D()._foo);
// Getter `foo` returns `B._foo` that is coming from the mixin declaration.

View file

@ -5,7 +5,7 @@
import "package:expect/expect.dart";
// Test error message with noSuchMethodError: non-existent names
// Test error message with noSuchMethodError: nonexistent names
// should result in a message that reports the missing method.
class Callable {

View file

@ -5,7 +5,7 @@
import "package:expect/expect.dart";
// Test error message with noSuchMethodError: non-existent names
// Test error message with noSuchMethodError: nonexistent names
// should result in a message that reports the missing method.
call_bar(x) => x.bar();

View file

@ -7,7 +7,7 @@
import "package:expect/expect.dart";
// Test error message with noSuchMethodError: non-existent names
// Test error message with noSuchMethodError: nonexistent names
// should result in a message that reports the missing method.
class Callable {

View file

@ -7,7 +7,7 @@
import "package:expect/expect.dart";
// Test error message with noSuchMethodError: non-existent names
// Test error message with noSuchMethodError: nonexistent names
// should result in a message that reports the missing method.
call_bar(x) => x.bar();

View file

@ -135,7 +135,7 @@ void testCreateInNonExistentDirectory() {
Directory temp = tempDir();
var file = new File("${temp.path}/nonExistentDirectory/newFile");
// Create in non-existent directory should throw exception.
// Create in nonexistent directory should throw exception.
Expect.throws(() => file.createSync(),
(e) => checkCreateInNonExistentFileSystemException(e));
@ -162,7 +162,7 @@ void testResolveSymbolicLinksOnNonExistentDirectory() {
Directory temp = tempDir();
var file = new File("${temp.path}/nonExistentDirectory");
// Full path non-existent directory should throw exception.
// Full path nonexistent directory should throw exception.
Expect.throws(() => file.resolveSymbolicLinksSync(),
(e) => checkResolveSymbolicLinksOnNonExistentFileSystemException(e));

View file

@ -137,7 +137,7 @@ void testCreateInNonExistentDirectory() {
Directory temp = tempDir();
var file = new File("${temp.path}/nonExistentDirectory/newFile");
// Create in non-existent directory should throw exception.
// Create in nonexistent directory should throw exception.
Expect.throws(() => file.createSync(),
(e) => checkCreateInNonExistentFileSystemException(e));
@ -164,7 +164,7 @@ void testResolveSymbolicLinksOnNonExistentDirectory() {
Directory temp = tempDir();
var file = new File("${temp.path}/nonExistentDirectory");
// Full path non-existent directory should throw exception.
// Full path nonexistent directory should throw exception.
Expect.throws(() => file.resolveSymbolicLinksSync(),
(e) => checkResolveSymbolicLinksOnNonExistentFileSystemException(e));