diff --git a/src/rustc/middle/region.rs b/src/rustc/middle/region.rs index 7011ea43cc80..50f38b16e096 100644 --- a/src/rustc/middle/region.rs +++ b/src/rustc/middle/region.rs @@ -52,7 +52,7 @@ Regions are more complex than type parameters because, unlike type parameters, they can be universally quantified within a type. To put it another way, you cannot (at least at the time of this writing) have a variable `x` of type `fn(T) -> T`. You can have an *item* of -type `fn(T) - T`, but whenever it is referenced within a method, +type `fn(T) -> T`, but whenever it is referenced within a method, that type parameter `T` is replaced with a concrete type *variable* `$T`. To make this more concrete, imagine this code: @@ -114,7 +114,7 @@ to `&a` would be `re_bound(rid_param("a", 0u))`, and the inner reference would be `re_free(rid_param("a", 0u))`. In `item2()`, the inner reference would be `re_bound(rid_param("a", 0u))`. -#### Impliciations for typeck +#### Implications for typeck In typeck, whenever we call a function, we must go over and replace all references to `re_bound()` regions within its parameters with diff --git a/src/rustc/middle/typeck/infer.rs b/src/rustc/middle/typeck/infer.rs index c9fbad28bbd3..909ab69362f1 100644 --- a/src/rustc/middle/typeck/infer.rs +++ b/src/rustc/middle/typeck/infer.rs @@ -1090,8 +1090,8 @@ impl assignment for infer_ctxt { // ______________________________________________________________________ // Type combining // -// There are three type combiners, sub, lub, and glb. Each implements -// the interface `combine` contains methods for combining two +// There are three type combiners: sub, lub, and glb. Each implements +// the interface `combine` and contains methods for combining two // instances of various things and yielding a new instance. These // combiner methods always yield a `result`---failure is propagated // upward using `chain()` methods. @@ -1101,13 +1101,13 @@ impl assignment for infer_ctxt { // instance as the first parameter. This would be better implemented // using traits. For this system to work properly, you should not // call the `super_X(foo, ...)` functions directly, but rather call -// `foo.X(...)`. The implemtation of `X()` can then choose to delegate +// `foo.X(...)`. The implementation of `X()` can then choose to delegate // to the `super` routine or to do other things. // // In reality, the sub operation is rather different from lub/glb, but // they are combined into one interface to avoid duplication (they // used to be separate but there were many bugs because there were two -// copies of most routines. +// copies of most routines). // // The differences are: // @@ -1177,7 +1177,7 @@ fn super_substs( (_, _) { // If these two substitutions are for the same type (and // they should be), then the type should either - // consistenly have a region parameter or not have a + // consistently have a region parameter or not have a // region parameter. infcx.tcx.sess.bug( #fmt["substitution a had opt_region %s and \