JS: Relax instantiation requirement for .prototype field#1050
Merged
semmle-qlci merged 4 commits intoMar 7, 2019
Conversation
xiemaisi
previously approved these changes
Mar 7, 2019
xiemaisi
reviewed
Mar 7, 2019
| @@ -49,7 +49,6 @@ AbstractValue getAnInitialPropertyValue(DefiniteAbstractValue baseVal, string pr | |||
| or | |||
| // `f.prototype` for functions `f` that are instantiated | |||
There was a problem hiding this comment.
Hang on, this comment still needs updating.
xiemaisi
approved these changes
Mar 7, 2019
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Allows tracking of values through the
.prototypeproperty of a function, even if we can't see a constructor invocation of that function.Evaluation shows a new result, and also indicates that there is a modest cost to doing this. The cost is spread across all of the taint-tracking queries, suggesting that this is simply because the call graph is more complete now, and not because it takes a longer time to construct the call graph.
I'd like to get this into 1.20 as it is needed at a client, and can't easily be handled without modifying the standard libraries.