about summary refs log tree commit diff
path: root/src/test/codegen/src-hash-algorithm/src-hash-algorithm-md5.rs
diff options
context:
space:
mode:
authorAman Arora <me@aman-arora.com>2020-06-17 18:13:05 -0400
committerAman Arora <aman23091998@gmail.com>2020-06-18 18:59:38 -0400
commit922ff8e485fc6d95286fcf860e05742dc8797223 (patch)
tree7040cda8f9c3fb0f9adb4b7c99d8bcb646b96620 /src/test/codegen/src-hash-algorithm/src-hash-algorithm-md5.rs
parent93696f45fffbefa55ff57d91b12fc29c77ee6302 (diff)
downloadrust-922ff8e485fc6d95286fcf860e05742dc8797223.tar.gz
rust-922ff8e485fc6d95286fcf860e05742dc8797223.zip
Refactor hir::Place
For the following code
```rust
let c = || bar(foo.x, foo.x)
```

We generate two different `hir::Place`s for both `foo.x`.
Handling this adds overhead for analysis we need to do for RFC 2229.

We also want to store type information at each Projection to support
analysis as part of the RFC. This resembles what we have for
`mir::Place`

This commit modifies the Place as follows:
- Rename to `PlaceWithHirId`, where there `hir_id` is that of the
expressioin.
- Move any other information that describes the access out to another
struct now called `Place`.
- Removed `Span`, it can be accessed using the [hir
API](https://doc.rust-lang.org/nightly/nightly-rustc/rustc_middle/hir/map/struct.Map.html#method.span)
- Modify `Projection` to be a strucutre of its own, that currently only
contains the `ProjectionKind`.

Adding type information to projections wil be completed as part of https://github.com/rust-lang/project-rfc-2229/issues/5

Closes https://github.com/rust-lang/project-rfc-2229/issues/3

Co-authored-by: Aman Arora <me@aman-arora.com>
Co-authored-by: Roxane Fruytier <roxane.fruytier@hotmail.com>
Diffstat (limited to 'src/test/codegen/src-hash-algorithm/src-hash-algorithm-md5.rs')
0 files changed, 0 insertions, 0 deletions