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(compiler): give ASTWithSource its own visit method #31347

Closed

Conversation

@ayazhafiz
Copy link
Member

commented Jun 28, 2019

ASTWithSource contains more information that AST and should have its own
visit method, if desired. This implements that.

Part 1 of template parsing refactoring for stability.

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

  • Bugfix
  • Feature
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • CI related changes
  • Documentation content changes
  • angular.io application / infrastructure changes
  • Other... Please describe:

What is the current behavior?

ASTWithSource#visit defers to AST#visit.

Issue Number: N/A

What is the new behavior?

ASTWithSource#visit has its own method if applicable, otherwise defers to AST#visit.

Does this PR introduce a breaking change?

  • Yes
  • No

Other information

@ayazhafiz ayazhafiz requested a review from angular/fw-compiler as a code owner Jun 28, 2019

@ayazhafiz ayazhafiz self-assigned this Jun 28, 2019

@ngbot ngbot bot modified the milestone: needsTriage Jun 28, 2019

@googlebot googlebot added the cla: yes label Jun 28, 2019

@ayazhafiz ayazhafiz requested a review from alxhub Jun 28, 2019

@alxhub
Copy link
Contributor

left a comment

This looks okay, but the diff is bigger than expected. Rebase needed?

ayazhafiz added some commits Jun 28, 2019

fix(compiler): give ASTWithSource its own visit method
ASTWithSource contains more information that AST and should have its own
visit method, if desired. This implements that.

@ayazhafiz ayazhafiz force-pushed the ayazhafiz:feature/ast-source-own-visitor branch from 35a992e to fcf6d54 Jul 2, 2019

@ayazhafiz

This comment has been minimized.

Copy link
Member Author

commented Jul 2, 2019

This looks okay, but the diff is bigger than expected. Rebase needed?

No; the diff is large because for whatever reason template_spec didn't receive the runInEachFileSystem wrapper that was introduced in 7186f9c. The tests fail without adding this.

@ayazhafiz ayazhafiz requested a review from alxhub Jul 2, 2019

@alxhub

alxhub approved these changes Jul 3, 2019

Copy link
Contributor

left a comment

👍

@jasonaden jasonaden closed this in 6aaca21 Jul 8, 2019

@ayazhafiz ayazhafiz deleted the ayazhafiz:feature/ast-source-own-visitor branch Jul 8, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.