Skip to content

Minor cleanups in scriptVersionCache#17021

Merged
1 commit merged into
masterfrom
scriptVersionCache_cleanup
Jul 10, 2017
Merged

Minor cleanups in scriptVersionCache#17021
1 commit merged into
masterfrom
scriptVersionCache_cleanup

Conversation

@ghost
Copy link
Copy Markdown

@ghost ghost commented Jul 7, 2017

  • Don't introduce a mutable variable just for the sake of reusing it. Use multiple immutable declarations.
  • Mark more privates private.
  • Remove unnecessary parens.

@ghost ghost requested a review from sheetalkamat July 7, 2017 21:59
@ghost ghost force-pushed the scriptVersionCache_cleanup branch from 748ba13 to 05ee42c Compare July 10, 2017 14:17
interiorNode.add(node);
charCount += node.charCount();
lineCount += node.lineCount();
nodeIndex++;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

How about you move the check of nodeIndex here.

if (nodeIndex >= nodes.length) {  
    break;  
}  

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

I'll make a separate PR for that.

@ghost ghost merged commit b8b1fb3 into master Jul 10, 2017
@ghost ghost deleted the scriptVersionCache_cleanup branch July 10, 2017 22:10
@ghost ghost mentioned this pull request Jul 11, 2017
@microsoft microsoft locked and limited conversation to collaborators Jun 14, 2018
This pull request was closed.
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