Skip to content

Support :args: directive before method #541

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

Merged
merged 1 commit into from
Oct 24, 2017

Conversation

aycabta
Copy link
Member

@aycabta aycabta commented Oct 11, 2017

The :args: directive is supported only by after def keyword line like below:

  def method_with_args_comment(*array) # :args: a, b, c
  end
  # => documented as method_with_args_comment(a, b, c)

This commit changes to support like below:

  ##
  # :args: a, b, c
  def meth(*array)
  end
  # => documented as meth(a, b, c)

This fixes #433.

The :args: directive is supported only by after "def" keyword line like
below:

  def method_with_args_comment(*array) # :args: a, b, c
  end
  # => documented as method_with_args_comment(a, b, c)

This commit changes to support like below:

  ##
  # :args: a, b, c
  def meth(*array)
  end
  # => documented as meth(a, b, c)
@aycabta aycabta force-pushed the support-args-before-method branch from b0054d5 to 57b30aa Compare October 11, 2017 14:49
@hsbt
Copy link
Member

hsbt commented Oct 24, 2017

New tests is fine to me.

@hsbt hsbt merged commit 9c33283 into ruby:master Oct 24, 2017
@aycabta aycabta deleted the support-args-before-method branch October 24, 2017 11:00
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

Successfully merging this pull request may close these issues.

:arg:, :args: doesn't work.
2 participants