[Rd] $new cannot be accessed when running from Rscript and methods package is not loaded

Winston Chang winstonchang1 at gmail.com
Wed Feb 12 22:15:35 CET 2014


On Tue, Feb 11, 2014 at 3:27 PM, Simon Urbanek
<simon.urbanek at r-project.org> wrote:
>
> I suspect the problem could be classified as bug in methods which doesn't behave correctly if not attached. I didn't look into details, but there used to be a technical problem in R C API where you could not pass the right environments to make that work (that bit me when I tried to use S4 a while ago), but I think that has been solved, so conceptually I think this is a bug that could be fixed. This sounds like something that should be possible to fix - even if it means fixing something in R to make it happen. Working around it in hacky ways mentioned here doesn't solve the underlying problem.


I agree that the best solution would for methods to work properly even
when not attached. I suspect that many people would be appreciative it
if this issue were fixed and they didn't have to resort to these hacks
and workarounds.

-Winston



More information about the R-devel mailing list