[Rd] grep problem in R-devel 2.14 r57004

2011-09-15 Thread Mark.Bravington
Problem below with PCRE grep in R-devel; works fine in R-patched. (Unless there's been an absolutely massive change in rules for updated PCRE version 8.13; jeez I hope not) > grep( '[.][.]', '', perl=TRUE) Error in grep("[.][.]", "", perl = TRUE) : invalid regular expression '[.][.]' In additi

Re: [Rd] Revision of shell.exec?

2011-09-15 Thread Dirk Eddelbuettel
On 14 September 2011 at 16:56, Simon Urbanek wrote: | | On Sep 14, 2011, at 4:44 PM, Dirk Eddelbuettel wrote: | | > | > On 14 September 2011 at 16:22, Simon Urbanek wrote: | > | | > | On Sep 14, 2011, at 4:15 PM, Brian Oney wrote: | > | | > | > Hi there, | > | > new idea (at 10 at night). All

Re: [Rd] External pointers and an apparent memory leak

2011-09-15 Thread Simon Urbanek
Jim, ok, now we're getting somewhere ;) The most important details are a) Linux b) small allocations. The answer is that Linux cannot release the memory due to the way its allocator works - it's not your fault. This has been discussed in part in https://bugs.r-project.org/bugzilla3/show_bug.cgi

Re: [Rd] External pointers and an apparent memory leak

2011-09-15 Thread James Bullard
Hi Simon, Matt First, thank you for the help. My memory is still growing and it is clear that I'm removing the things I am allocating - potentially it is just Linux not giving back the memory until another process needs it, but it definitely doesn't behave that way when I allocate directly with

Re: [Rd] External pointers and an apparent memory leak

2011-09-15 Thread Simon Urbanek
Jim, On Sep 14, 2011, at 5:21 PM, James Bullard wrote: > I'm using external pointers and seemingly leaking memory. My determination of > a memory leak is that the R process continually creeps up in memory as seen > by top while the usage as reported by gc() stays flat. I have isolated the C >

Re: [Rd] External pointers and an apparent memory leak

2011-09-15 Thread Matt Shotwell
James, Works for me! In a file, 'test.c', I have: void h5R_allocate_finalizer(SEXP eptr) { char* vector = (char*) R_ExternalPtrAddr(eptr); free(vector); printf("memory freed at address %lu\n", (long unsigned) vector); R_ClearExternalPtr(eptr); } SEXP h5R_allocate(SEXP size) {

[Rd] External pointers and an apparent memory leak

2011-09-15 Thread James Bullard
I'm using external pointers and seemingly leaking memory. My determination of a memory leak is that the R process continually creeps up in memory as seen by top while the usage as reported by gc() stays flat. I have isolated the C code: void h5R_allocate_finalizer(SEXP eptr) { Rprintf("Calli

[Rd] S4 method dispatch

2011-09-15 Thread Edzer Pebesma
List, In order to get rid of some old, unreadable S3 code in package sp, I'm trying to rewrite things using S4 methods. Somewhere I fail, and I cannot sort out why. In order to isolate the problem, I created two functions, doNothing<- and dosth, and both should do nothing. The issue is that in mos

Re: [Rd] Revision of shell.exec?

2011-09-15 Thread Stephen Weston
2011/9/14 Uwe Ligges : > > > On 14.09.2011 12:27, Brian Oney wrote: >> >> Hi List, >> I hope this is correct list to propose function extensions, sorry if not. >> I am preparing for a (hopefully painless) migration to linux. As far as >> I am aware of, the function "shell.exec" only comes with the

Re: [Rd] Revision of shell.exec?

2011-09-15 Thread Duncan Murdoch
On 11-09-15 4:27 AM, Uwe Ligges wrote: On 14.09.2011 22:15, Brian Oney wrote: Hi there, new idea (at 10 at night). All the emails keep me thinking (btw thanks for all the feedback). What does this do on linux? getOption("pdfviewer") ### I got this idea from: getS3method("print","vignette") O

Re: [Rd] Revision of shell.exec?

2011-09-15 Thread Uwe Ligges
On 14.09.2011 22:15, Brian Oney wrote: Hi there, new idea (at 10 at night). All the emails keep me thinking (btw thanks for all the feedback). What does this do on linux? getOption("pdfviewer") ### I got this idea from: getS3method("print","vignette") On windows, (an advantage...) somebody wr