tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(8,20): error TS4006: Type parameter 'T' of constructor signature from exported interface has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(8,37): error TS4045: Return type of constructor signature from exported interface has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(9,16): error TS4008: Type parameter 'T' of call signature from exported interface has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(9,33): error TS4047: Return type of call signature from exported interface has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(10,24): error TS4014: Type parameter 'T' of method from exported interface has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(10,41): error TS4057: Return type of method from exported interface has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(32,43): error TS4010: Type parameter 'T' of public static method from exported class has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(36,30): error TS4012: Type parameter 'T' of public method from exported class has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(75,67): error TS4016: Type parameter 'T' of exported function has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(127,20): error TS4006: Type parameter 'T' of constructor signature from exported interface has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(127,50): error TS4045: Return type of constructor signature from exported interface has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(128,16): error TS4008: Type parameter 'T' of call signature from exported interface has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(128,46): error TS4047: Return type of call signature from exported interface has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(129,24): error TS4014: Type parameter 'T' of method from exported interface has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(129,54): error TS4057: Return type of method from exported interface has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(132,43): error TS4010: Type parameter 'T' of public static method from exported class has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(134,30): error TS4012: Type parameter 'T' of public method from exported class has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(137,74): error TS4016: Type parameter 'T' of exported function has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(164,24): error TS4006: Type parameter 'T' of constructor signature from exported interface has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(164,41): error TS4045: Return type of constructor signature from exported interface has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(165,20): error TS4008: Type parameter 'T' of call signature from exported interface has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(165,37): error TS4047: Return type of call signature from exported interface has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(166,28): error TS4014: Type parameter 'T' of method from exported interface has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(166,45): error TS4057: Return type of method from exported interface has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(188,47): error TS4010: Type parameter 'T' of public static method from exported class has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(192,34): error TS4012: Type parameter 'T' of public method from exported class has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(231,71): error TS4016: Type parameter 'T' of exported function has or is using private name 'privateClass'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(283,24): error TS4006: Type parameter 'T' of constructor signature from exported interface has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(283,54): error TS4045: Return type of constructor signature from exported interface has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(284,20): error TS4008: Type parameter 'T' of call signature from exported interface has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(284,50): error TS4047: Return type of call signature from exported interface has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(285,28): error TS4014: Type parameter 'T' of method from exported interface has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(285,58): error TS4057: Return type of method from exported interface has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(288,47): error TS4010: Type parameter 'T' of public static method from exported class has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(290,34): error TS4012: Type parameter 'T' of public method from exported class has or is using private name 'privateModule'. tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts(293,78): error TS4016: Type parameter 'T' of exported function has or is using private name 'privateModule'. ==== tests/cases/compiler/privacyTypeParameterOfFunctionDeclFile.ts (36 errors) ==== class privateClass { } export class publicClass { } export interface publicInterfaceWithPrivateTypeParameters { new (): privateClass; // Error ~~~~~~~~~~~~ !!! error TS4006: Type parameter 'T' of constructor signature from exported interface has or is using private name 'privateClass'. ~~~~~~~~~~~~ !!! error TS4045: Return type of constructor signature from exported interface has or is using private name 'privateClass'. (): privateClass; // Error ~~~~~~~~~~~~ !!! error TS4008: Type parameter 'T' of call signature from exported interface has or is using private name 'privateClass'. ~~~~~~~~~~~~ !!! error TS4047: Return type of call signature from exported interface has or is using private name 'privateClass'. myMethod(): privateClass; // Error ~~~~~~~~~~~~ !!! error TS4014: Type parameter 'T' of method from exported interface has or is using private name 'privateClass'. ~~~~~~~~~~~~ !!! error TS4057: Return type of method from exported interface has or is using private name 'privateClass'. } export interface publicInterfaceWithPublicTypeParameters { new (): publicClass; (): publicClass; myMethod(): publicClass; } interface privateInterfaceWithPrivateTypeParameters { new (): privateClass; (): privateClass; myMethod(): privateClass; } interface privateInterfaceWithPublicTypeParameters { new (): publicClass; (): publicClass; myMethod(): publicClass; } export class publicClassWithWithPrivateTypeParameters { static myPublicStaticMethod() { // Error ~~~~~~~~~~~~ !!! error TS4010: Type parameter 'T' of public static method from exported class has or is using private name 'privateClass'. } private static myPrivateStaticMethod() { } myPublicMethod() { // Error ~~~~~~~~~~~~ !!! error TS4012: Type parameter 'T' of public method from exported class has or is using private name 'privateClass'. } private myPrivateMethod() { } } export class publicClassWithWithPublicTypeParameters { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } class privateClassWithWithPrivateTypeParameters { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } class privateClassWithWithPublicTypeParameters { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } export function publicFunctionWithPrivateTypeParameters() { // Error ~~~~~~~~~~~~ !!! error TS4016: Type parameter 'T' of exported function has or is using private name 'privateClass'. } export function publicFunctionWithPublicTypeParameters() { } function privateFunctionWithPrivateTypeParameters() { } function privateFunctionWithPublicTypeParameters() { } export interface publicInterfaceWithPublicTypeParametersWithoutExtends { new (): publicClass; (): publicClass; myMethod(): publicClass; } interface privateInterfaceWithPublicTypeParametersWithoutExtends { new (): publicClass; (): publicClass; myMethod(): publicClass; } export class publicClassWithWithPublicTypeParametersWithoutExtends { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } class privateClassWithWithPublicTypeParametersWithoutExtends { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } export function publicFunctionWithPublicTypeParametersWithoutExtends() { } function privateFunctionWithPublicTypeParametersWithoutExtends() { } export interface publicInterfaceWithPrivatModuleTypeParameters { new (): privateModule.publicClass; // Error ~~~~~~~~~~~~~ !!! error TS4006: Type parameter 'T' of constructor signature from exported interface has or is using private name 'privateModule'. ~~~~~~~~~~~~~ !!! error TS4045: Return type of constructor signature from exported interface has or is using private name 'privateModule'. (): privateModule.publicClass; // Error ~~~~~~~~~~~~~ !!! error TS4008: Type parameter 'T' of call signature from exported interface has or is using private name 'privateModule'. ~~~~~~~~~~~~~ !!! error TS4047: Return type of call signature from exported interface has or is using private name 'privateModule'. myMethod(): privateModule.publicClass; // Error ~~~~~~~~~~~~~ !!! error TS4014: Type parameter 'T' of method from exported interface has or is using private name 'privateModule'. ~~~~~~~~~~~~~ !!! error TS4057: Return type of method from exported interface has or is using private name 'privateModule'. } export class publicClassWithWithPrivateModuleTypeParameters { static myPublicStaticMethod() { // Error ~~~~~~~~~~~~~ !!! error TS4010: Type parameter 'T' of public static method from exported class has or is using private name 'privateModule'. } myPublicMethod() { // Error ~~~~~~~~~~~~~ !!! error TS4012: Type parameter 'T' of public method from exported class has or is using private name 'privateModule'. } } export function publicFunctionWithPrivateMopduleTypeParameters() { // Error ~~~~~~~~~~~~~ !!! error TS4016: Type parameter 'T' of exported function has or is using private name 'privateModule'. } interface privateInterfaceWithPrivatModuleTypeParameters { new (): privateModule.publicClass; (): privateModule.publicClass; myMethod(): privateModule.publicClass; } class privateClassWithWithPrivateModuleTypeParameters { static myPublicStaticMethod() { } myPublicMethod() { } } function privateFunctionWithPrivateMopduleTypeParameters() { } export module publicModule { class privateClass { } export class publicClass { } export interface publicInterfaceWithPrivateTypeParameters { new (): privateClass; // Error ~~~~~~~~~~~~ !!! error TS4006: Type parameter 'T' of constructor signature from exported interface has or is using private name 'privateClass'. ~~~~~~~~~~~~ !!! error TS4045: Return type of constructor signature from exported interface has or is using private name 'privateClass'. (): privateClass; // Error ~~~~~~~~~~~~ !!! error TS4008: Type parameter 'T' of call signature from exported interface has or is using private name 'privateClass'. ~~~~~~~~~~~~ !!! error TS4047: Return type of call signature from exported interface has or is using private name 'privateClass'. myMethod(): privateClass; // Error ~~~~~~~~~~~~ !!! error TS4014: Type parameter 'T' of method from exported interface has or is using private name 'privateClass'. ~~~~~~~~~~~~ !!! error TS4057: Return type of method from exported interface has or is using private name 'privateClass'. } export interface publicInterfaceWithPublicTypeParameters { new (): publicClass; (): publicClass; myMethod(): publicClass; } interface privateInterfaceWithPrivateTypeParameters { new (): privateClass; (): privateClass; myMethod(): privateClass; } interface privateInterfaceWithPublicTypeParameters { new (): publicClass; (): publicClass; myMethod(): publicClass; } export class publicClassWithWithPrivateTypeParameters { static myPublicStaticMethod() { // Error ~~~~~~~~~~~~ !!! error TS4010: Type parameter 'T' of public static method from exported class has or is using private name 'privateClass'. } private static myPrivateStaticMethod() { } myPublicMethod() { // Error ~~~~~~~~~~~~ !!! error TS4012: Type parameter 'T' of public method from exported class has or is using private name 'privateClass'. } private myPrivateMethod() { } } export class publicClassWithWithPublicTypeParameters { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } class privateClassWithWithPrivateTypeParameters { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } class privateClassWithWithPublicTypeParameters { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } export function publicFunctionWithPrivateTypeParameters() { // Error ~~~~~~~~~~~~ !!! error TS4016: Type parameter 'T' of exported function has or is using private name 'privateClass'. } export function publicFunctionWithPublicTypeParameters() { } function privateFunctionWithPrivateTypeParameters() { } function privateFunctionWithPublicTypeParameters() { } export interface publicInterfaceWithPublicTypeParametersWithoutExtends { new (): publicClass; (): publicClass; myMethod(): publicClass; } interface privateInterfaceWithPublicTypeParametersWithoutExtends { new (): publicClass; (): publicClass; myMethod(): publicClass; } export class publicClassWithWithPublicTypeParametersWithoutExtends { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } class privateClassWithWithPublicTypeParametersWithoutExtends { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } export function publicFunctionWithPublicTypeParametersWithoutExtends() { } function privateFunctionWithPublicTypeParametersWithoutExtends() { } export interface publicInterfaceWithPrivatModuleTypeParameters { new (): privateModule.publicClass; // Error ~~~~~~~~~~~~~ !!! error TS4006: Type parameter 'T' of constructor signature from exported interface has or is using private name 'privateModule'. ~~~~~~~~~~~~~ !!! error TS4045: Return type of constructor signature from exported interface has or is using private name 'privateModule'. (): privateModule.publicClass; // Error ~~~~~~~~~~~~~ !!! error TS4008: Type parameter 'T' of call signature from exported interface has or is using private name 'privateModule'. ~~~~~~~~~~~~~ !!! error TS4047: Return type of call signature from exported interface has or is using private name 'privateModule'. myMethod(): privateModule.publicClass; // Error ~~~~~~~~~~~~~ !!! error TS4014: Type parameter 'T' of method from exported interface has or is using private name 'privateModule'. ~~~~~~~~~~~~~ !!! error TS4057: Return type of method from exported interface has or is using private name 'privateModule'. } export class publicClassWithWithPrivateModuleTypeParameters { static myPublicStaticMethod() { // Error ~~~~~~~~~~~~~ !!! error TS4010: Type parameter 'T' of public static method from exported class has or is using private name 'privateModule'. } myPublicMethod() { // Error ~~~~~~~~~~~~~ !!! error TS4012: Type parameter 'T' of public method from exported class has or is using private name 'privateModule'. } } export function publicFunctionWithPrivateMopduleTypeParameters() { // Error ~~~~~~~~~~~~~ !!! error TS4016: Type parameter 'T' of exported function has or is using private name 'privateModule'. } interface privateInterfaceWithPrivatModuleTypeParameters { new (): privateModule.publicClass; (): privateModule.publicClass; myMethod(): privateModule.publicClass; } class privateClassWithWithPrivateModuleTypeParameters { static myPublicStaticMethod() { } myPublicMethod() { } } function privateFunctionWithPrivateMopduleTypeParameters() { } } module privateModule { class privateClass { } export class publicClass { } export interface publicInterfaceWithPrivateTypeParameters { new (): privateClass; (): privateClass; myMethod(): privateClass; } export interface publicInterfaceWithPublicTypeParameters { new (): publicClass; (): publicClass; myMethod(): publicClass; } interface privateInterfaceWithPrivateTypeParameters { new (): privateClass; (): privateClass; myMethod(): privateClass; } interface privateInterfaceWithPublicTypeParameters { new (): publicClass; (): publicClass; myMethod(): publicClass; } export class publicClassWithWithPrivateTypeParameters { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } export class publicClassWithWithPublicTypeParameters { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } class privateClassWithWithPrivateTypeParameters { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } class privateClassWithWithPublicTypeParameters { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } export function publicFunctionWithPrivateTypeParameters() { } export function publicFunctionWithPublicTypeParameters() { } function privateFunctionWithPrivateTypeParameters() { } function privateFunctionWithPublicTypeParameters() { } export interface publicInterfaceWithPublicTypeParametersWithoutExtends { new (): publicClass; (): publicClass; myMethod(): publicClass; } interface privateInterfaceWithPublicTypeParametersWithoutExtends { new (): publicClass; (): publicClass; myMethod(): publicClass; } export class publicClassWithWithPublicTypeParametersWithoutExtends { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } class privateClassWithWithPublicTypeParametersWithoutExtends { static myPublicStaticMethod() { } private static myPrivateStaticMethod() { } myPublicMethod() { } private myPrivateMethod() { } } export function publicFunctionWithPublicTypeParametersWithoutExtends() { } function privateFunctionWithPublicTypeParametersWithoutExtends() { } }