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

Fix usage of C level format token #1897

Merged
merged 2 commits into from
Dec 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# vctrs (development version)

* Internal changes requested by CRAN around C level format strings (#1896).

* Fixed tests related to changes to `dim<-()` in R-devel (#1889).

# vctrs 0.6.4
Expand Down
2 changes: 1 addition & 1 deletion src/altrep-rle.c
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ Rboolean altrep_rle_Inspect(SEXP x,
int deep,
int pvec,
void (*inspect_subtree)(SEXP, int, int, int)) {
Rprintf("vctrs_altrep_rle (len=%d, materialized=%s)\n",
Rprintf("vctrs_altrep_rle (len=%" R_PRIdXLEN_T ", materialized=%s)\n",
altrep_rle_Length(x),
R_altrep_data2(x) != R_NilValue ? "T" : "F");
return TRUE;
Expand Down
10 changes: 10 additions & 0 deletions src/vctrs-core.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,5 +108,15 @@ enum vctrs_dbl dbl_classify(double x);

#define VECTOR_PTR_RO(x) ((const SEXP*) DATAPTR_RO(x))

// Likely supplied in R 4.4.0
// https://github.com/wch/r-source/commit/38403c9c347dd5426da6009573b087188ec6be04
#ifndef R_PRIdXLEN_T
# ifdef LONG_VECTOR_SUPPORT
# define R_PRIdXLEN_T "td"
# else
# define R_PRIdXLEN_T "d"
# endif
#endif


#endif