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

(GH416) Wrong arrow alignment when key has interpolated variable #497

Closed
wants to merge 1 commit into from
Closed

(GH416) Wrong arrow alignment when key has interpolated variable #497

wants to merge 1 commit into from

Conversation

rnelson0
Copy link
Collaborator

Ensure that interpolated variable delimiters (${}) are not ignored when calculating alignment.
The --fix function remains broken, see #424 for progress on that front.

@rnelson0
Copy link
Collaborator Author

Fixes #416, needs review.

@rnelson0
Copy link
Collaborator Author

rnelson0 commented Jul 7, 2016

@ahpook @binford2k @kylog This is ready for review now. In #416, two users confirmed no adverse side effects with this branch on their code, in addition to the spec tests working (I'm not sure why the push fails, but it's related to travis ci git magic, NOT the code - works fine on pr).

@@ -362,7 +362,7 @@ def interpolate_string(string, line, column)
lexer.tokens.each do |token|
tok_col = column + token.column + (ss.pos - contents.size - 1)
tok_line = token.line + line - 1
tokens << new_token(token.type, token.value, token.value.size, :line => tok_line, :column => tok_col)
tokens << new_token(token.type, token.value, token.value.size + 3, :line => tok_line, :column => tok_col)
Copy link
Collaborator

Choose a reason for hiding this comment

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

What does this do on a line w/o the curlies? e.g., "A double quoted $string without properly bracketed variables"

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Ugh, it does not work properly. However I think #492 will give us a better grasp on the issue to debug it.

Copy link
Collaborator

Choose a reason for hiding this comment

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

So we are still waiting to merge this one, correct?

  Ensure that interpolated variable delimiters (`${}`) are not ignored when calculating alignment.
  The `--fix` function remains broken, see #424 for progress on that front.
@rnelson0
Copy link
Collaborator Author

Yep, still waiting. Im going to close it until it's ready.

@rnelson0 rnelson0 closed this Aug 18, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants