"ifdef"'ing R/S code

Douglas Bates bates@stat.wisc.edu
26 Dec 1997 09:13:32 -0600


I should have saved the messages about this but I didn't.  Can someone
remind me of what function or object to check from within a function
to determine if you are running R?  I need to make some changes in
code according to whether I am running it under R or under S and I
would prefer to keep one source tree.

Thomas Lumley:  I read your web page on porting S code to R.  It looks
very good.  You may want to change the parts about Calloc versus
calloc for the 0.61 release.  Also, little tidbits about the changes
in the interpreted code (such as the answer to the above query) could
help.  I realize that everything is in a state of flux so such
information quickly gets out of date but who trusts a web page more
than two weeks old anyway :-)
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
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
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._