Re: [Rd] Rd2dvi (PR#9812)

From: <ripley_at_stats.ox.ac.uk>
Date: Fri, 27 Jul 2007 13:30:59 +0200 (CEST)


It seems this feature was introduced in Perl 5.6.1, but that is older than Solaris 9 (which was first released 9/02 according to www.sun.com).

We need to know what version of Perl this was.

On Thu, 26 Jul 2007, Bill Dunlap wrote:

> On Thu, 26 Jul 2007 larryh@zebra.us.udel.edu wrote:
>
>> Is this a bug--
>>
>> -------------------------------------------------------------------------------
>> <234>% R CMD Rd2dvi base.Rd
>> Converting Rd files to LaTeX ...
>> base.Rd
>> Can't use an undefined value as filehandle reference at
>> /opt/R-2.5.1/lib/R/share/perl/R/Rdconv.pm line 78.
>
> This may be due to a change I suggested a while back which
> required perl 5.6 (or so) to work. The change was to ensure
> that the file handle rdfile was closed when Rdconv was done
> with it. If this is the problem, upgrading perl to 5.8 will
> make it go away. Rdconv.pm should have a 'use v5.6' (or 5.8?)
> line at the top if it wants to continue to use this syntax.
>
> < open(rdfile, "<$Rdname") or die "Rdconv(): Couldn't open '$Rdfile': $!\n";
> <
> ---
>> open(my $rdfile, "<$Rdname") or die "Rdconv(): Couldn't open '$Rdfile': $!\n";
>> # Before we added the 'my $' in front of rdfile,
>> # rdfile was not getting closed. Now it will close
>> # when $rdfile goes out of scope. (We could have added
>> # a close rdfile at the end of the while(<rdfile>), but
>> # scoping method is more reliable.
> 123c127
> < while(<rdfile>){
> ---
>> while(<$rdfile>){
>
> ----------------------------------------------------------------------------
> Bill Dunlap
> Insightful Corporation
> bill at insightful dot com
> 360-428-8146
>
> "All statements in this message represent the opinions of the author and do
> not necessarily reflect Insightful Corporation policy or position."
>
> ______________________________________________
> R-devel_at_r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel
>

-- 
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

______________________________________________
R-devel_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel
Received on Fri 27 Jul 2007 - 11:33:51 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Fri 27 Jul 2007 - 20:38:25 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-devel. Please read the posting guide before posting to the list.