Skip to content

Fixed memory leak when using '--watch' flag.#367

Merged
DanielRosenwasser merged 3 commits into
masterfrom
theDisintegrationOfThePersistenceOfMemory
Aug 6, 2014
Merged

Fixed memory leak when using '--watch' flag.#367
DanielRosenwasser merged 3 commits into
masterfrom
theDisintegrationOfThePersistenceOfMemory

Conversation

@DanielRosenwasser
Copy link
Copy Markdown
Member

We were actually nesting closure environments with each new getSourceFile. Instead we now just aggregate the source files into a map.

Fixes #366.

As I initially feared, we were actually nesting closure environments with each new `getSourceFile`.

Fixes #366.
Comment thread src/compiler/tc.ts Outdated
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

One could even imagine filtering out the changed files from this list, and I'll totally do that if everyone else feels it would be appropriate tomorrow.

@vladima
Copy link
Copy Markdown
Contributor

vladima commented Aug 6, 2014

LGTM

Comment thread src/compiler/tc.ts Outdated
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

this seems highly unnecessary, esp. as you overwrite 'program' just a few lines later.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

+1, this looks redundant

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

You're right; releasing doesn't seem to have a noticeable effect on memory footprint from what I can tell anyway.

@sheetalkamat
Copy link
Copy Markdown
Member

👍

DanielRosenwasser added a commit that referenced this pull request Aug 6, 2014
…nceOfMemory

Fixed memory leak when using '--watch' flag.
@DanielRosenwasser DanielRosenwasser merged commit 893940c into master Aug 6, 2014
@DanielRosenwasser DanielRosenwasser deleted the theDisintegrationOfThePersistenceOfMemory branch August 6, 2014 23:28
@microsoft microsoft locked and limited conversation to collaborators Jun 18, 2018
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.

'--watch' flag seems to have a leak

4 participants