Strip external generics on build#662
Conversation
|
Might want to clarify in the docs that it should come after all method registration. The example in This also raises the idea of a combined function |
And refactor out some package helpers
| S7::method(t3_s4, t4_class) <- function(x) "s4-dispatch" | ||
|
|
||
| .onLoad <- function(libname, pkgname) { | ||
| S7::S4_register(t4_class) |
There was a problem hiding this comment.
@lawremi Claude discovered this while writing this test. Does that seem correct to you? (i.e. that S4_register(), which calls setOldClass() has to be called onLoad)
There was a problem hiding this comment.
Or maybe this is related to the environment fixes in #643?
There was a problem hiding this comment.
Shouldn't be necessary to call S4_register() at runtime. All it does is call setOldClass() which of course works at build time. Strangely, Gemini suggested the same thing when converting a package to use S7.
There was a problem hiding this comment.
Let's hope that #663 fixes this. I'll hold off on merging until that's confirmed.
|
Hmmm, I wonder if we can call ... Nope, that doesn't work. |
Fixes #364