One piece of infrastructure we need to unlock macro-expansion/name resolution experimentation is handling of macro by example. Specifically:
There's a super prototype implementation in rust-analyzer already, and I wonder how we should expand it further. For example, I can imagine we can fully libariify this, and share code with rustc (so, macro-by-example working subgroup can be formed). Or we can write something useful for proc-macro authors (perhaps sharing code with nrc's proc-macro-rules). Or we can decide that full support of mbe is out of scope, and just make a minimal impl that allows experimentation with hygiene and incremental name resolution.
I don't really have any opinion here :) Perhaps someone from @WG-rls2.0 has more experience in this area?
This commit sums up the current state of mbe in rust-analyzer pretty well https://github.com/rust-analyzer/rust-analyzer/pull/968/commits/fb6576b6b7f500c37123fd10b1c8f90d6d90219a :)
We went looking everywhere, but couldn’t find those commits.
I hope that's not the actual state of mbe in rust-analyzer ;)
Usually indicates that the branch was force-pushed and indeed that specific commit hash is gone.
Editing the URL to remove the SHA and go back to the PR proper is usually a good step
Yeah, the situation is a tiny bit better: https://github.com/rust-analyzer/rust-analyzer/pull/968/commits/1bcc01822dbfc4f917105b5e22032ad8a728b33b :D (link to commit, b/c PR is huge)