Skip to content

Commit e430853

Browse files
author
ripley
committed
improve reported calls on some warning messages
port C code for [dpqr]xxx functions to stats leave .Internals for now, as they are used directly as an optimization by byte-compiler git-svn-id: https://svn.r-project.org/R/trunk@59447 00db46b3-68df-0310-9c12-caf00c1e9a41
1 parent eb4e8d5 commit e430853

File tree

17 files changed

+940
-146
lines changed

17 files changed

+940
-146
lines changed

doc/NEWS.Rd

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -274,7 +274,10 @@
274274
When set to \code{TRUE}, error messages will contain the
275275
location of the most recent call containing source reference
276276
information. (Other values are supported as well; see
277-
\code{?options}.
277+
\code{?options}.
278+
279+
\item The NA warning messages from e.g. \code{pchisq} now report the
280+
call to the closure and not that of the \code{.Internal}.
278281
)
279282
}
280283
}

src/library/grDevices/R/device.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ dev.next <-
7676
{
7777
if(!exists(".Devices"))
7878
.Devices <- list("null.device")
79-
num.device <- .External(C_dev.next, as.integer(which))
79+
num.device <- .External(C_devnext, as.integer(which))
8080
names(num.device) <- .Devices[[num.device]]
8181
num.device
8282
}

src/library/stats/R/distn.R

Lines changed: 100 additions & 97 deletions
Large diffs are not rendered by default.

src/library/stats/R/runmed.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ runmed <- function(x, k, endrule = c("median","keep","constant"),
2828
if(is.na(n)) stop("invalid value of length(x)")
2929
k <- as.integer(k)
3030
if(is.na(k)) stop("invalid value of 'k'")
31-
if(k < 0) stop("'k' must be positive")
31+
if(k < 0) stop("'k' must be positive")
3232
if(k%%2 == 0)
3333
warning("'k' must be odd! Changing 'k' to ",
3434
k <- as.integer(1+ 2*(k %/% 2)))

src/library/stats/src/Makefile.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ SOURCES_C = init.c kmeans.c \
2424
mAR.c pacf.c starma.c port.c family.c sbart.c \
2525
approx.c loglin.c lowess.c massdist.c splines.c lm.c \
2626
complete_cases.c cov.c deriv.c fourier.c model.c optim.c optimize.c \
27-
integrate.c random.c
27+
integrate.c random.c distn.c
2828

2929
SOURCES_F = bsplvd.f bvalue.f bvalus.f loessf.f ppr.f qsbart.f \
3030
sgram.f sinerp.f sslvrg.f stxwx.f \

src/library/stats/src/Makefile.win

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ SOURCES_C = init.c kmeans.c \
2222
mAR.c pacf.c starma.c port.c family.c sbart.c \
2323
approx.c loglin.c lowess.c massdist.c splines.c lm.c \
2424
complete_cases.c cov.c deriv.c fourier.c model.c optim.c optimize.c \
25-
integrate.c random.c
25+
integrate.c random.c distn.c
2626

2727
SOURCES_F = bsplvd.f bvalue.f bvalus.f loessf.f ppr.f qsbart.f \
2828
sgram.f sinerp.f sslvrg.f stxwx.f \

0 commit comments

Comments
 (0)