File tree Expand file tree Collapse file tree 1 file changed +5
-8
lines changed Expand file tree Collapse file tree 1 file changed +5
-8
lines changed Original file line number Diff line number Diff line change @@ -4705,18 +4705,15 @@ namespace ts {
4705
4705
return undefined ;
4706
4706
}
4707
4707
if ( declaration . kind === SyntaxKind . BinaryExpression ) {
4708
- const kind = getSpecialPropertyAssignmentKind ( declaration as BinaryExpression ) ;
4709
- const lhs = ( declaration as BinaryExpression ) . left ;
4710
- switch ( kind ) {
4711
- case SpecialPropertyAssignmentKind . None :
4712
- case SpecialPropertyAssignmentKind . ModuleExports :
4713
- return undefined ;
4708
+ const expr = declaration as BinaryExpression ;
4709
+ switch ( getSpecialPropertyAssignmentKind ( expr ) ) {
4714
4710
case SpecialPropertyAssignmentKind . ExportsProperty :
4715
4711
case SpecialPropertyAssignmentKind . ThisProperty :
4716
4712
case SpecialPropertyAssignmentKind . Property :
4717
- return ( lhs as PropertyAccessExpression ) . name ;
4718
4713
case SpecialPropertyAssignmentKind . PrototypeProperty :
4719
- return ( ( lhs as PropertyAccessExpression ) . expression as PropertyAccessExpression ) . name ;
4714
+ return ( expr . left as PropertyAccessExpression ) . name ;
4715
+ default :
4716
+ return undefined ;
4720
4717
}
4721
4718
}
4722
4719
else {
You can’t perform that action at this time.
0 commit comments