-
Notifications
You must be signed in to change notification settings - Fork 12.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add 'lifetime' and 'type parameter list' fragment specifiers to macro parser. #10413
Comments
cc me |
cc moi |
Sigh, I guess this is another problem with using the not-actually-delimiters (... < $($x:tt)* > ...) => ... but this will (I think) try to consume the terminating There is probably a way to fix that with a recursive macro that eats one |
triage: not aware of any change here. |
This is now only tracking the type parameter fragments, which would definitely need an RFC. Lifetimes in macros are tracked here: #10413. I'm going to close this since there's nothing left to be tracked in the rust-lang/rust repo for this issue. |
[significant_drop_tightening] Fix rust-lang#10413 Fix rust-lang#10413 This is quite a rewrite that unfortunately took a large amount of time. I tried my best to comment what is going on to easy review but feel free to ask any question. The problem basically is that the current algorithm is only taking into consideration single blocks which means that things like the following don't work or show unpredictable results. ```rust let mutex = Mutex::new(1); { let lock = mutex.lock().unwrap(); { let _ = *lock; } } ``` The solve the issue, each path that refers a lock is now being tracked individually. ``` changelog: [`significant_drop_tightening`]: Lift the restriction of only considerate single blocks ```
This would make manipulating type parameter lists much easier.
The text was updated successfully, but these errors were encountered: