From 037b65781fe268fd3f6206a16a27dfbc7ee4b652 Mon Sep 17 00:00:00 2001 From: AbubakerB Date: Thu, 4 Feb 2016 22:52:38 +0000 Subject: [PATCH] Accept baselines --- .../classConstructorAccessibility.errors.txt | 16 +++++++-------- .../classConstructorAccessibility2.errors.txt | 20 +++++++++---------- .../typesWithPrivateConstructor.errors.txt | 8 ++++---- .../typesWithProtectedConstructor.errors.txt | 8 ++++---- 4 files changed, 26 insertions(+), 26 deletions(-) diff --git a/tests/baselines/reference/classConstructorAccessibility.errors.txt b/tests/baselines/reference/classConstructorAccessibility.errors.txt index a24ec6c63d1..c79633ba33d 100644 --- a/tests/baselines/reference/classConstructorAccessibility.errors.txt +++ b/tests/baselines/reference/classConstructorAccessibility.errors.txt @@ -1,7 +1,7 @@ -tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility.ts(15,9): error TS2673: Constructor of type '(x: number): D' is private and only accessible within class 'D'. -tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility.ts(16,9): error TS2674: Constructor of type '(x: number): E' is protected and only accessible within class 'E'. -tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility.ts(32,13): error TS2673: Constructor of type '(x: T): D' is private and only accessible within class 'D'. -tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility.ts(33,13): error TS2674: Constructor of type '(x: T): E' is protected and only accessible within class 'E'. +tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility.ts(15,9): error TS2673: Constructor of class 'D' is private and only accessible within the class declaration. +tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility.ts(16,9): error TS2674: Constructor of class 'E' is protected and only accessible within the class declaration. +tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility.ts(32,13): error TS2673: Constructor of class 'D' is private and only accessible within the class declaration. +tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility.ts(33,13): error TS2674: Constructor of class 'E' is protected and only accessible within the class declaration. ==== tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility.ts (4 errors) ==== @@ -21,10 +21,10 @@ tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessib var c = new C(1); var d = new D(1); // error ~~~~~~~~ -!!! error TS2673: Constructor of type '(x: number): D' is private and only accessible within class 'D'. +!!! error TS2673: Constructor of class 'D' is private and only accessible within the class declaration. var e = new E(1); // error ~~~~~~~~ -!!! error TS2674: Constructor of type '(x: number): E' is protected and only accessible within class 'E'. +!!! error TS2674: Constructor of class 'E' is protected and only accessible within the class declaration. module Generic { class C { @@ -42,9 +42,9 @@ tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessib var c = new C(1); var d = new D(1); // error ~~~~~~~~ -!!! error TS2673: Constructor of type '(x: T): D' is private and only accessible within class 'D'. +!!! error TS2673: Constructor of class 'D' is private and only accessible within the class declaration. var e = new E(1); // error ~~~~~~~~ -!!! error TS2674: Constructor of type '(x: T): E' is protected and only accessible within class 'E'. +!!! error TS2674: Constructor of class 'E' is protected and only accessible within the class declaration. } \ No newline at end of file diff --git a/tests/baselines/reference/classConstructorAccessibility2.errors.txt b/tests/baselines/reference/classConstructorAccessibility2.errors.txt index 1c6fc46edb3..7bd784ac268 100644 --- a/tests/baselines/reference/classConstructorAccessibility2.errors.txt +++ b/tests/baselines/reference/classConstructorAccessibility2.errors.txt @@ -1,8 +1,8 @@ -tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility2.ts(26,28): error TS2674: Constructor of type '(x: number): BaseB' is protected and only accessible within class 'BaseB'. -tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility2.ts(29,24): error TS2675: Cannot extend private class 'BaseC'. -tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility2.ts(32,28): error TS2673: Constructor of type '(x: number): BaseC' is private and only accessible within class 'BaseC'. -tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility2.ts(36,10): error TS2674: Constructor of type '(x: number): BaseB' is protected and only accessible within class 'BaseB'. -tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility2.ts(37,10): error TS2673: Constructor of type '(x: number): BaseC' is private and only accessible within class 'BaseC'. +tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility2.ts(26,28): error TS2674: Constructor of class 'BaseB' is protected and only accessible within the class declaration. +tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility2.ts(29,24): error TS2675: Cannot extend a class 'BaseC'. Class constructor is marked as private. +tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility2.ts(32,28): error TS2673: Constructor of class 'BaseC' is private and only accessible within the class declaration. +tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility2.ts(36,10): error TS2674: Constructor of class 'BaseB' is protected and only accessible within the class declaration. +tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility2.ts(37,10): error TS2673: Constructor of class 'BaseC' is private and only accessible within the class declaration. ==== tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessibility2.ts (5 errors) ==== @@ -33,26 +33,26 @@ tests/cases/conformance/classes/constructorDeclarations/classConstructorAccessib createInstance() { new DerivedB(1); } createBaseInstance() { new BaseB(1); } // error ~~~~~~~~~~~~ -!!! error TS2674: Constructor of type '(x: number): BaseB' is protected and only accessible within class 'BaseB'. +!!! error TS2674: Constructor of class 'BaseB' is protected and only accessible within the class declaration. } class DerivedC extends BaseC { // error ~~~~~ -!!! error TS2675: Cannot extend private class 'BaseC'. +!!! error TS2675: Cannot extend a class 'BaseC'. Class constructor is marked as private. constructor(public x: number) { super(x); } createInstance() { new DerivedC(1); } createBaseInstance() { new BaseC(1); } // error ~~~~~~~~~~~~ -!!! error TS2673: Constructor of type '(x: number): BaseC' is private and only accessible within class 'BaseC'. +!!! error TS2673: Constructor of class 'BaseC' is private and only accessible within the class declaration. } var ba = new BaseA(1); var bb = new BaseB(1); // error ~~~~~~~~~~~~ -!!! error TS2674: Constructor of type '(x: number): BaseB' is protected and only accessible within class 'BaseB'. +!!! error TS2674: Constructor of class 'BaseB' is protected and only accessible within the class declaration. var bc = new BaseC(1); // error ~~~~~~~~~~~~ -!!! error TS2673: Constructor of type '(x: number): BaseC' is private and only accessible within class 'BaseC'. +!!! error TS2673: Constructor of class 'BaseC' is private and only accessible within the class declaration. var da = new DerivedA(1); var db = new DerivedB(1); diff --git a/tests/baselines/reference/typesWithPrivateConstructor.errors.txt b/tests/baselines/reference/typesWithPrivateConstructor.errors.txt index d30bb29e314..ab8ea4e26ad 100644 --- a/tests/baselines/reference/typesWithPrivateConstructor.errors.txt +++ b/tests/baselines/reference/typesWithPrivateConstructor.errors.txt @@ -1,5 +1,5 @@ -tests/cases/conformance/types/members/typesWithPrivateConstructor.ts(6,9): error TS2673: Constructor of type '(): C' is private and only accessible within class 'C'. -tests/cases/conformance/types/members/typesWithPrivateConstructor.ts(14,10): error TS2673: Constructor of type '(x: number): C2' is private and only accessible within class 'C2'. +tests/cases/conformance/types/members/typesWithPrivateConstructor.ts(6,9): error TS2673: Constructor of class 'C' is private and only accessible within the class declaration. +tests/cases/conformance/types/members/typesWithPrivateConstructor.ts(14,10): error TS2673: Constructor of class 'C2' is private and only accessible within the class declaration. ==== tests/cases/conformance/types/members/typesWithPrivateConstructor.ts (2 errors) ==== @@ -10,7 +10,7 @@ tests/cases/conformance/types/members/typesWithPrivateConstructor.ts(14,10): err var c = new C(); // error C is private ~~~~~~~ -!!! error TS2673: Constructor of type '(): C' is private and only accessible within class 'C'. +!!! error TS2673: Constructor of class 'C' is private and only accessible within the class declaration. var r: () => void = c.constructor; class C2 { @@ -20,5 +20,5 @@ tests/cases/conformance/types/members/typesWithPrivateConstructor.ts(14,10): err var c2 = new C2(); // error C2 is private ~~~~~~~~ -!!! error TS2673: Constructor of type '(x: number): C2' is private and only accessible within class 'C2'. +!!! error TS2673: Constructor of class 'C2' is private and only accessible within the class declaration. var r2: (x: number) => void = c2.constructor; \ No newline at end of file diff --git a/tests/baselines/reference/typesWithProtectedConstructor.errors.txt b/tests/baselines/reference/typesWithProtectedConstructor.errors.txt index 4dc8add9fc2..2a5a059f44d 100644 --- a/tests/baselines/reference/typesWithProtectedConstructor.errors.txt +++ b/tests/baselines/reference/typesWithProtectedConstructor.errors.txt @@ -1,5 +1,5 @@ -tests/cases/conformance/types/members/typesWithProtectedConstructor.ts(6,9): error TS2674: Constructor of type '(): C' is protected and only accessible within class 'C'. -tests/cases/conformance/types/members/typesWithProtectedConstructor.ts(14,10): error TS2674: Constructor of type '(x: number): C2' is protected and only accessible within class 'C2'. +tests/cases/conformance/types/members/typesWithProtectedConstructor.ts(6,9): error TS2674: Constructor of class 'C' is protected and only accessible within the class declaration. +tests/cases/conformance/types/members/typesWithProtectedConstructor.ts(14,10): error TS2674: Constructor of class 'C2' is protected and only accessible within the class declaration. ==== tests/cases/conformance/types/members/typesWithProtectedConstructor.ts (2 errors) ==== @@ -10,7 +10,7 @@ tests/cases/conformance/types/members/typesWithProtectedConstructor.ts(14,10): e var c = new C(); // error C is protected ~~~~~~~ -!!! error TS2674: Constructor of type '(): C' is protected and only accessible within class 'C'. +!!! error TS2674: Constructor of class 'C' is protected and only accessible within the class declaration. var r: () => void = c.constructor; class C2 { @@ -20,5 +20,5 @@ tests/cases/conformance/types/members/typesWithProtectedConstructor.ts(14,10): e var c2 = new C2(); // error C2 is protected ~~~~~~~~ -!!! error TS2674: Constructor of type '(x: number): C2' is protected and only accessible within class 'C2'. +!!! error TS2674: Constructor of class 'C2' is protected and only accessible within the class declaration. var r2: (x: number) => void = c2.constructor; \ No newline at end of file