tidyverse / vroom

Fast reading of delimited files
https://vroom.r-lib.org
Other
621 stars 60 forks source link

Avoid implicit conversion from `sexp` to `bool` #543

Closed DavisVaughan closed 3 months ago

DavisVaughan commented 3 months ago

cpp11 allows some somewhat scary implicit conversions between sexp and the 3 types bool, size_t, and double. These are unchecked conversions, and we'd like to remove them: https://github.com/r-lib/cpp11/pull/390/

The recommended way is to use cpp11::as_cpp<bool>(), which checks the type and length before performing the conversion.

I'm not going to remove these in this version of cpp11, but we will in the next