diff --git a/inst/tests/tests.Rraw b/inst/tests/tests.Rraw index 078a7d173..405ccd0a0 100644 --- a/inst/tests/tests.Rraw +++ b/inst/tests/tests.Rraw @@ -14366,7 +14366,7 @@ test(2002.12, rbind(DT1, DT2, idcol='id'), data.table(id=integer(), a=logica #rbindlist coverage test(2003.1, rbindlist(list(), use.names=1), error="use.names= should be TRUE, FALSE, or not used [(]\"check\" by default[)]") -test(2003.2, rbindlist(list(), fill=1), error="fill= should be TRUE or FALSE") +test(2003.2, rbindlist(list(), fill=1), error="fill should be TRUE or FALSE") test(2003.3, rbindlist(list(data.table(a=1:2), data.table(b=3:4)), fill=TRUE, use.names=FALSE), data.table(a=c(1:4))) test(2003.4, rbindlist(list(data.table(a=1:2,c=5:6), data.table(b=3:4)), fill=TRUE, use.names=FALSE), diff --git a/src/fastmean.c b/src/fastmean.c index 2fcc6ebd2..1c9b3eb64 100644 --- a/src/fastmean.c +++ b/src/fastmean.c @@ -36,7 +36,7 @@ SEXP fastmean(SEXP args) if (length(args)>2) { tmp = CADDR(args); if (!isLogical(tmp) || LENGTH(tmp)!=1 || LOGICAL(tmp)[0]==NA_LOGICAL) - error(_("narm should be TRUE or FALSE")); // # nocov ; [.data.table should construct the .External call correctly + error(_("%s should be TRUE or FALSE"), "narm"); // # nocov ; [.data.table should construct the .External call correctly narm=LOGICAL(tmp)[0]; } PROTECT(ans = allocNAVector(REALSXP, 1)); diff --git a/src/nafill.c b/src/nafill.c index 03aa6d091..5fe81933d 100644 --- a/src/nafill.c +++ b/src/nafill.c @@ -100,7 +100,7 @@ SEXP nafillR(SEXP obj, SEXP type, SEXP fill, SEXP nan_is_na_arg, SEXP inplace, S bool binplace = LOGICAL(inplace)[0]; if (!IS_TRUE_OR_FALSE(nan_is_na_arg)) - error(_("nan_is_na must be TRUE or FALSE")); // # nocov + error(_("%s must be TRUE or FALSE"), "nan_is_na"); // # nocov bool nan_is_na = LOGICAL(nan_is_na_arg)[0]; SEXP x = R_NilValue; diff --git a/src/rbindlist.c b/src/rbindlist.c index ba19d2c38..d8cd32476 100644 --- a/src/rbindlist.c +++ b/src/rbindlist.c @@ -5,7 +5,7 @@ SEXP rbindlist(SEXP l, SEXP usenamesArg, SEXP fillArg, SEXP idcolArg) { if (!isLogical(fillArg) || LENGTH(fillArg) != 1 || LOGICAL(fillArg)[0] == NA_LOGICAL) - error(_("fill= should be TRUE or FALSE")); + error(_("%s should be TRUE or FALSE"), "fill"); if (!isLogical(usenamesArg) || LENGTH(usenamesArg)!=1) error(_("use.names= should be TRUE, FALSE, or not used (\"check\" by default)")); // R levels converts "check" to NA if (!length(l)) return(l);