Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 2fb9ab7

Browse filesBrowse files
author
Arthur Ozga
committed
repond to feedback
1 parent c1d466a commit 2fb9ab7
Copy full SHA for 2fb9ab7

3 files changed

+2-3Lines changed: 2 additions & 3 deletions

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎src/compiler/checker.ts‎

Copy file name to clipboardExpand all lines: src/compiler/checker.ts
-1Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,6 @@ namespace ts {
110110
getParameterType: getTypeAtPosition,
111111
getReturnTypeOfSignature,
112112
getNonNullableType,
113-
getBaseTypeVariableOfClass,
114113
typeToTypeNode: nodeBuilder.typeToTypeNode,
115114
indexInfoToIndexSignatureDeclaration: nodeBuilder.indexInfoToIndexSignatureDeclaration,
116115
signatureToSignatureDeclaration: nodeBuilder.signatureToSignatureDeclaration,
Collapse file

‎src/compiler/types.ts‎

Copy file name to clipboardExpand all lines: src/compiler/types.ts
-1Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2530,7 +2530,6 @@ namespace ts {
25302530
*/
25312531
/* @internal */ getParameterType(signature: Signature, parameterIndex: number): Type;
25322532
getNonNullableType(type: Type): Type;
2533-
/* @internal */ getBaseTypeVariableOfClass(symbol: Symbol): Type | undefined;
25342533

25352534
/** Note that the resulting nodes cannot be checked. */
25362535
typeToTypeNode(type: Type, enclosingDeclaration?: Node, flags?: NodeBuilderFlags): TypeNode;
Collapse file

‎src/services/codefixes/fixAddMissingMember.ts‎

Copy file name to clipboardExpand all lines: src/services/codefixes/fixAddMissingMember.ts
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@ namespace ts.codefix {
4949
const symbol = leftExpressionType.symbol;
5050
if (symbol.flags & SymbolFlags.Class) {
5151
classDeclaration = symbol.declarations && <ClassLikeDeclaration>symbol.declarations[0];
52-
if (getObjectFlags(leftExpressionType) & ObjectFlags.Anonymous && symbol.flags & SymbolFlags.Class && !checker.getBaseTypeVariableOfClass(symbol)) {
52+
if (leftExpressionType !== checker.getDeclaredTypeOfSymbol(symbol)) {
53+
// The expression is a class symbol but the type is not the instance-side.
5354
makeStatic = true;
5455
}
5556
}

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.