Skip to content
This repository has been archived by the owner on Mar 25, 2021. It is now read-only.

Replace node.getSourceFile(), which climbs ancestors, with the sourceFile field on a RuleWalker. #1896

Merged
merged 1 commit into from
Dec 18, 2016

Conversation

andy-hanson
Copy link
Contributor

@andy-hanson andy-hanson commented Dec 18, 2016

PR checklist

  • Addresses an existing issue: #0000
  • New feature, bugfix, or enhancement
    • Includes tests
  • Documentation update

What changes did you make?

Made a minor change for performance. getSourceFile isn't good to call repeatedly from deep within a tree, especially when the source file is already a field of the class. https://github.com/Microsoft/TypeScript/blob/master/src/compiler/utilities.ts#L153

@nchen63 nchen63 merged commit 4677686 into palantir:master Dec 18, 2016
@nchen63
Copy link
Contributor

nchen63 commented Dec 18, 2016

@andy-hanson thanks! This shares the same underlying issue as #1747

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