]> git.lizzy.rs Git - rust.git/commit
Merge #4029
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>
Sat, 18 Apr 2020 17:56:54 +0000 (17:56 +0000)
committerGitHub <noreply@github.com>
Sat, 18 Apr 2020 17:56:54 +0000 (17:56 +0000)
commit98819d89199c5138cc5018b036b0ec5d3fade77e
tree77b293ab5eb3a99f70082efe9cb66784f71f3343
parent84e3304a9bf0d68e30d58b1e37a6db2e9ec97525
parent72bba9882889b2e20fd91e3c6c3a97debbbe6543
Merge #4029

4029: Fix various proc-macro bugs r=matklad a=edwin0cheng

This PRs does the following things:

1. Fixed #4001 by splitting `LIFETIME` lexer token to two mbe tokens. It is because rustc token stream expects `LIFETIME` as a combination of punct and ident, but RA `tt:TokenTree` treats it as a single `Ident` previously.
2. Fixed #4003, by skipping `proc-macro` for completion. It is because currently we don't have `AstNode` for `proc-macro`. We would need to redesign how to implement `HasSource` for `proc-macro`.
3.  Fixed a bug how empty `TokenStream` merging in `proc-macro-srv` such that no L_DOLLAR and R_DOLLAR will be emitted accidentally.

Co-authored-by: Edwin Cheng <edwin0cheng@gmail.com>