rust/compiler/rustc_parse/src/lexer
Nicholas Nethercote d7928a92e5 Clarify spacing computation.
The spacing computation is done in two parts. In the first part
`next_token` and `bump` use `Spacing::Alone` to mean "preceded by
whitespace" and `Spacing::Joint` to mean the opposite. In the second
part `parse_token_tree_other` then adjusts the `spacing` value to mean
the usual thing (i.e. "is the following token joinable punctuation?").
This shift in meaning is very confusing and it took me some time to
understand what was going on.

This commit changes the first part to use a bool, and adds some
comments, which makes things much clearer.
2022-09-26 13:21:26 +10:00
..
mod.rs Clarify spacing computation. 2022-09-26 13:21:26 +10:00
tokentrees.rs Clarify spacing computation. 2022-09-26 13:21:26 +10:00
unescape_error_reporting.rs Always import all tracing macros for the entire crate instead of piecemeal by module 2022-09-01 14:54:27 +00:00
unicode_chars.rs remove unnecessary to_string and String::new 2022-06-13 15:48:40 +09:00