Skip to content

Remove MetaMethod and GhostMethod#1705

Open
Earlopain wants to merge 1 commit into
ruby:masterfrom
Earlopain:remove-method-subclasses
Open

Remove MetaMethod and GhostMethod#1705
Earlopain wants to merge 1 commit into
ruby:masterfrom
Earlopain:remove-method-subclasses

Conversation

@Earlopain
Copy link
Copy Markdown
Contributor

RDoc has no special handling for these. MetaMethod is unreferenced, and GhostMethod was only used for tomdoc.

RDoc has no special handling for these. `MetaMethod` is unreferenced, and `GhostMethod` was only
used for tomdoc.
Copilot AI review requested due to automatic review settings May 11, 2026 12:09
@Earlopain Earlopain requested a deployment to fork-preview-protection May 11, 2026 12:09 — with GitHub Actions Waiting
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR removes the RDoc::MetaMethod and RDoc::GhostMethod code objects, which no longer have any special handling in RDoc (and were unreferenced aside from TomDoc parsing). The TomDoc signature parsing now creates standard RDoc::AnyMethod instances instead of RDoc::GhostMethod.

Changes:

  • Replace RDoc::GhostMethod with RDoc::AnyMethod when synthesizing methods from TomDoc signatures.
  • Delete the RDoc::MetaMethod and RDoc::GhostMethod class files.
  • Remove related autoload entries and inline documentation references.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.

Show a summary per file
File Description
lib/rdoc/parser/ruby.rb Uses RDoc::AnyMethod for TomDoc-derived method objects instead of GhostMethod.
lib/rdoc/code_object/meta_method.rb Removes the unused RDoc::MetaMethod subclass.
lib/rdoc/code_object/ghost_method.rb Removes the RDoc::GhostMethod subclass previously used only for TomDoc.
lib/rdoc/code_object.rb Updates the code object hierarchy comment to drop removed classes.
lib/rdoc.rb Removes autoloads for the deleted code object classes.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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