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

Fix anonymous class doc_namespace to use named superclass #13

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

tompng
Copy link
Member

@tompng tompng commented Dec 29, 2023

Showing document for a instance of anonymous class is slow

irb(main):001> s = Struct.new(:foo).new
irb(main):002> s.ins[TAB]

It's because doc_namespace returned '#inspect' instead of KLASS_NAME#inspect. RDoc seems to search every class that has method inspect.

Changed to search for superclass that has a name.

The same problem also exists in IRB's RegexpCompletor.

@tompng tompng added the bug Something isn't working label Dec 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant