rust/compiler/rustc_span/src
Arpad Borsos 9f36f988ad
Avoid GenFuture shim when compiling async constructs
Previously, async constructs would be lowered to "normal" generators,
with an additional `from_generator` / `GenFuture` shim in between to
convert from `Generator` to `Future`.

The compiler will now special-case these generators internally so that
async constructs will *directly* implement `Future` without the need
to go through the `from_generator` / `GenFuture` shim.

The primary motivation for this change was hiding this implementation
detail in stack traces and debuginfo, but it can in theory also help
the optimizer as there is less abstractions to see through.
2022-11-24 10:04:27 +01:00
..
analyze_source_file remove redundant closures (clippy::redundant_closure) 2021-01-03 13:34:24 +01:00
lev_distance Improve method name suggestions 2022-04-03 16:38:57 +01:00
source_map Fix #103451, find_width_of_character_at_span return width with 1 when reaching end 2022-10-25 21:16:12 +08:00
symbol Move the Lock into symbol::Interner 2021-09-15 18:46:45 +02:00
analyze_source_file.rs Fix some clippy lints 2020-12-03 17:08:19 -05:00
caching_source_map_view.rs Convert debug_assert to assert in CachingSourceMapView 2021-09-17 12:01:29 -05:00
def_id.rs Manually order DefId on 64-bit big-endian 2022-09-27 15:21:31 -07:00
edition.rs Create 2024 edition 2022-04-02 02:45:49 -04:00
fatal_error.rs Make fatal DiagnosticBuilder yield never 2022-03-27 22:25:32 -07:00
hygiene.rs ssa: implement #[collapse_debuginfo] 2022-09-07 13:54:51 +01:00
lev_distance.rs Improve method name suggestions 2022-04-03 16:38:57 +01:00
lib.rs Use as_deref in compiler (but only where it makes sense) 2022-11-16 21:58:58 +00:00
profiling.rs extend EventArgRecorder into span-aware SpannedEventArgRecorder 2022-04-22 18:06:21 +02:00
source_map.rs detect () to avoid redundant <> suggestion for type 2022-11-17 09:01:27 -08:00
span_encoding.rs Make names more explicit. 2022-08-17 19:20:28 +02:00
symbol.rs Avoid GenFuture shim when compiling async constructs 2022-11-24 10:04:27 +01:00
tests.rs Lazify SourceFile::lines. 2022-06-01 10:36:39 +10:00