diff --git a/common/hashing.h b/common/hashing.h index 368937972d08..450084583e94 100644 --- a/common/hashing.h +++ b/common/hashing.h @@ -375,7 +375,7 @@ class Hasher { // which will generate 8 64-bit values and one more digit. The `bc` command's // decimal based scaling means that without getting at least some extra hex // digits rendered there will be rounding that we don't want so the script - // below goes on to produce one more hex digit ensuring the the 8 initializers + // below goes on to produce one more hex digit ensuring the 8 initializers // aren't rounded in any way. Using a higher scale won't cause the 8 // initializers here to change further. // diff --git a/docs/design/generics/details.md b/docs/design/generics/details.md index 67f5dc411559..a04e0ab44113 100644 --- a/docs/design/generics/details.md +++ b/docs/design/generics/details.md @@ -4560,7 +4560,7 @@ declarations are selected. impl and `Z(i16)` for `i8` using the second. In this case, `(i8 as Z(i16)).Cond == Y`. -There is no reason to to prefer one of these outcomes over the other. +There is no reason to prefer one of these outcomes over the other. **Example:** Further, cycles can create contradictions in the type system: diff --git a/explorer/ast/pattern.h b/explorer/ast/pattern.h index e7d5d1bd2c13..a81b1f919ecc 100644 --- a/explorer/ast/pattern.h +++ b/explorer/ast/pattern.h @@ -115,7 +115,7 @@ auto VisitNestedPatterns(const Pattern& pattern, inline auto VisitNestedPatterns(Pattern& pattern, llvm::function_ref visitor) -> bool { - // The non-const version is is implemented in terms of the const version. The + // The non-const version is implemented in terms of the const version. The // const_cast is safe because every pattern reachable through a non-const // pattern is also non-const. const Pattern& const_pattern = pattern; diff --git a/explorer/base/trace_stream.h b/explorer/base/trace_stream.h index 6830c814f889..0ed9f45ea885 100644 --- a/explorer/base/trace_stream.h +++ b/explorer/base/trace_stream.h @@ -39,7 +39,7 @@ enum class ProgramPhase { // Encapsulates the trace stream so that we can cleanly disable tracing while // the prelude is being processed. The prelude is expected to take a -// disproprotionate amount of time to log, so we try to avoid it. +// disproportionate amount of time to log, so we try to avoid it. class TraceStream { public: explicit TraceStream() = default; diff --git a/proposals/p0339.md b/proposals/p0339.md index a3d7f12ff831..71a1ff77e93d 100644 --- a/proposals/p0339.md +++ b/proposals/p0339.md @@ -292,7 +292,7 @@ In the first statement, `*` is a unary operator and so `T*` is the type and `x` is the identifier. However, in the second statement, `*` is a binary operator and so `T * x = 3` is the type, and `y` is the identifier; the resulting compiler errors may be confusing to users. Furthermore, the place of `3` could -be taken by an an arbitrarily complex expression; this could cause resolving the +be taken by an arbitrarily complex expression; this could cause resolving the ambiguity between unary and binary `*` to require unbounded look-ahead, adversely impacting [code compilation time goals](/docs/project/goals.md#fast-and-scalable-development). diff --git a/proposals/p2760.md b/proposals/p2760.md index fa45337fb630..379b37dbdbf6 100644 --- a/proposals/p2760.md +++ b/proposals/p2760.md @@ -240,7 +240,7 @@ member for This makes the part of a class definition that is used in forward declarations be exactly the part before the curly braces (`{`...`}`). Before this proposal, -class forward declarations would exclude the `extends` clause from the the first +class forward declarations would exclude the `extends` clause from the first line of the class definition. This change makes classes consistent with other entities that may be forward declared. diff --git a/toolchain/lex/tokenized_buffer.cpp b/toolchain/lex/tokenized_buffer.cpp index afff149da592..b6227653b0f2 100644 --- a/toolchain/lex/tokenized_buffer.cpp +++ b/toolchain/lex/tokenized_buffer.cpp @@ -198,7 +198,7 @@ auto TokenizedBuffer::PrintWidths::Widen(const PrintWidths& widths) -> void { } // Compute the printed width of a number. When numbers are printed in decimal, -// the number of digits needed is is one more than the log-base-10 of the +// the number of digits needed is one more than the log-base-10 of the // value. We handle a value of `zero` explicitly. // // This routine requires its argument to be *non-negative*. diff --git a/toolchain/parse/handle_expr.cpp b/toolchain/parse/handle_expr.cpp index 9680a51d4fff..28bb235e6048 100644 --- a/toolchain/parse/handle_expr.cpp +++ b/toolchain/parse/handle_expr.cpp @@ -313,7 +313,7 @@ auto HandleExprLoop(Context& context) -> void { } } -// Adds the operator node and returns the the main expression loop. +// Adds the operator node and returns the main expression loop. static auto HandleExprLoopForOperator(Context& context, Context::StateStackEntry state, NodeKind node_kind) -> void {