rust-lang / rust-lang/reference
Typo? 3.1. Macros By Example / Path-Based Scope: `m!(); // OK: Path-based lookup`
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 1.6k
- Forks
- 607
- PR merge metrics
- PR metrics pending
Description
I suspect a typo.
Fragment of interest:
self::m!();
m!(); // OK: Path-based lookup finds m in the current module.
I suspect it must be:
self::m!(); // OK: Path-based lookup finds m in the current module.
i.e. the fragment m!(); must not be there.
I'm relatively new to Rust, still studying it. I can be wrong. But I have an intuitive described above suspicion of a typo. If that's not a typo then an extra explanation would help.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Find the Rust Reference section “3.1. Macros By Example / Path-Based Scope” and review the shown self::m!(); and m!(); fragments alongside the path-based lookup explanation. Confirm whether the second fragment is intentional; done means correcting the example or adding the explanation needed to make the behavior unambiguous.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 1/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 68/100