Skip to content
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

Use Rf_isCharASCII for IS_ASCII instead of testing LEVELS on R >= 4.5 #6422

Draft
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

aitap
Copy link
Contributor

@aitap aitap commented Aug 28, 2024

This part is split from #6420 (but includes #6420; can rebase if needed) because the R version containing Rf_isCharASCII is not currently released. The overall issue is #6180. Not yet sure how to change NEWS.md in case we're expecting data.table releases in the meantime.

Since data.table now depends on R >= 3.3, the backports are no longer
needed. Moreover, MAYBE_SHARED is currently a function, while
MAYBE_REFERENCED expands to !NO_REFERENCES (which is a function).

In debugging output, show MAYBE_REFERENCED (NAMED > 0) instead of NAMED.
getCharCE appeared in R-2.7, making it possible to check for strings
_marked_ as UTF-8 or Latin-1.

There is no marking as ASCII, so fixing IS_ASCII will have to wait for R
>= 4.5.
There's no explicit encoding code for ASCII, so use charIsASCII()
("eapi", expected to appear in R-4.5.0).
Copy link

github-actions bot commented Aug 28, 2024

Comparison Plot

Generated via commit b409a40

Download link for the artifact containing the test results: ↓ atime-results.zip

Time taken to finish the standard R installation steps: 11 minutes and 31 seconds

Time taken to run atime::atime_pkg on the tests: 5 minutes and 49 seconds

@MichaelChirico
Copy link
Member

Not yet sure how to change NEWS.md in case we're expecting data.table releases in the meantime.

Don't mind that, we maintainers will take care of it :)

NEWS.md Outdated Show resolved Hide resolved
@MichaelChirico MichaelChirico changed the base branch from master to nonapi_b_gone August 28, 2024 16:39
@MichaelChirico
Copy link
Member

set #6420 as the target of this PR to make the chain clearer

Base automatically changed from nonapi_b_gone to master August 28, 2024 16:42
Copy link
Member

@HughParsonage HughParsonage left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it an issue that the pre 4.5.0 version returns 1 or 0 whereas the new version returns an Rboolean?

@aitap
Copy link
Contributor Author

aitap commented Aug 29, 2024 via email

@MichaelChirico MichaelChirico marked this pull request as draft September 12, 2024 03:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants