Chalk-RLS integration

active work items

  • remove concept of “local and external” and reformulate in terms of crate-ids — make coherence relative to a specific crate? @Sunjay V
  • how to handle ids? @Wilco K (detrumi)
  • chalk uses ids, RLS has a distinct notion of id per definition
  • list out the various places that chalk uses ids
  • compare to corresponding RLS types 
  • refactor to match
  • error types
  • should we add an error type? perhaps it unifies to CannotProve or something like that?
  • morph it into type, isomorphic to chalk::Ty bit by bit, than swap out the impl

things in the RLS

  • Some links into the RLS HIR:
  • Things to add:
  • TraitRef type for resolved traits
  • representation of bounds
  • refactor type representation to be closer to chalk’s
  • consolidate variants into Apply
  • remove stuff like names and implement proper pretty-printing

overall flow

  • main integration point is probably a prove query that, given a canonical goal, gives back the result
  • chalk-engine will call back to RLS to request “stuff from impls”
  • this will invoke chalk’s lowering code