Skip to content

Commit

Permalink
- num() requires an integerish digits argument (#362).
Browse files Browse the repository at this point in the history
Closes #362.
  • Loading branch information
krlmlr committed Oct 17, 2021
1 parent 94e9e61 commit 917f280
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions R/num.R
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ num <- function(x, ...,
extra_sigfig = NULL) {

stopifnot(is.numeric(x))
stopifnot(is.null(digits) || is_integerish(digits))
check_dots_empty()

# FIXME: math and arith should also work for integers
Expand Down

0 comments on commit 917f280

Please sign in to comment.