Skip to content

S4 module metadata (2 of 2, over #1515) - #1516

Merged
eddelbuettel merged 2 commits into
RcppCore:masterfrom
mdsumner:s4-module-metadata
Oct 22, 2026
Merged

eddelbuettel merged 2 commits into
RcppCore:masterfrom
mdsumner:s4-module-metadata

Conversation

@mdsumner

@mdsumner mdsumner commented Oct 2, 2026

Copy link
Copy Markdown
Contributor

@Enchufa2 Enchufa2 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

A rebase is needed, and an updated ChangeLog.

Comment thread R/00_classes.R
Comment on lines +66 to +71
.cpp_methods_info <- function( x, prefix = " " ){
paste(
paste( prefix, x@signatures, ifelse(x@const, " const", "" ), "\n", prefix, prefix,
ifelse( nchar(x@docstrings), paste( "docstring :", x@docstrings) , "" )
) , collapse = "\n" )
}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Do we really need this? This is called once per method, so after the savings of this PR, this probably takes a lot of time. S4_CppOverloadedMethods in the C++ side already loops over every overload, so we could build each signature and store it in a docinfo slot.

@eddelbuettel

Copy link
Copy Markdown
Member

Good point in the missing rebase. What I tested was a '1515 and 1516' combination but then I only merged 1515 so far.

@Enchufa2

Enchufa2 commented Oct 22, 2026 •

Copy link
Copy Markdown
Member

BTW, and of course, the only shortcoming of this PR is that a package built against this won't load with an older version of Rcpp (but it does work the other way around). I think we can live with this.

@Enchufa2

Copy link
Copy Markdown
Member

Rebased and updated the ChangeLog. If you already tested this with the revdeps checks, then I propose to merge it and we could address what I raised above as a separate PR.

@eddelbuettel

Copy link
Copy Markdown
Member

Good plan, squash-merging as usual.

@eddelbuettel
eddelbuettel merged commit 2cf7685 into RcppCore:master Oct 22, 2026
14 checks passed
@mdsumner

Copy link
Copy Markdown
Contributor Author

Thanks!!

@Enchufa2

Copy link
Copy Markdown
Member

Thanks to you for taking the time to put this together!

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.

3 participants