Skip to content

Commit a1877ef

Browse files
author
Arthur Ozga
committed
fexed comment and initialization
1 parent feb7e1d commit a1877ef

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

src/compiler/checker.ts

+4-6
Original file line numberDiff line numberDiff line change
@@ -3734,12 +3734,12 @@ namespace ts {
37343734
// We only support expressions that are simple qualified names. For other expressions this produces undefined.
37353735
let typeNameOrExpression = node.kind === SyntaxKind.TypeReference ? (<TypeReferenceNode>node).typeName :
37363736
isSupportedExpressionWithTypeArguments(<ExpressionWithTypeArguments>node) ? (<ExpressionWithTypeArguments>node).expression :
3737-
undefined;
3737+
undefined;
37383738
let symbol = typeNameOrExpression && resolveEntityName(typeNameOrExpression, SymbolFlags.Type) || unknownSymbol;
37393739
let type = symbol === unknownSymbol ? unknownType :
37403740
symbol.flags & (SymbolFlags.Class | SymbolFlags.Interface) ? getTypeFromClassOrInterfaceReference(node, symbol) :
3741-
symbol.flags & SymbolFlags.TypeAlias ? getTypeFromTypeAliasReference(node, symbol) :
3742-
getTypeFromNonGenericTypeReference(node, symbol);
3741+
symbol.flags & SymbolFlags.TypeAlias ? getTypeFromTypeAliasReference(node, symbol) :
3742+
getTypeFromNonGenericTypeReference(node, symbol);
37433743
// Cache both the resolved symbol and the resolved type. The resolved symbol is needed in when we check the
37443744
// type reference in checkTypeReferenceOrExpressionWithTypeArguments.
37453745
links.resolvedSymbol = symbol;
@@ -4641,8 +4641,6 @@ namespace ts {
46414641
let sourceProp = getPropertyOfType(source, targetProp.name);
46424642

46434643
if (sourceProp !== targetProp) {
4644-
// sourceProp !== targetProp -- ie: source and target have distinct declarations with the same name
4645-
46464644
if (!sourceProp) {
46474645
if (!(targetProp.flags & SymbolFlags.Optional) || requireOptionalProperties) {
46484646
if (reportErrors) {
@@ -7216,7 +7214,7 @@ namespace ts {
72167214
}
72177215

72187216
if (flags & NodeFlags.Abstract) {
7219-
// A method cannot be accessed in a super call if the method is abstract.
7217+
// A method cannot be accessed in a super property access if the method is abstract.
72207218
// This error could mask a private property access error. But, a member
72217219
// cannot simultaneously be private and abstract, so this will trigger an
72227220
// additional error elsewhere.

0 commit comments

Comments
 (0)