Skip to content
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

@!macro cannot attach to DSL methods in @!parse #1583

Open
UlyssesZh opened this issue Sep 11, 2024 · 0 comments
Open

@!macro cannot attach to DSL methods in @!parse #1583

UlyssesZh opened this issue Sep 11, 2024 · 0 comments

Comments

@UlyssesZh
Copy link

@!macro cannot attach to DSL methods in @!parse.

Steps to reproduce

Write these in lib/test.rb:

# A test class.
class Test

  # @!macro [attach] property
  #   @return [$2] the $1 property
  # @!parse property :title, String

  # @!parse property :view_count, Integer
end

Run yard doc --debug.

Actual Output

No methods are documented.
image

Expected Output

It should be equivalent to this:

# A test class.
class Test

  # @!macro [attach] property
  #   @return [$2] the $1 property
  property :title, String

  property :view_count, Integer
end

image

Environment details:

  • OS: NixOS 24.05
  • Ruby version (ruby -v): 3.3.4
  • YARD version (yard -v): 0.9.37

I have read the Contributing Guide.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant