Skip to content

rustc is too eager to see macros where there are not #41273

Closed

Description

@nox

https://is.gd/TY8WYH

The actual error is a missing fn.

Activity

  1. added
    A-diagnosticsArea: Messages for errors, warnings, and lints
    on Apr 14, 2017
  2. estebank commented on Dec 12, 2017

    @estebank
    Contributor

    Current output:

    error: missing `fn` for method definition
     --> src/main.rs:1:4
      |
    1 | pub what_macro() {}
      |    ^
    help: add `fn` here to parse `what_macro` as a public method
      |
    1 | pub fn what_macro() {}
      |     ^^
    

    Fixed in #45997.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-diagnosticsArea: Messages for errors, warnings, and lintsC-enhancementCategory: An issue proposing an enhancement or a PR with one.WG-diagnosticsWorking group: Diagnostics

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions