Skip to content

📚️ Fix Config attributes docs broken by rdoc 8.0 - #735

Merged
nevans merged 1 commit into
masterfrom
fix-config-attributes-rdoc-8.0
Aug 26, 2026
Merged

nevans merged 1 commit into
masterfrom
fix-config-attributes-rdoc-8.0

Conversation

@nevans

@nevans nevans commented Aug 26, 2026

Copy link
Copy Markdown
Collaborator

The prism parser (the only parser in rdoc v8.0) is strict about arguments to attr_reader, attr_writer, attr_accessor, and attr. It only parses as an attribute when all arguments are symbols.

The rdoc for Net::IMAP::Config intentionally took advantage of the looser parsing done by rdoc 7.2. Net::IMAP::Config defines its own versions of attr_reader, attr_writer and attr_accessor that add keyword arguments.

This implements a temporary workaround to fix the documentation pages, but (in my opinion) this is a regression in rdoc 8.0.0, which should be fixed in rdoc. See ruby/rdoc#1790

The prism parser (the only parser in rdoc v8.0) is strict about
arguments to `attr_reader`, `attr_writer`, `attr_accessor`, and `attr`.
It _only_ parses as an attribute when _all_ arguments are symbols.

IMO, this is a regression in rdoc 8.0, and a bug in rdoc.

The rdoc for `Net::IMAP::Config` intentionally took advantage of the
looser parsing done by rdoc 7.2.  `Net::IMAP::Config` defines its own
versions of `attr_reader`, `attr_writer` and `attr_accessor` that add
keyword arguments.

See ruby/rdoc#1790
@nevans
nevans force-pushed the fix-config-attributes-rdoc-8.0 branch from 78baa76 to 5aeab90 Compare August 26, 2026 18:46
@nevans nevans added the documentation Improvements or additions to documentation label Aug 26, 2026
@nevans
nevans merged commit 0ad218a into master Aug 26, 2026
34 checks passed
@nevans
nevans deleted the fix-config-attributes-rdoc-8.0 branch August 26, 2026 22:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant