argument PACKAGE in .C/.Fortran

Prof Brian D Ripley ripley@stats.ox.ac.uk
Fri, 24 Sep 1999 15:50:07 +0100 (BST)


One problem with linking compiled code is getting the symbol from the right
shared library/DLL (hereafter DLL). This actually happened to Guido
Masarotto recently: both leaps and ts had "ss", and leaps got ts's
version (and thereby crashed R).

We have added an argument PACKAGE to .C, .Fortran, .Call and .External,
which confines the symbol search to the named DLL (name without extension).
This in today's R-release, but it is backwards compatible if used as the
last argument (one surplus argument does no harm).  We would like to
encourage package writers to make use of it: R's own code now does.

For future reference, especially for porting projects, tomorrow's version
of R-release also allows passing float/REAL arguments to and from
.C/.Fortran, and has handling of Fortran character strings that
actually works on all the systems I have access to.

Brian Ripley

-- 
Brian D. Ripley,                  ripley@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 272860 (secr)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595

-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._