dtolnay / dtolnay/quote

Unseparated punctuations should have `Spacing::Joint`

Open
#291 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
1.6k
Forks
113
PR merge metrics
No merged PRs in 30d

Description

The document of [proc_macro::Spacing](https://doc.rust-lang.org/stable/proc_macro/enum.Spacing.html#variant.Joint) says:

> * When a Punct is immediately followed by another Punct without a whitespace. E.g. `+` is Joint in `+=` and `++`.

However, `quote!(++)` generates two sepalated `+` tokens which have `Spacing::Alone` and `quote!(++).to_string()` is `"+ +"`.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.