Skip to content

Commit b5f1169

Browse files
committed
Accept baselines
1 parent 3181a8d commit b5f1169

8 files changed

+19
-19
lines changed

src/compiler/checker.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2184,7 +2184,7 @@ namespace ts {
21842184
function isEntityNameVisible(entityName: EntityNameOrEntityNameExpression, enclosingDeclaration: Node): SymbolVisibilityResult {
21852185
// get symbol of the first identifier of the entityName
21862186
let meaning: SymbolFlags;
2187-
if (entityName.parent.kind === SyntaxKind.TypeQuery ||
2187+
if (entityName.parent.kind === SyntaxKind.TypeQuery ||
21882188
isExpressionWithTypeArgumentsInClassExtendsClause(entityName.parent) ||
21892189
entityName.parent.kind === SyntaxKind.ComputedPropertyName) {
21902190
// Typeof value

tests/baselines/reference/classWithDuplicateIdentifier.errors.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ tests/cases/compiler/classWithDuplicateIdentifier.ts(3,5): error TS2300: Duplica
22
tests/cases/compiler/classWithDuplicateIdentifier.ts(6,5): error TS2300: Duplicate identifier 'b'.
33
tests/cases/compiler/classWithDuplicateIdentifier.ts(7,5): error TS2300: Duplicate identifier 'b'.
44
tests/cases/compiler/classWithDuplicateIdentifier.ts(11,5): error TS2300: Duplicate identifier 'c'.
5-
tests/cases/compiler/classWithDuplicateIdentifier.ts(11,5): error TS2403: Subsequent variable declarations must have the same type. Variable 'c' must be of type 'number', but here has type 'string'.
5+
tests/cases/compiler/classWithDuplicateIdentifier.ts(11,5): error TS2711: Subsequent property declarations must have the same type. Property 'c' must be of type 'number', but here has type 'string'.
66

77

88
==== tests/cases/compiler/classWithDuplicateIdentifier.ts (5 errors) ====
@@ -26,6 +26,6 @@ tests/cases/compiler/classWithDuplicateIdentifier.ts(11,5): error TS2403: Subseq
2626
~
2727
!!! error TS2300: Duplicate identifier 'c'.
2828
~
29-
!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'c' must be of type 'number', but here has type 'string'.
29+
!!! error TS2711: Subsequent property declarations must have the same type. Property 'c' must be of type 'number', but here has type 'string'.
3030
}
3131

tests/baselines/reference/duplicateClassElements.errors.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ tests/cases/compiler/duplicateClassElements.ts(26,9): error TS2300: Duplicate id
1616
tests/cases/compiler/duplicateClassElements.ts(29,9): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
1717
tests/cases/compiler/duplicateClassElements.ts(32,9): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
1818
tests/cases/compiler/duplicateClassElements.ts(34,12): error TS2300: Duplicate identifier 'x2'.
19-
tests/cases/compiler/duplicateClassElements.ts(34,12): error TS2403: Subsequent variable declarations must have the same type. Variable 'x2' must be of type 'number', but here has type 'any'.
19+
tests/cases/compiler/duplicateClassElements.ts(34,12): error TS2711: Subsequent property declarations must have the same type. Property 'x2' must be of type 'number', but here has type 'any'.
2020
tests/cases/compiler/duplicateClassElements.ts(36,9): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
2121
tests/cases/compiler/duplicateClassElements.ts(36,9): error TS2300: Duplicate identifier 'z2'.
2222
tests/cases/compiler/duplicateClassElements.ts(39,9): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
@@ -96,7 +96,7 @@ tests/cases/compiler/duplicateClassElements.ts(41,12): error TS2300: Duplicate i
9696
~~
9797
!!! error TS2300: Duplicate identifier 'x2'.
9898
~~
99-
!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x2' must be of type 'number', but here has type 'any'.
99+
!!! error TS2711: Subsequent property declarations must have the same type. Property 'x2' must be of type 'number', but here has type 'any'.
100100

101101
get z2() {
102102
~~

tests/baselines/reference/gettersAndSettersErrors.errors.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
tests/cases/compiler/gettersAndSettersErrors.ts(2,16): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
22
tests/cases/compiler/gettersAndSettersErrors.ts(3,16): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
33
tests/cases/compiler/gettersAndSettersErrors.ts(5,12): error TS2300: Duplicate identifier 'Foo'.
4-
tests/cases/compiler/gettersAndSettersErrors.ts(5,12): error TS2403: Subsequent variable declarations must have the same type. Variable 'Foo' must be of type 'string', but here has type 'number'.
4+
tests/cases/compiler/gettersAndSettersErrors.ts(5,12): error TS2711: Subsequent property declarations must have the same type. Property 'Foo' must be of type 'string', but here has type 'number'.
55
tests/cases/compiler/gettersAndSettersErrors.ts(6,16): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
66
tests/cases/compiler/gettersAndSettersErrors.ts(7,16): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
77
tests/cases/compiler/gettersAndSettersErrors.ts(11,17): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
@@ -23,7 +23,7 @@ tests/cases/compiler/gettersAndSettersErrors.ts(12,16): error TS2379: Getter and
2323
~~~
2424
!!! error TS2300: Duplicate identifier 'Foo'.
2525
~~~
26-
!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'Foo' must be of type 'string', but here has type 'number'.
26+
!!! error TS2711: Subsequent property declarations must have the same type. Property 'Foo' must be of type 'string', but here has type 'number'.
2727
public get Goo(v:string):string {return null;} // error - getters must not have a parameter
2828
~~~
2929
!!! error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.

tests/baselines/reference/interfaceDeclaration1.errors.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ tests/cases/compiler/interfaceDeclaration1.ts(2,5): error TS2300: Duplicate iden
22
tests/cases/compiler/interfaceDeclaration1.ts(3,5): error TS2300: Duplicate identifier 'item'.
33
tests/cases/compiler/interfaceDeclaration1.ts(7,5): error TS2300: Duplicate identifier 'item'.
44
tests/cases/compiler/interfaceDeclaration1.ts(8,5): error TS2300: Duplicate identifier 'item'.
5-
tests/cases/compiler/interfaceDeclaration1.ts(8,5): error TS2403: Subsequent variable declarations must have the same type. Variable 'item' must be of type 'any', but here has type 'number'.
5+
tests/cases/compiler/interfaceDeclaration1.ts(8,5): error TS2711: Subsequent property declarations must have the same type. Property 'item' must be of type 'any', but here has type 'number'.
66
tests/cases/compiler/interfaceDeclaration1.ts(22,11): error TS2310: Type 'I5' recursively references itself as a base type.
77
tests/cases/compiler/interfaceDeclaration1.ts(35,7): error TS2420: Class 'C1' incorrectly implements interface 'I3'.
88
Property 'prototype' is missing in type 'C1'.
@@ -29,7 +29,7 @@ tests/cases/compiler/interfaceDeclaration1.ts(52,11): error TS2320: Interface 'i
2929
~~~~
3030
!!! error TS2300: Duplicate identifier 'item'.
3131
~~~~
32-
!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'item' must be of type 'any', but here has type 'number'.
32+
!!! error TS2711: Subsequent property declarations must have the same type. Property 'item' must be of type 'any', but here has type 'number'.
3333
}
3434

3535
interface I3 {

tests/baselines/reference/mergedInterfacesWithConflictingPropertyNames.errors.txt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConflictingPropertyNames.ts(6,5): error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'string', but here has type 'number'.
2-
tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConflictingPropertyNames.ts(15,9): error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'T', but here has type 'number'.
3-
tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConflictingPropertyNames.ts(39,9): error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'T', but here has type 'number'.
1+
tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConflictingPropertyNames.ts(6,5): error TS2711: Subsequent property declarations must have the same type. Property 'x' must be of type 'string', but here has type 'number'.
2+
tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConflictingPropertyNames.ts(15,9): error TS2711: Subsequent property declarations must have the same type. Property 'x' must be of type 'T', but here has type 'number'.
3+
tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConflictingPropertyNames.ts(39,9): error TS2711: Subsequent property declarations must have the same type. Property 'x' must be of type 'T', but here has type 'number'.
44

55

66
==== tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConflictingPropertyNames.ts (3 errors) ====
@@ -11,7 +11,7 @@ tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConfli
1111
interface A {
1212
x: number;
1313
~
14-
!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'string', but here has type 'number'.
14+
!!! error TS2711: Subsequent property declarations must have the same type. Property 'x' must be of type 'string', but here has type 'number'.
1515
}
1616

1717
module M {
@@ -22,7 +22,7 @@ tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConfli
2222
interface A<T> {
2323
x: number; // error
2424
~
25-
!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'T', but here has type 'number'.
25+
!!! error TS2711: Subsequent property declarations must have the same type. Property 'x' must be of type 'T', but here has type 'number'.
2626
}
2727
}
2828

@@ -48,6 +48,6 @@ tests/cases/conformance/interfaces/declarationMerging/mergedInterfacesWithConfli
4848
export interface A<T> {
4949
x: number; // error
5050
~
51-
!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'x' must be of type 'T', but here has type 'number'.
51+
!!! error TS2711: Subsequent property declarations must have the same type. Property 'x' must be of type 'T', but here has type 'number'.
5252
}
5353
}

tests/baselines/reference/numericStringNamedPropertyEquivalence.errors.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ tests/cases/conformance/types/objectTypeLiteral/propertySignatures/numericString
33
tests/cases/conformance/types/objectTypeLiteral/propertySignatures/numericStringNamedPropertyEquivalence.ts(12,5): error TS2300: Duplicate identifier '1'.
44
tests/cases/conformance/types/objectTypeLiteral/propertySignatures/numericStringNamedPropertyEquivalence.ts(16,5): error TS2300: Duplicate identifier '1'.
55
tests/cases/conformance/types/objectTypeLiteral/propertySignatures/numericStringNamedPropertyEquivalence.ts(17,5): error TS2300: Duplicate identifier '1'.
6-
tests/cases/conformance/types/objectTypeLiteral/propertySignatures/numericStringNamedPropertyEquivalence.ts(17,5): error TS2403: Subsequent variable declarations must have the same type. Variable '1.0' must be of type 'number', but here has type 'string'.
6+
tests/cases/conformance/types/objectTypeLiteral/propertySignatures/numericStringNamedPropertyEquivalence.ts(17,5): error TS2711: Subsequent property declarations must have the same type. Property '1.0' must be of type 'number', but here has type 'string'.
77
tests/cases/conformance/types/objectTypeLiteral/propertySignatures/numericStringNamedPropertyEquivalence.ts(22,5): error TS2300: Duplicate identifier '0'.
88

99

@@ -36,7 +36,7 @@ tests/cases/conformance/types/objectTypeLiteral/propertySignatures/numericString
3636
~~~
3737
!!! error TS2300: Duplicate identifier '1'.
3838
~~~
39-
!!! error TS2403: Subsequent variable declarations must have the same type. Variable '1.0' must be of type 'number', but here has type 'string'.
39+
!!! error TS2711: Subsequent property declarations must have the same type. Property '1.0' must be of type 'number', but here has type 'string'.
4040
}
4141

4242
var b = {

tests/baselines/reference/reassignStaticProp.errors.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
tests/cases/compiler/reassignStaticProp.ts(5,12): error TS2300: Duplicate identifier 'bar'.
2-
tests/cases/compiler/reassignStaticProp.ts(5,12): error TS2403: Subsequent variable declarations must have the same type. Variable 'bar' must be of type 'number', but here has type 'string'.
2+
tests/cases/compiler/reassignStaticProp.ts(5,12): error TS2711: Subsequent property declarations must have the same type. Property 'bar' must be of type 'number', but here has type 'string'.
33

44

55
==== tests/cases/compiler/reassignStaticProp.ts (2 errors) ====
@@ -11,7 +11,7 @@ tests/cases/compiler/reassignStaticProp.ts(5,12): error TS2403: Subsequent varia
1111
~~~
1212
!!! error TS2300: Duplicate identifier 'bar'.
1313
~~~
14-
!!! error TS2403: Subsequent variable declarations must have the same type. Variable 'bar' must be of type 'number', but here has type 'string'.
14+
!!! error TS2711: Subsequent property declarations must have the same type. Property 'bar' must be of type 'number', but here has type 'string'.
1515

1616
}
1717

0 commit comments

Comments
 (0)