From 74edcb8bd1e457cbfbbd8e101652301824a67255 Mon Sep 17 00:00:00 2001 From: Yuri Astrakhan Date: Wed, 30 Mar 2022 01:39:38 -0400 Subject: [PATCH] Spellchecking some comments This PR attempts to clean up some minor spelling mistakes in comments --- Readme.md | 2 +- example/arbitrary_self_types_pointers_and_wrappers.rs | 2 +- src/builder.rs | 4 ++-- src/context.rs | 2 +- src/intrinsic/mod.rs | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Readme.md b/Readme.md index 27b30e0fd1b..fe23a267696 100644 --- a/Readme.md +++ b/Readme.md @@ -12,7 +12,7 @@ A secondary goal is to check if using the gcc backend will provide any run-time ## Building **This requires a patched libgccjit in order to work. -The patches in [this repostory](https://github.com/antoyo/libgccjit-patches) need to be applied. +The patches in [this repository](https://github.com/antoyo/libgccjit-patches) need to be applied. (Those patches should work when applied on master, but in case it doesn't work, they are known to work when applied on 079c23cfe079f203d5df83fea8e92a60c7d7e878.) You can also use my [fork of gcc](https://github.com/antoyo/gcc) which already includes these patches.** diff --git a/example/arbitrary_self_types_pointers_and_wrappers.rs b/example/arbitrary_self_types_pointers_and_wrappers.rs index ddeb752f93e..3af0ba09e0b 100644 --- a/example/arbitrary_self_types_pointers_and_wrappers.rs +++ b/example/arbitrary_self_types_pointers_and_wrappers.rs @@ -37,7 +37,7 @@ impl, U> DispatchFromDyn> for Wrapper {} trait Trait { // This method isn't object-safe yet. Unsized by-value `self` is object-safe (but not callable - // without unsized_locals), but wrappers arond `Self` currently are not. + // without unsized_locals), but wrappers around `Self` currently are not. // FIXME (mikeyhew) uncomment this when unsized rvalues object-safety is implemented // fn wrapper(self: Wrapper) -> i32; fn ptr_wrapper(self: Ptr>) -> i32; diff --git a/src/builder.rs b/src/builder.rs index b2f46e92ecc..21c7d420b20 100644 --- a/src/builder.rs +++ b/src/builder.rs @@ -508,7 +508,7 @@ fn sdiv(&mut self, a: RValue<'gcc>, b: RValue<'gcc>) -> RValue<'gcc> { } fn exactsdiv(&mut self, a: RValue<'gcc>, b: RValue<'gcc>) -> RValue<'gcc> { - // TODO(antoyo): posion if not exact. + // TODO(antoyo): poison if not exact. // FIXME(antoyo): rustc_codegen_ssa::mir::intrinsic uses different types for a and b but they // should be the same. let typ = a.get_type().to_signed(self); @@ -1252,7 +1252,7 @@ fn cx(&self) -> &CodegenCx<'gcc, 'tcx> { } fn do_not_inline(&mut self, _llret: RValue<'gcc>) { - // FIMXE(bjorn3): implement + // FIXME(bjorn3): implement } fn set_span(&mut self, _span: Span) {} diff --git a/src/context.rs b/src/context.rs index 5e5b9e7e9b1..edbe7122bdd 100644 --- a/src/context.rs +++ b/src/context.rs @@ -110,7 +110,7 @@ pub struct CodegenCx<'gcc, 'tcx> { /// NOTE: a hack is used because the rustc API is not suitable to libgccjit and as such, /// `const_undef()` returns struct as pointer so that they can later be assigned a value. /// As such, this set remembers which of these pointers were returned by this function so that - /// they can be deferenced later. + /// they can be dereferenced later. /// FIXME(antoyo): fix the rustc API to avoid having this hack. pub structs_as_pointer: RefCell>>, } diff --git a/src/intrinsic/mod.rs b/src/intrinsic/mod.rs index 08e584a46f3..68a05d95ef7 100644 --- a/src/intrinsic/mod.rs +++ b/src/intrinsic/mod.rs @@ -340,7 +340,7 @@ fn abort(&mut self) { } fn assume(&mut self, value: Self::Value) { - // TODO(antoyo): switch to asumme when it exists. + // TODO(antoyo): switch to assume when it exists. // Or use something like this: // #define __assume(cond) do { if (!(cond)) __builtin_unreachable(); } while (0) self.expect(value, true);