[Roxygen-commits] r147 - pkg/R

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Sat Aug 2 09:21:36 CEST 2008


Author: pcd
Date: 2008-08-02 09:21:36 +0200 (Sat, 02 Aug 2008)
New Revision: 147

Modified:
   pkg/R/callgraph.R
   pkg/R/parse.R
Log:
reasonable TODO; suppress superfluous warnings; immediate warnings with call-lists


Modified: pkg/R/callgraph.R
===================================================================
--- pkg/R/callgraph.R	2008-08-02 07:21:33 UTC (rev 146)
+++ pkg/R/callgraph.R	2008-08-02 07:21:36 UTC (rev 147)
@@ -69,11 +69,13 @@
       else {
         preorder.walk.expression(discover.subcalls,
             parse(text=src.lines(partitum)))
-        if (require(Rgraphviz, quietly=TRUE))
+        if (tryCatch(require(Rgraphviz, quietly=TRUE),
+                     warning=function(e) FALSE))
           graphviz(subcalls)
         else {
           warning(paste('Rgraphviz not present; replacing',
-                        'callgraphs with text-only call-lists.'))
+                        'callgraphs with text-only call-lists.'),
+                  immediate.=TRUE)
           text(subcalls)
         }
       }

Modified: pkg/R/parse.R
===================================================================
--- pkg/R/parse.R	2008-08-02 07:21:33 UTC (rev 146)
+++ pkg/R/parse.R	2008-08-02 07:21:36 UTC (rev 147)
@@ -2,7 +2,6 @@
 #' @include functional.R
 #' @include string.R
 #' @include list.R
-#' @TODO number parser?
 roxygen()
 
 #' Sequence that distinguishes roxygen comment from normal comment.
@@ -37,6 +36,7 @@
 }
 
 #' Preref parser table
+#' @TODO number parser?
 preref.parsers <- new.env(parent=emptyenv())
 
 #' Srcref parser table



More information about the Roxygen-commits mailing list