[R-gregmisc-users] SF.net SVN: r-gregmisc: [1256] trunk/gtools/R/assert.R
Brought to you by:
warnes
From: <wa...@us...> - 2008-04-12 19:14:11
|
Revision: 1256 http://r-gregmisc.svn.sourceforge.net/r-gregmisc/?rev=1256&view=rev Author: warnes Date: 2008-04-12 12:14:06 -0700 (Sat, 12 Apr 2008) Log Message: ----------- Assert is now deprecated in favor of base::stopifnot(), so add call to .Deprecated() to inform the user. Modified Paths: -------------- trunk/gtools/R/assert.R Modified: trunk/gtools/R/assert.R =================================================================== --- trunk/gtools/R/assert.R 2008-04-10 14:05:37 UTC (rev 1255) +++ trunk/gtools/R/assert.R 2008-04-12 19:14:06 UTC (rev 1256) @@ -1,6 +1,6 @@ ## useful function, raises an error if the FLAG expression is FALSE assert <- function( FLAG ) { - if(!all(FLAG)) - stop("Failed Assertion") + .Deprecated(new="stopifnot", package="base") + stopifnot(FLAG) } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |