The compiler doesn't currently look beyond the first definition found
(the generated code does the right thing, but the compiler won't
optimize calls to functions masked by non-functions).  I'll look into
whether thechecking can be made to take this into account; it may be
more trouble than it is worth though.

luke

On Thu, 5 Apr 2012, Sam Steingold wrote:

* Duncan Murdoch <zheqbpu.qha...@tznvy.pbz> [2012-04-04 21:46:57 -0400]:

On 12-04-04 5:15 PM, Sam Steingold wrote:
* Duncan Murdoch<zheqbpu.qha...@tznvy.pbz>  [2012-04-04 17:00:32 -0400]:

There's no warning when you mask a function with a non-function at top
level, and little need for one, because R does the right search based on
the fact that you're making a function call:

c
[1] 1
c(1,2)
[1] 1 2

why then am I getting these warnings from cmpfile?

You would have to tell me what you did before I could attempt to answer
that.

all <- 1
cmpfile("foo.R")

where foo.R contains functions which call all()




Note: no visible global function definition for 'all'
Note: no visible global function definition for 'all'
Note: no visible global function definition for 'all'
Note: no visible global function definition for 'all'
Note: no visible global function definition for 'all'
Note: no visible global function definition for 'all'
Note: no visible global function definition for 'all'
Note: no visible global function definition for 'all'
Note: no visible global function definition for 'all'
Note: no visible global function definition for 'all'

I did overwrite all to a data frame, but it only appears in a funtion
position all(...) in the file being compiled.





--
Luke Tierney
Chair, Statistics and Actuarial Science
Ralph E. Wareham Professor of Mathematical Sciences
University of Iowa                  Phone:             319-335-3386
Department of Statistics and        Fax:               319-335-3017
   Actuarial Science
241 Schaeffer Hall                  email:   luke-tier...@uiowa.edu
Iowa City, IA 52242                 WWW:  http://www.stat.uiowa.edu

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to