-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Code sanitising: type checks #5209
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
TODO: |
Merge branch 'main' into type_checks # Conflicts: # DESCRIPTION # R/geom-.R
I'm putting this PR on hold pending the release of rlang 1.1.0, which is required for the imported functions. |
I think this PR is now ready for review, but should wait with merging until rlang 1.1.0 has landed on CRAN |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM - have you checked that all checks are covered by unit tests (they should as I went through this when updating the errors before last minor release but better check again
hopefully rlang will be released this week |
I'll double-check this later today |
rlang 1.1.0 is now on CRAN |
This PR aims to fix #4834.
It replaces checks of the type
is.myclass(x) && length(x) == 1
by {rlang} scalar checks. There was no function for scalar numeric checks, so I added one.