rust/compiler/rustc_errors/src
Nicholas Nethercote 66e9b1149c Rearrange TokenTreesReader::parse_token_tree.
`parse_token_tree` is basically a match with four arms: `Eof`,
`OpenDelim`, `CloseDelim`, and "other". It has two call sites, and at
each call site one of the arms is unreachable. It's also not inlined.

This commit removes `parse_token_tree` by splitting it into four
functions and inlining them. This avoids some repeated conditional
tests and also some non-inlined function calls on the hot path.
2022-09-26 08:28:45 +10:00
..
json Use serde_json for json error messages 2022-06-03 16:46:19 +00:00
annotate_snippet_emitter_writer.rs errors: move translation logic into module 2022-08-15 12:26:35 +01:00
diagnostic.rs Revert "Auto merge of #101620 - cjgillot:compute_lint_levels_by_def, r=oli-obk" 2022-09-22 19:36:11 +02:00
diagnostic_builder.rs FIX - adopt new Diagnostic naming in newly migrated modules 2022-09-21 11:43:22 -04:00
emitter.rs Don't render inline suggestions of only spaces 2022-09-13 03:52:43 +00:00
json.rs errors: move translation logic into module 2022-08-15 12:26:35 +01:00
lib.rs Rearrange TokenTreesReader::parse_token_tree. 2022-09-26 08:28:45 +10:00
lock.rs
registry.rs Remove (lots of) dead code 2021-03-27 22:16:33 -04:00
snippet.rs Compute most of Public/Exported access level in rustc_resolve 2022-01-09 21:33:14 +00:00
styled_buffer.rs Spellchecking some comments 2022-03-30 01:39:38 -04:00
translation.rs Use more into_iter rather than drain(..) 2022-08-30 04:42:03 +01:00