Skip to content

Conversation

xiemaisi
Copy link

Fixes https://discuss.lgtm.com/t/false-positive-in-preact/1348.

The actual fix is in the first commit and involves a minor rearrangement so we don't assume VarDef.getSource() is always defined (because it isn't).

Once I had that in, LocalFunction started acting up with a very expensive antijoin_rhs. I have no idea why that suddenly became a problem, but the second commit refactors things to fix it.

Overall, there is no performance overhead (in fact, the second commit gives us a speedup on some projects), and results are unchanged except for the reported FP in preact, which I'm adding to our default benchmark suite. Given the fact that I wasn't able to find a single other change in results, I think we can skip a change note.

@xiemaisi xiemaisi requested a review from a team as a code owner October 12, 2018 12:07
@ghost ghost added the JS label Oct 12, 2018
ghost
ghost previously approved these changes Oct 12, 2018
Copy link

@ghost ghost left a comment

Choose a reason for hiding this comment

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

LGTM

@xiemaisi
Copy link
Author

Test failure fixed; removing that override was a little reckless. I'll do a another small evaluation to make sure this doesn't mess with performance (but I think it shouldn't).

@xiemaisi xiemaisi added WIP This is a work-in-progress, do not merge yet! and removed WIP This is a work-in-progress, do not merge yet! labels Oct 16, 2018
@xiemaisi
Copy link
Author

Small evaluation on ace and node shows no major performance impact, so I consider this ready to merge (but would of course be happy to do a more extensive evaluation if desired).

@semmle-qlci semmle-qlci merged commit e319159 into github:master Oct 16, 2018
@xiemaisi xiemaisi deleted the js/odasa-7355-workaround branch October 17, 2018 08:56
aibaars pushed a commit that referenced this pull request Oct 14, 2021
smowton pushed a commit to smowton/codeql that referenced this pull request Apr 16, 2022
Adjust trap file names of external file class declarations
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants