]> git.lizzy.rs Git - rust.git/commitdiff
Merge #2200
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>
Mon, 11 Nov 2019 11:48:02 +0000 (11:48 +0000)
committerGitHub <noreply@github.com>
Mon, 11 Nov 2019 11:48:02 +0000 (11:48 +0000)
2200: Add variables to HIR r=matklad a=matklad

Introduce a `hir::Variable`, which should cover locals, parameters and `self`. Unlike `PatId`, variable knows it's owner so it is self-contained, and should be more convenient to use from `ra_ide_api`.

The goal here is to hide more details about `Body` from hir, which should make it easier to move `Body` into `hir_def`. I don't think that `ra_ide_api` intrracts with bodies directly at the moment anyway, but the glue layer is based basically on `ast::BindPat`, which seems pretty brittle.

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>

Trivial merge