From ripley at stats.ox.ac.uk  Mon Feb  9 07:18:56 2009
From: ripley at stats.ox.ac.uk (Prof Brian Ripley)
Date: Mon, 9 Feb 2009 06:18:56 +0000 (GMT)
Subject: [Rd] Where's code for binding values to formal arguments in
 functions?
In-Reply-To: <a0428ec90902081946y1298d8d5i9bd4dc4acb8e57ca@mail.gmail.com>
References: <a0428ec90902081946y1298d8d5i9bd4dc4acb8e57ca@mail.gmail.com>
Message-ID: <alpine.LFD.2.00.0902090613420.12998@gannet.stats.ox.ac.uk>

Have you studied d the R-ints manual?

It is a complex process, since in fact it is promises which are bound. 
The code for that is in match.c: matchArgs.

In general, you will not find people willing to read the source code 
for you, and especially if you give no reason for your 'wants'.

On Sun, 8 Feb 2009, Yi Zhang wrote:

> Hello,
>
> Can anyone give me a pointer where to find the implementation code for
> binding values to formal arguments in functions? For example, if we
> have a function f <- function(x,y)... and f(1,2) is called, I want to
> find the code that binds 1 to x when evaluating f(1,2). I tried eval.c
> but it's too long and I was lost... Thanks!
>
> -- 
> Yi

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



[Rd] Where's code for binding values to formal arguments in functions?
Prof Brian Ripley