[Rd] sys.on.exit not working (PR#7665)
Prof Brian Ripley
ripley at stats.ox.ac.uk
Mon Feb 7 15:23:40 CET 2005
It is working as documented: there is no on.exit set for str, is there?
'sys.on.exit()' retrieves the expression stored for use by
'on.exit' in the function currently being evaluated. (Note that
^^^^^^^^^^^^^^^^^^^^^^^^^
this differs from S, which returns a list of expressions for the
current frame and its parents.)
I see you have looked at PR#269, but did not notice the crucial
difference: here the current function is str (it is evaluating its
arguments), not soe.test.
On Mon, 7 Feb 2005 mark.bravington at csiro.au wrote:
> Full_Name: Mark Bravington
> Version: 2.0.1
> OS: Windows XP
> Submission from: (NULL) (140.79.22.104)
>
>
> 'sys.on.exit()' doesn't seem to be working, since R1.7.1 at least:
Please read the FAQ: we don't want R-bugs clogged up with `doesn't seem to
be working' reports, and we do say so.
> soe.test <- function() {
> on.exit( cat( 'In exit code\n'))
> str( sys.on.exit()) # should display "language..." I think
> 12
> }
>
> (A similar bug was apparently fixed for version 0.65!)
One difference being that PR#269 was a bug, and this is not.
--
Brian D. Ripley, ripley at stats.ox.ac.uk
Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/
University of Oxford, Tel: +44 1865 272861 (self)
1 South Parks Road, +44 1865 272866 (PA)
Oxford OX1 3TG, UK Fax: +44 1865 272595
More information about the R-devel
mailing list