• “Elaboration” is the process of identifying all the predicates that are implied by a source predicate. Currently, this basically means walking the “supertraits” and other similar assumptions. For example, if we know that T: Ord, the elaborator would deduce that T: PartialOrd holds as well. Similarly, if we have trait Foo: 'static, and we know that T: Foo, then we know that T: 'static.
  • A filter around an iterator of predicates that makes it yield up just trait references.
  • “Trait alias expansion” is the process of expanding a sequence of trait references into another sequence by transitively following all trait aliases. e.g. If you have bounds like Foo + Send, a trait alias trait Foo = Bar + Sync;, and another trait alias trait Bar = Read + Write, then the bounds would expand to Read + Write + Sync + Send. Expansion is done via a DFS (depth-first search), and the visited field is used to avoid cycles.
  • Stores information about the expansion of a trait via a path of zero or more trait aliases.



  • Describes how to elaborate an obligation into a sub-obligation.