Skip to content

fix detection if an aesthetic is calculated #935

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

Closed
wants to merge 2 commits into from
Closed

fix detection if an aesthetic is calculated #935

wants to merge 2 commits into from

Conversation

krlmlr
Copy link
Member

@krlmlr krlmlr commented Mar 23, 2014

  • variables can also appear as part of an expression
    • detection of identifier limits is performed using lookarounds and Perl
      regular expressions
  • fix glitch in character range
  • remove unneeded local variable
  • add test

Improves #917.

Kirill Müller added 2 commits March 24, 2014 00:10
- variables can also appear as part of an expression
  - detection of identifier limits is performed using lookarounds and Perl regular expressions
- fix glitch in character range
- remove unneeded local variable

# Determine if aesthetic is calculated
is_calculated_aes <- function(aesthetics) {
stats <- rep(FALSE, length(aesthetics))
grepl(.calculated_aes_regex, sapply(aesthetics, deparse))
Copy link
Member

Choose a reason for hiding this comment

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

Since aesthetics is a call/name, might be better to do a little computing on the language here, rather than using a complicated regexp.

@hadley hadley closed this in 5871957 Mar 24, 2014
@lock
Copy link

lock bot commented Jan 19, 2019

This old issue has been automatically locked. If you believe you have found a related problem, please file a new issue (with reprex) and link to this issue. https://reprex.tidyverse.org/

@lock lock bot locked and limited conversation to collaborators Jan 19, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants