We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Will be closed by #488 after Gabor merges r-lib/cli#727 cc @wurli
The text was updated successfully, but these errors were encountered:
A new version of cli was released and the PR was not considered, this looks like it could take forever or even be rejected.
Better to just patch it in constructive itself. I think something like this is safe:
# In code code_highlight <- NULL # In .onLoad code_highlight <- cli::code_highlight environment(code_highlight) <- rlang::new_environment( data = list(getParseData = get_parse_data) parent = environment(cli::code_highlight) ) code_highlight <<- code_highlight
Or a bit less efficient but without polluting .onLoad :
code_highlight_fixed <- function(...) { code_highlight <- cli::code_highlight environment(code_highlight) <- rlang::new_environment( data = list(getParseData = get_parse_data) parent = environment(cli::code_highlight) ) code_highlight(...) }
where get_parse_data() is the function defined in the PR but slightly modified to have the same args as getParseData() so no code using it will break.
get_parse_data()
getParseData()
We could also do something with rlang::local_bindings() but that's more invasive, we'll need to unlock bindings and I think CRAN doesn't like that.
rlang::local_bindings()
We need the tests as well, we can copy them but use construct() rather than code_highlight()
construct()
code_highlight()
Sorry, something went wrong.
No branches or pull requests
Will be closed by #488 after Gabor merges r-lib/cli#727 cc @wurli
The text was updated successfully, but these errors were encountered: