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

{.val evaluation for vector vs inline expression #685

Closed
olivroy opened this issue Apr 17, 2024 · 1 comment
Closed

{.val evaluation for vector vs inline expression #685

olivroy opened this issue Apr 17, 2024 · 1 comment

Comments

@olivroy
Copy link
Contributor

olivroy commented Apr 17, 2024

Feel free to close if it's intended.

 cli::format_inline("{.val 104} and {.val {104}}") |> cat()
#> "104" and 104

Is it intended that {.val is quoted unless served with an R object?

@olivroy olivroy changed the title {.val printing {.val evaluation for vector vs inline expression Apr 17, 2024
@gaborcsardi
Copy link
Member

Strings are quoted, numbers are not. Literals are strings.

cli::cli_text("{.val 104} and {.val {104}} and {.val {'104'}}")
"104" and 104 and "104"

@olivroy olivroy closed this as completed Apr 17, 2024
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

No branches or pull requests

2 participants