Skip to contents

This version of : throws an error if from is positive and to is zero, to make the error more obvious if you've used 1:length(x) instead of seq_along()

Usage

shim_colon(from, to)

Arguments

from, to

Passed on to seq()

Examples

x <- numeric()
seq_along(x)
#> integer(0)
lax(1:length(x))
#> [1] 1 0