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

Support single overload #168

Merged
merged 2 commits into from
May 22, 2023
Merged

Conversation

ohai
Copy link
Contributor

@ohai ohai commented May 21, 2023

Outline

This PR adds support for a single "overload" tag. This PR is required to handle YARD documents for C/C++ extension.

Background

The "overload" tag in YARD is used for the following two purposes:

  1. Describing overloaded methods
  2. Write YARD documents for C/C++ extensions

The YARD system can not retrieve signatures of methods written by C/C++, therefore overload tag is usually used to describe such method signatures.

Description

This PR treats such an overload tag by replacing the method signature with the content of the first overload tag.
The information contained in the overload tag is also merged into the method object.

Limitation

The second and subsequent overload tags are ignored.

ohai added 2 commits May 15, 2023 22:36
This functionality is mainly required for YARD docs for C/C++ extensions.
Now the information in @overload tag does not replace MethodObject
object, it is merged into MethodObject object.
@AaronC81
Copy link
Owner

Thanks! I've never seen this before, interesting to know about :)

@AaronC81 AaronC81 merged commit e60b829 into AaronC81:master May 22, 2023
@AaronC81
Copy link
Owner

This change is included in release 5.1.0 and also 6.0.0, so you can pick which to use depending on whether 6.0's breaking change affects you (support for RBS 3.0)

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.

2 participants