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

Provide .dollarNames method #289

Merged
merged 3 commits into from
Sep 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@ Suggests:
Config/Needs/website: tidyverse/tidytemplate, ggplot2, microbenchmark, scales
Config/testthat/edition: 3
Encoding: UTF-8
RoxygenNote: 7.2.3
RoxygenNote: 7.3.2
1 change: 1 addition & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# Generated by roxygen2: do not edit by hand

S3method(.DollarNames,R6)
S3method(as.list,R6)
S3method(format,R6)
S3method(format,R6ClassGenerator)
Expand Down
2 changes: 2 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
R6 2.5.1.9000
========

* R6 methods no longer recommends `initialize` or `.__enclos_env__` in autocomplete.

* The deprecated `lock` parameter has been removed.

* `R6Class()` now prints a message when a `finalize` method is public instead of private.
Expand Down
6 changes: 6 additions & 0 deletions R/r6_class.R
Original file line number Diff line number Diff line change
Expand Up @@ -541,3 +541,9 @@ R6Class <- encapsulate(function(classname = NULL, public = list(),

generator
})

#' @export
.DollarNames.R6 <- function(x, pattern) {
names <- NextMethod()
names <- setdiff(names, c(".__enclos_env__", "initialize"))
}
Loading