Skip to content

missing_docs lint triggers on all declarative macros 2.0 #57569

Closed

Description

@jethrogb
#![feature(decl_macro)]
#![deny(missing_docs)]
#![allow(unused)]
//! my crate

mod m {
    macro a { () => {} }
    pub(crate) macro b { () => {} }
    pub macro c { () => {} }
    macro_rules! r { () => {} }
    pub fn f() {}
}
error: missing documentation for macro
 --> m.rs:7:5
  |
7 |     macro a { () => {} }
  |     ^^^^^^^
  |
note: lint level defined here
 --> m.rs:2:9
  |
2 | #![deny(missing_docs)]
  |         ^^^^^^^^^^^^

error: missing documentation for macro
 --> m.rs:8:5
  |
8 |     pub(crate) macro b { () => {} }
  |     ^^^^^^^^^^^^^^^^^^

error: missing documentation for macro
 --> m.rs:9:5
  |
9 |     pub macro c { () => {} }
  |     ^^^^^^^^^^^

Note there is no error for r or f.

Activity

  1. added
    A-lintsArea: Lints (warnings about flaws in source code) such as unused_mut.
    A-macrosArea: All kinds of macros (custom derive, macro_rules!, proc macros, ..)
    A-decl-macros-2-0Area: Declarative macros 2.0 (#39412)
    on Jan 13, 2019
  2. GuillaumeGomez commented on Jan 16, 2019

    @GuillaumeGomez
    Member

    That's interesting. A bad check very certainly on wether something is publically viewable or not.

  3. inquisitivecrystal commented on Jul 6, 2021

    @inquisitivecrystal
    Contributor

    Going to see if I can figure this out.

    @rustbot claim
    @rustbot label C-bug T-compiler

  4. added
    C-bugCategory: This is a bug.
    T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.
    on Jul 6, 2021
  5. added
    T-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.
    on Jul 6, 2021
  6. inquisitivecrystal commented on Jul 7, 2021

    @inquisitivecrystal
    Contributor

    I have what I think is a solution implemented, but still need to do final testing. Fingers crossed.

  7. added a commit that references this issue on Jul 10, 2021
  8. added
    A-lintsArea: Lints (warnings about flaws in source code) such as unused_mut.
    and removed
    A-lintsArea: Lints (warnings about flaws in source code) such as unused_mut.
    on Dec 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

A-decl-macros-2-0Area: Declarative macros 2.0 (#39412)A-lintsArea: Lints (warnings about flaws in source code) such as unused_mut.A-macrosArea: All kinds of macros (custom derive, macro_rules!, proc macros, ..)C-bugCategory: This is a bug.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.T-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions