SCM

SCM Repository

[inlinedocs] Diff of /pkg/inlinedocs/R/parsers.R
ViewVC logotype

Diff of /pkg/inlinedocs/R/parsers.R

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 246, Thu Apr 7 13:21:39 2011 UTC revision 248, Thu Apr 7 13:54:54 2011 UTC
# Line 895  Line 895 
895    old <- options(keep.source=TRUE,topLevelEnvironment=e)    old <- options(keep.source=TRUE,topLevelEnvironment=e)
896    on.exit(options(old))    on.exit(options(old))
897    exprs <- parse(text=code)    exprs <- parse(text=code)
898      ## TDH 2011-04-07 set this so that no warnings about creating a fake
899      ## package when we try to process S4 classes defined in code
900      e$.packageName <- "inlinedocs.processor"
901    for (i in exprs){    for (i in exprs){
902      tryCatch(eval(i, e),error=function(e){      ## TDH 2011-04-07 Disable this tryCatch since it makes it harder
903        ##to debug errors/warnings in the evaluated code
904    
905        ##tryCatch({
906          eval(i, e)
907        ##},error=function(e){
908        ##print(e)        ##print(e)
909      })      ##})
910    }    }
911    objs <- sapply(ls(e),get,e,simplify=FALSE)    objs <- sapply(ls(e),get,e,simplify=FALSE)
912    
# Line 954  Line 962 
962    apply.parsers(readLines(f),parsers,verbose=FALSE,...)    apply.parsers(readLines(f),parsers,verbose=FALSE,...)
963  },ex=function(){  },ex=function(){
964    f <- system.file("silly","R","silly.R",package="inlinedocs")    f <- system.file("silly","R","silly.R",package="inlinedocs")
965    extract.docs.file(f) ##FIXME: warning    extract.docs.file(f)
966  })  })
967    

Legend:
Removed from v.246  
changed lines
  Added in v.248

R-Forge@R-project.org
ViewVC Help
Powered by ViewVC 1.0.0  
Thanks to:
Vienna University of Economics and Business University of Wisconsin - Madison Powered By FusionForge