"innermost", "outermost", "leftmost", and "rightmost" don't need hyphens

These are all standard dictionary words and don't require hyphenation.
This commit is contained in:
Josh Triplett 2024-10-23 02:45:24 -07:00
parent 9abfcb4900
commit ecdc2441b6
19 changed files with 45 additions and 45 deletions

View File

@ -197,7 +197,7 @@ fn is_gcc_scalar_pair(&self) -> bool {
/// `[T]` becomes `T`, while `str` and `Trait` turn into `i8` - this
/// is useful for indexing slices, as `&[T]`'s data pointer is `T*`.
/// If the type is an unsized struct, the regular layout is generated,
/// with the inner-most trailing unsized field using the "minimal unit"
/// with the innermost trailing unsized field using the "minimal unit"
/// of that field's type - this is useful for taking the address of
/// that field and ensuring the struct has the right alignment.
fn gcc_type<'gcc>(&self, cx: &CodegenCx<'gcc, 'tcx>) -> Type<'gcc> {

View File

@ -191,7 +191,7 @@ fn is_llvm_scalar_pair(&self) -> bool {
/// `[T]` becomes `T`, while `str` and `Trait` turn into `i8` - this
/// is useful for indexing slices, as `&[T]`'s data pointer is `T*`.
/// If the type is an unsized struct, the regular layout is generated,
/// with the inner-most trailing unsized field using the "minimal unit"
/// with the innermost trailing unsized field using the "minimal unit"
/// of that field's type - this is useful for taking the address of
/// that field and ensuring the struct has the right alignment.
fn llvm_type<'a>(&self, cx: &CodegenCx<'a, 'tcx>) -> &'a Type {

View File

@ -888,7 +888,7 @@ pub fn new(tcx: TyCtxt<'_>, target_cpu: String) -> CrateInfo {
// below.
//
// In order to get this left-to-right dependency ordering, we use the reverse
// postorder of all crates putting the leaves at the right-most positions.
// postorder of all crates putting the leaves at the rightmost positions.
let mut compiler_builtins = None;
let mut used_crates: Vec<_> = tcx
.postorder_cnums(())

View File

@ -58,9 +58,9 @@ pub fn short(&self) -> bool {
struct Margin {
/// The available whitespace in the left that can be consumed when centering.
pub whitespace_left: usize,
/// The column of the beginning of left-most span.
/// The column of the beginning of leftmost span.
pub span_left: usize,
/// The column of the end of right-most span.
/// The column of the end of rightmost span.
pub span_right: usize,
/// The beginning of the line to be displayed.
pub computed_left: usize,
@ -128,7 +128,7 @@ fn compute(&mut self, max_line_len: usize) {
} else {
0
};
// We want to show as much as possible, max_line_len is the right-most boundary for the
// We want to show as much as possible, max_line_len is the rightmost boundary for the
// relevant code.
self.computed_right = max(max_line_len, self.computed_left);
@ -685,7 +685,7 @@ fn draw_line(
buffer.puts(line_offset, code_offset, "...", Style::LineNumber);
}
if margin.was_cut_right(line_len) {
// We have stripped some code after the right-most span end, make it clear we did so.
// We have stripped some code after the rightmost span end, make it clear we did so.
buffer.puts(line_offset, code_offset + taken - 3, "...", Style::LineNumber);
}
buffer.puts(line_offset, 0, &self.maybe_anonymized(line_index), Style::LineNumber);

View File

@ -25,7 +25,7 @@ expand_collapse_debuginfo_illegal =
illegal value for attribute #[collapse_debuginfo(no|external|yes)]
expand_count_repetition_misplaced =
`count` can not be placed inside the inner-most repetition
`count` can not be placed inside the innermost repetition
expand_crate_name_in_cfg_attr =
`crate_name` within an `#![cfg_attr]` attribute is forbidden

View File

@ -23,11 +23,11 @@ pub(crate) enum MetaVarExpr {
/// Ignore a meta-variable for repetition without expansion.
Ignore(Ident),
/// The index of the repetition at a particular depth, where 0 is the inner-most
/// The index of the repetition at a particular depth, where 0 is the innermost
/// repetition. The `usize` is the depth.
Index(usize),
/// The length of the repetition at a particular depth, where 0 is the inner-most
/// The length of the repetition at a particular depth, where 0 is the innermost
/// repetition. The `usize` is the depth.
Len(usize),
}

View File

@ -570,7 +570,7 @@ fn lockstep_iter_size(
}
}
/// Used solely by the `count` meta-variable expression, counts the outer-most repetitions at a
/// Used solely by the `count` meta-variable expression, counts the outermost repetitions at a
/// given optional nested depth.
///
/// For example, a macro parameter of `$( { $( $foo:ident ),* } )*` called with `{ a, b } { c }`:

View File

@ -2457,7 +2457,7 @@ fn truncate_capture_for_optimization(
) -> (Place<'_>, ty::UpvarCapture) {
let is_shared_ref = |ty: Ty<'_>| matches!(ty.kind(), ty::Ref(.., hir::Mutability::Not));
// Find the right-most deref (if any). All the projections that come after this
// Find the rightmost deref (if any). All the projections that come after this
// are fields or other "in-place pointer adjustments"; these refer therefore to
// data owned by whatever pointer is being dereferenced here.
let idx = place.projections.iter().rposition(|proj| ProjectionKind::Deref == proj.kind);

View File

@ -1048,8 +1048,8 @@ pub(crate) fn schedule_drop(
// | +------------|outer_scope cache|--+ |
// +------------------------------|middle_scope cache|------+
//
// Now, a new, inner-most scope is added along with a new drop into
// both inner-most and outer-most scopes:
// Now, a new, innermost scope is added along with a new drop into
// both innermost and outermost scopes:
//
// +------------------------------------------------------------+
// | +----------------------------------+ |
@ -1061,11 +1061,11 @@ pub(crate) fn schedule_drop(
// +----=----------------|invalid middle_scope cache|-----------+
//
// If, when adding `drop(new)` we do not invalidate the cached blocks for both
// outer_scope and middle_scope, then, when building drops for the inner (right-most)
// outer_scope and middle_scope, then, when building drops for the inner (rightmost)
// scope, the old, cached blocks, without `drop(new)` will get used, producing the
// wrong results.
//
// Note that this code iterates scopes from the inner-most to the outer-most,
// Note that this code iterates scopes from the innermost to the outermost,
// invalidating caches of each scope visited. This way bare minimum of the
// caches gets invalidated. i.e., if a new drop is added into the middle scope, the
// cache of outer scope stays intact.

View File

@ -1177,7 +1177,7 @@ struct PlaceInfo<'tcx> {
/// The projection used to go from parent to this node (only None for root).
proj_elem: Option<TrackElem>,
/// The left-most child.
/// The leftmost child.
first_child: Option<PlaceIndex>,
/// Index of the sibling to the right of this node.

View File

@ -85,7 +85,7 @@ pub(super) fn report_suspicious_mismatch_block(
}
}
// Find the inner-most span candidate for final report
// Find the innermost span candidate for final report
let candidate_span =
matched_spans.into_iter().rev().find(|&(_, same_ident)| !same_ident).map(|(span, _)| span);

View File

@ -79,7 +79,7 @@ pub fn bulk_push<I, A: Allocator + Clone>(&mut self, iter: I, length: &mut usize
}
open_node.push(key, value, right_tree);
// Go down to the right-most leaf again.
// Go down to the rightmost leaf again.
cur_node = open_node.forget_type().last_leaf_edge().into_node();
}

View File

@ -102,7 +102,7 @@ pub fn fix_left_border<A: Allocator + Clone>(&mut self, alloc: A) {
pub fn fix_right_border_of_plentiful(&mut self) {
let mut cur_node = self.borrow_mut();
while let Internal(internal) = cur_node.force() {
// Check if right-most child is underfull.
// Check if rightmost child is underfull.
let mut last_kv = internal.last_kv().consider_for_balancing();
debug_assert!(last_kv.left_child_len() >= MIN_LEN * 2);
let right_child_len = last_kv.right_child_len();

View File

@ -1521,7 +1521,7 @@ pub fn bulk_steal_left(&mut self, count: usize) {
right_node.val_area_mut(..count - 1),
);
// Move the left-most stolen pair to the parent.
// Move the leftmost stolen pair to the parent.
let k = left_node.key_area_mut(new_left_len).assume_init_read();
let v = left_node.val_area_mut(new_left_len).assume_init_read();
let (k, v) = self.parent.replace_kv(k, v);
@ -1570,7 +1570,7 @@ pub fn bulk_steal_right(&mut self, count: usize) {
// Move leaf data.
{
// Move the right-most stolen pair to the parent.
// Move the rightmost stolen pair to the parent.
let k = right_node.key_area_mut(count - 1).assume_init_read();
let v = right_node.val_area_mut(count - 1).assume_init_read();
let (k, v) = self.parent.replace_kv(k, v);

View File

@ -71,7 +71,7 @@
/// this can be useful for specializing [`FromIterator`] implementations or recovering the
/// remaining elements after an iterator has been partially exhausted.
///
/// Note that implementations do not necessarily have to provide access to the inner-most
/// Note that implementations do not necessarily have to provide access to the innermost
/// source of a pipeline. A stateful intermediate adapter might eagerly evaluate a part
/// of the pipeline and expose its internal storage as source.
///

View File

@ -1208,7 +1208,7 @@ The compiler has some latitude in how an entity is encoded as long as the symbol
* Named functions, methods, and statics shall be represented by a *[path]* production.
* Paths should be rooted at the inner-most entity that can act as a path root.
* Paths should be rooted at the innermost entity that can act as a path root.
Roots can be crate-ids, inherent impls, trait impls, and (for items within default methods) trait definitions.
* The compiler is free to choose disambiguation indices and namespace tags from

View File

@ -6,9 +6,9 @@ fn main() {
macro_rules! one_nested_count_and_len {
( $( [ $( $l:literal ),* ] ),* ) => {
[
// outer-most repetition
// outermost repetition
$(
// inner-most repetition
// innermost repetition
$(
${ignore($l)} ${index()}, ${len()},
)*
@ -23,34 +23,34 @@ macro_rules! one_nested_count_and_len {
[
// # ["foo"]
// ## inner-most repetition (first iteration)
// ## innermost repetition (first iteration)
//
// `index` is 0 because this is the first inner-most iteration.
// `len` is 1 because there is only one inner-most repetition, "foo".
// `index` is 0 because this is the first innermost iteration.
// `len` is 1 because there is only one innermost repetition, "foo".
0, 1,
// ## outer-most repetition (first iteration)
// ## outermost repetition (first iteration)
//
// `count` is 1 because of "foo", i,e, `$l` has only one repetition,
// `index` is 0 because this is the first outer-most iteration.
// `len` is 2 because there are 2 outer-most repetitions, ["foo"] and ["bar", "baz"]
// `index` is 0 because this is the first outermost iteration.
// `len` is 2 because there are 2 outermost repetitions, ["foo"] and ["bar", "baz"]
1, 0, 2,
// # ["bar", "baz"]
// ## inner-most repetition (first iteration)
// ## innermost repetition (first iteration)
//
// `index` is 0 because this is the first inner-most iteration
// `index` is 0 because this is the first innermost iteration
// `len` is 2 because there are repetitions, "bar" and "baz"
0, 2,
// ## inner-most repetition (second iteration)
// ## innermost repetition (second iteration)
//
// `index` is 1 because this is the second inner-most iteration
// `index` is 1 because this is the second innermost iteration
// `len` is 2 because there are repetitions, "bar" and "baz"
1, 2,
// ## outer-most repetition (second iteration)
// ## outermost repetition (second iteration)
//
// `count` is 2 because of "bar" and "baz", i,e, `$l` has two repetitions,
// `index` is 1 because this is the second outer-most iteration
// `len` is 2 because there are 2 outer-most repetitions, ["foo"] and ["bar", "baz"]
// `index` is 1 because this is the second outermost iteration
// `len` is 2 because there are 2 outermost repetitions, ["foo"] and ["bar", "baz"]
2, 1, 2,
// # last count
@ -61,7 +61,7 @@ macro_rules! one_nested_count_and_len {
// Based on the above explanation, the following macros should be straightforward
// Grouped from the outer-most to the inner-most
// Grouped from the outermost to the innermost
macro_rules! three_nested_count {
( $( { $( [ $( ( $( $i:ident )* ) )* ] )* } )* ) => {
&[
@ -156,7 +156,7 @@ macro_rules! three_nested_count {
][..]
);
// Grouped from the outer-most to the inner-most
// Grouped from the outermost to the innermost
macro_rules! three_nested_len {
( $( { $( [ $( ( $( $i:ident )* ) )* ] )* } )* ) => {
&[

View File

@ -10,12 +10,12 @@ macro_rules! curly__no_rhs_dollar__round {
macro_rules! curly__no_rhs_dollar__no_round {
( $i:ident ) => { ${ count($i) } };
//~^ ERROR `count` can not be placed inside the inner-most repetition
//~^ ERROR `count` can not be placed inside the innermost repetition
}
macro_rules! curly__rhs_dollar__no_round {
( $i:ident ) => { ${ count($i) } };
//~^ ERROR `count` can not be placed inside the inner-most repetition
//~^ ERROR `count` can not be placed inside the innermost repetition
}
#[rustfmt::skip] // autoformatters can break a few of the error traces

View File

@ -196,13 +196,13 @@ error: expected identifier or string literal
LL | ( $( $i:ident ),* ) => { ${ {} } };
| ^^
error: `count` can not be placed inside the inner-most repetition
error: `count` can not be placed inside the innermost repetition
--> $DIR/syntax-errors.rs:12:24
|
LL | ( $i:ident ) => { ${ count($i) } };
| ^^^^^^^^^^^^^
error: `count` can not be placed inside the inner-most repetition
error: `count` can not be placed inside the innermost repetition
--> $DIR/syntax-errors.rs:17:24
|
LL | ( $i:ident ) => { ${ count($i) } };