Nicholas Nethercote b0440d359b Avoid useless Vec clones in pending_obligations().
The only instance of `ObligationForest` in use has an obligation type of
`PendingPredicateObligation`, which contains a `PredicateObligation` and a
`Vec<Ty>`.

`FulfillmentContext::pending_obligations()` calls
`ObligationForest::pending_obligations()`, which clones all the
`PendingPredicateObligation`s. But the `Vec<Ty>` field of those cloned
obligations is never touched.

This patch changes `ObligationForest::pending_obligations()` to
`map_pending_obligations` -- which gives callers control about which part
of the obligation to clone -- and takes advantage of the change to avoid
cloning the `Vec<Ty>`. The change speeds up runs of a few rustc-perf
benchmarks, the best by 1%.
2018-06-08 09:00:17 +10:00
..
2018-06-03 17:43:11 +03:00
2018-05-27 17:28:35 +02:00
2018-06-01 14:56:01 +02:00
2018-06-01 14:56:01 +02:00
2018-06-01 14:56:01 +02:00
2018-06-01 14:56:01 +02:00
2018-06-03 14:31:37 +02:00
2018-06-01 15:00:17 +02:00

This directory contains the source code of the rust project, including:

  • rustc and its tests
  • libstd
  • Various submodules for tools, like rustdoc, rls, etc.

For more information on how various parts of the compiler work, see the rustc guide.

Their is also useful content in the following READMEs, which are gradually being moved over to the guide: