fix(50551): Destructuring assignment with var bypasses "variable is used before being assigned" check (2454) - #50560
Conversation
|
TypeScript Bot (@typescript-bot) test this |
|
Heya Daniel Rosenwasser (@DanielRosenwasser), I've started to run the diff-based user code test suite on this PR at f279dd5. You can monitor the build here. |
|
Heya Daniel Rosenwasser (@DanielRosenwasser), I've started to run the diff-based user code test suite on this PR at f279dd5. You can monitor the build here. Update: The results are in! |
|
Heya Daniel Rosenwasser (@DanielRosenwasser), I've started to run the perf test suite on this PR at f279dd5. You can monitor the build here. Update: The results are in! |
|
Heya Daniel Rosenwasser (@DanielRosenwasser), I've started to run the extended test suite on this PR at f279dd5. You can monitor the build here. |
|
Daniel Rosenwasser (@DanielRosenwasser) Here are the results of running the user test suite comparing Something interesting changed - please have a look. Details
|
|
Heya Daniel Rosenwasser (@DanielRosenwasser), I've run the RWC suite on this PR - assuming you're on the TS core team, you can view the resulting diff here. |
|
Looks like this breaks valid code and needs some other checks as well. Why this was condition was accounted for, but not tested, is surprising. So we need a test like declare const obj: { a?: string, b?: number };
const {
a = "0",
b = +a,
} = obj;This should not trigger an error. |
|
Daniel Rosenwasser (@DanielRosenwasser) Here they are:
CompilerComparison Report - main..50560
System
Hosts
Scenarios
TSServerComparison Report - main..50560
System
Hosts
Scenarios
Developer Information: |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Gabriela Araujo Britto (gabritto)
left a comment
There was a problem hiding this comment.
Still trying to figure out what is going on in the checker code to give more precise feedback, but for now maybe you know how to get rid of the error that shouldn't be there that I commented below.
|
TypeScript Bot (@typescript-bot) user test this |
|
Heya Gabriela Araujo Britto (@gabritto), I've started to run the diff-based user code test suite on this PR at a6e5486. You can monitor the build here. Update: The results are in! |
|
Gabriela Araujo Britto (@gabritto) Here are the results of running the user test suite comparing Everything looks good! |
|
TypeScript Bot (@typescript-bot) test this |
|
Heya Gabriela Araujo Britto (@gabritto), I've started to run the diff-based top-repos suite on this PR at 7074198. You can monitor the build here. Update: The results are in! |
|
Heya Gabriela Araujo Britto (@gabritto), I've started to run the extended test suite on this PR at 7074198. You can monitor the build here. |
|
Heya Gabriela Araujo Britto (@gabritto), I've started to run the diff-based user code test suite on this PR at 7074198. You can monitor the build here. Update: The results are in! |
|
Heya Gabriela Araujo Britto (@gabritto), I've started to run the perf test suite on this PR at 7074198. You can monitor the build here. Update: The results are in! |
Gabriela Araujo Britto (gabritto)
left a comment
There was a problem hiding this comment.
Thanks!
|
Let's see if the tests are all ok, and then we're good to merge I think. |
|
Gabriela Araujo Britto (@gabritto) Here are the results of running the user test suite comparing Everything looks good! |
|
Gabriela Araujo Britto (@gabritto) Here they are:
CompilerComparison Report - main..50560
System
Hosts
Scenarios
TSServerComparison Report - main..50560
System
Hosts
Scenarios
Developer Information: |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Gabriela Araujo Britto (@gabritto) Here are the results of running the top-repos suite comparing Everything looks good! |
|
TypeScript Bot (@typescript-bot) perf test this faster |
|
Heya Daniel Rosenwasser (@DanielRosenwasser), I've started to run the abridged perf test suite on this PR at 7074198. You can monitor the build here. Update: The results are in! |
|
Daniel Rosenwasser (@DanielRosenwasser) Here they are:Comparison Report - main..50560
System
Hosts
Scenarios
Developer Information: |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Fixes #50551