516 lines
No EOL
28 KiB
Text
516 lines
No EOL
28 KiB
Text
tests/cases/compiler/privacyVarDeclFile_GlobalFile.ts(105,21): error TS4033: Property 'myProperty' of exported interface has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_GlobalFile.ts(121,40): error TS4028: Public static property 'myPublicStaticProperty' of exported class has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_GlobalFile.ts(123,27): error TS4031: Public property 'myPublicProperty' of exported class has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_GlobalFile.ts(148,51): error TS4025: Exported variable 'publicVarWithPrivatePropertyTypes' has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_GlobalFile.ts(153,66): error TS4025: Exported variable 'publicAmbientVarWithPrivatePropertyTypes' has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_GlobalFile.ts(159,21): error TS4033: Property 'myProperty' of exported interface has or is using private name 'privateModule'.
|
|
tests/cases/compiler/privacyVarDeclFile_GlobalFile.ts(162,40): error TS4028: Public static property 'myPublicStaticProperty' of exported class has or is using private name 'privateModule'.
|
|
tests/cases/compiler/privacyVarDeclFile_GlobalFile.ts(163,27): error TS4031: Public property 'myPublicProperty' of exported class has or is using private name 'privateModule'.
|
|
tests/cases/compiler/privacyVarDeclFile_GlobalFile.ts(165,57): error TS4025: Exported variable 'publicVarWithPrivateModulePropertyTypes' has or is using private name 'privateModule'.
|
|
tests/cases/compiler/privacyVarDeclFile_GlobalFile.ts(166,72): error TS4025: Exported variable 'publicAmbientVarWithPrivateModulePropertyTypes' has or is using private name 'privateModule'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(9,17): error TS4033: Property 'myProperty' of exported interface has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(25,36): error TS4028: Public static property 'myPublicStaticProperty' of exported class has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(27,23): error TS4031: Public property 'myPublicProperty' of exported class has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(52,47): error TS4025: Exported variable 'publicVarWithPrivatePropertyTypes' has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(57,62): error TS4025: Exported variable 'publicAmbientVarWithPrivatePropertyTypes' has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(63,17): error TS4033: Property 'myProperty' of exported interface has or is using private name 'privateModule'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(66,36): error TS4028: Public static property 'myPublicStaticProperty' of exported class has or is using private name 'privateModule'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(67,23): error TS4031: Public property 'myPublicProperty' of exported class has or is using private name 'privateModule'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(69,53): error TS4025: Exported variable 'publicVarWithPrivateModulePropertyTypes' has or is using private name 'privateModule'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(70,68): error TS4025: Exported variable 'publicAmbientVarWithPrivateModulePropertyTypes' has or is using private name 'privateModule'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(90,21): error TS4033: Property 'myProperty' of exported interface has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(106,40): error TS4028: Public static property 'myPublicStaticProperty' of exported class has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(108,27): error TS4031: Public property 'myPublicProperty' of exported class has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(133,51): error TS4025: Exported variable 'publicVarWithPrivatePropertyTypes' has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(138,66): error TS4025: Exported variable 'publicAmbientVarWithPrivatePropertyTypes' has or is using private name 'privateClass'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(144,21): error TS4033: Property 'myProperty' of exported interface has or is using private name 'privateModule'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(147,40): error TS4028: Public static property 'myPublicStaticProperty' of exported class has or is using private name 'privateModule'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(148,27): error TS4031: Public property 'myPublicProperty' of exported class has or is using private name 'privateModule'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(150,57): error TS4025: Exported variable 'publicVarWithPrivateModulePropertyTypes' has or is using private name 'privateModule'.
|
|
tests/cases/compiler/privacyVarDeclFile_externalModule.ts(151,72): error TS4025: Exported variable 'publicAmbientVarWithPrivateModulePropertyTypes' has or is using private name 'privateModule'.
|
|
|
|
|
|
==== tests/cases/compiler/privacyVarDeclFile_externalModule.ts (20 errors) ====
|
|
|
|
class privateClass {
|
|
}
|
|
|
|
export class publicClass {
|
|
}
|
|
|
|
export interface publicInterfaceWithPrivatePropertyTypes {
|
|
myProperty: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4033: Property 'myProperty' of exported interface has or is using private name 'privateClass'.
|
|
}
|
|
|
|
export interface publicInterfaceWithPublicPropertyTypes {
|
|
myProperty: publicClass;
|
|
}
|
|
|
|
interface privateInterfaceWithPrivatePropertyTypes {
|
|
myProperty: privateClass;
|
|
}
|
|
|
|
interface privateInterfaceWithPublicPropertyTypes {
|
|
myProperty: publicClass;
|
|
}
|
|
|
|
export class publicClassWithWithPrivatePropertyTypes {
|
|
static myPublicStaticProperty: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4028: Public static property 'myPublicStaticProperty' of exported class has or is using private name 'privateClass'.
|
|
private static myPrivateStaticProperty: privateClass;
|
|
myPublicProperty: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4031: Public property 'myPublicProperty' of exported class has or is using private name 'privateClass'.
|
|
private myPrivateProperty: privateClass;
|
|
}
|
|
|
|
export class publicClassWithWithPublicPropertyTypes {
|
|
static myPublicStaticProperty: publicClass;
|
|
private static myPrivateStaticProperty: publicClass;
|
|
myPublicProperty: publicClass;
|
|
private myPrivateProperty: publicClass;
|
|
}
|
|
|
|
class privateClassWithWithPrivatePropertyTypes {
|
|
static myPublicStaticProperty: privateClass;
|
|
private static myPrivateStaticProperty: privateClass;
|
|
myPublicProperty: privateClass;
|
|
private myPrivateProperty: privateClass;
|
|
}
|
|
|
|
class privateClassWithWithPublicPropertyTypes {
|
|
static myPublicStaticProperty: publicClass;
|
|
private static myPrivateStaticProperty: publicClass;
|
|
myPublicProperty: publicClass;
|
|
private myPrivateProperty: publicClass;
|
|
}
|
|
|
|
export var publicVarWithPrivatePropertyTypes: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4025: Exported variable 'publicVarWithPrivatePropertyTypes' has or is using private name 'privateClass'.
|
|
export var publicVarWithPublicPropertyTypes: publicClass;
|
|
var privateVarWithPrivatePropertyTypes: privateClass;
|
|
var privateVarWithPublicPropertyTypes: publicClass;
|
|
|
|
export declare var publicAmbientVarWithPrivatePropertyTypes: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4025: Exported variable 'publicAmbientVarWithPrivatePropertyTypes' has or is using private name 'privateClass'.
|
|
export declare var publicAmbientVarWithPublicPropertyTypes: publicClass;
|
|
declare var privateAmbientVarWithPrivatePropertyTypes: privateClass;
|
|
declare var privateAmbientVarWithPublicPropertyTypes: publicClass;
|
|
|
|
export interface publicInterfaceWithPrivateModulePropertyTypes {
|
|
myProperty: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4033: Property 'myProperty' of exported interface has or is using private name 'privateModule'.
|
|
}
|
|
export class publicClassWithPrivateModulePropertyTypes {
|
|
static myPublicStaticProperty: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4028: Public static property 'myPublicStaticProperty' of exported class has or is using private name 'privateModule'.
|
|
myPublicProperty: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4031: Public property 'myPublicProperty' of exported class has or is using private name 'privateModule'.
|
|
}
|
|
export var publicVarWithPrivateModulePropertyTypes: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4025: Exported variable 'publicVarWithPrivateModulePropertyTypes' has or is using private name 'privateModule'.
|
|
export declare var publicAmbientVarWithPrivateModulePropertyTypes: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4025: Exported variable 'publicAmbientVarWithPrivateModulePropertyTypes' has or is using private name 'privateModule'.
|
|
|
|
interface privateInterfaceWithPrivateModulePropertyTypes {
|
|
myProperty: privateModule.publicClass;
|
|
}
|
|
class privateClassWithPrivateModulePropertyTypes {
|
|
static myPublicStaticProperty: privateModule.publicClass;
|
|
myPublicProperty: privateModule.publicClass;
|
|
}
|
|
var privateVarWithPrivateModulePropertyTypes: privateModule.publicClass;
|
|
declare var privateAmbientVarWithPrivateModulePropertyTypes: privateModule.publicClass;
|
|
|
|
export module publicModule {
|
|
class privateClass {
|
|
}
|
|
|
|
export class publicClass {
|
|
}
|
|
|
|
export interface publicInterfaceWithPrivatePropertyTypes {
|
|
myProperty: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4033: Property 'myProperty' of exported interface has or is using private name 'privateClass'.
|
|
}
|
|
|
|
export interface publicInterfaceWithPublicPropertyTypes {
|
|
myProperty: publicClass;
|
|
}
|
|
|
|
interface privateInterfaceWithPrivatePropertyTypes {
|
|
myProperty: privateClass;
|
|
}
|
|
|
|
interface privateInterfaceWithPublicPropertyTypes {
|
|
myProperty: publicClass;
|
|
}
|
|
|
|
export class publicClassWithWithPrivatePropertyTypes {
|
|
static myPublicStaticProperty: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4028: Public static property 'myPublicStaticProperty' of exported class has or is using private name 'privateClass'.
|
|
private static myPrivateStaticProperty: privateClass;
|
|
myPublicProperty: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4031: Public property 'myPublicProperty' of exported class has or is using private name 'privateClass'.
|
|
private myPrivateProperty: privateClass;
|
|
}
|
|
|
|
export class publicClassWithWithPublicPropertyTypes {
|
|
static myPublicStaticProperty: publicClass;
|
|
private static myPrivateStaticProperty: publicClass;
|
|
myPublicProperty: publicClass;
|
|
private myPrivateProperty: publicClass;
|
|
}
|
|
|
|
class privateClassWithWithPrivatePropertyTypes {
|
|
static myPublicStaticProperty: privateClass;
|
|
private static myPrivateStaticProperty: privateClass;
|
|
myPublicProperty: privateClass;
|
|
private myPrivateProperty: privateClass;
|
|
}
|
|
|
|
class privateClassWithWithPublicPropertyTypes {
|
|
static myPublicStaticProperty: publicClass;
|
|
private static myPrivateStaticProperty: publicClass;
|
|
myPublicProperty: publicClass;
|
|
private myPrivateProperty: publicClass;
|
|
}
|
|
|
|
export var publicVarWithPrivatePropertyTypes: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4025: Exported variable 'publicVarWithPrivatePropertyTypes' has or is using private name 'privateClass'.
|
|
export var publicVarWithPublicPropertyTypes: publicClass;
|
|
var privateVarWithPrivatePropertyTypes: privateClass;
|
|
var privateVarWithPublicPropertyTypes: publicClass;
|
|
|
|
export declare var publicAmbientVarWithPrivatePropertyTypes: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4025: Exported variable 'publicAmbientVarWithPrivatePropertyTypes' has or is using private name 'privateClass'.
|
|
export declare var publicAmbientVarWithPublicPropertyTypes: publicClass;
|
|
declare var privateAmbientVarWithPrivatePropertyTypes: privateClass;
|
|
declare var privateAmbientVarWithPublicPropertyTypes: publicClass;
|
|
|
|
export interface publicInterfaceWithPrivateModulePropertyTypes {
|
|
myProperty: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4033: Property 'myProperty' of exported interface has or is using private name 'privateModule'.
|
|
}
|
|
export class publicClassWithPrivateModulePropertyTypes {
|
|
static myPublicStaticProperty: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4028: Public static property 'myPublicStaticProperty' of exported class has or is using private name 'privateModule'.
|
|
myPublicProperty: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4031: Public property 'myPublicProperty' of exported class has or is using private name 'privateModule'.
|
|
}
|
|
export var publicVarWithPrivateModulePropertyTypes: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4025: Exported variable 'publicVarWithPrivateModulePropertyTypes' has or is using private name 'privateModule'.
|
|
export declare var publicAmbientVarWithPrivateModulePropertyTypes: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4025: Exported variable 'publicAmbientVarWithPrivateModulePropertyTypes' has or is using private name 'privateModule'.
|
|
|
|
interface privateInterfaceWithPrivateModulePropertyTypes {
|
|
myProperty: privateModule.publicClass;
|
|
}
|
|
class privateClassWithPrivateModulePropertyTypes {
|
|
static myPublicStaticProperty: privateModule.publicClass;
|
|
myPublicProperty: privateModule.publicClass;
|
|
}
|
|
var privateVarWithPrivateModulePropertyTypes: privateModule.publicClass;
|
|
declare var privateAmbientVarWithPrivateModulePropertyTypes: privateModule.publicClass;
|
|
}
|
|
|
|
module privateModule {
|
|
class privateClass {
|
|
}
|
|
|
|
export class publicClass {
|
|
}
|
|
|
|
export interface publicInterfaceWithPrivatePropertyTypes {
|
|
myProperty: privateClass;
|
|
}
|
|
|
|
export interface publicInterfaceWithPublicPropertyTypes {
|
|
myProperty: publicClass;
|
|
}
|
|
|
|
interface privateInterfaceWithPrivatePropertyTypes {
|
|
myProperty: privateClass;
|
|
}
|
|
|
|
interface privateInterfaceWithPublicPropertyTypes {
|
|
myProperty: publicClass;
|
|
}
|
|
|
|
export class publicClassWithWithPrivatePropertyTypes {
|
|
static myPublicStaticProperty: privateClass;
|
|
private static myPrivateStaticProperty: privateClass;
|
|
myPublicProperty: privateClass;
|
|
private myPrivateProperty: privateClass;
|
|
}
|
|
|
|
export class publicClassWithWithPublicPropertyTypes {
|
|
static myPublicStaticProperty: publicClass;
|
|
private static myPrivateStaticProperty: publicClass;
|
|
myPublicProperty: publicClass;
|
|
private myPrivateProperty: publicClass;
|
|
}
|
|
|
|
class privateClassWithWithPrivatePropertyTypes {
|
|
static myPublicStaticProperty: privateClass;
|
|
private static myPrivateStaticProperty: privateClass;
|
|
myPublicProperty: privateClass;
|
|
private myPrivateProperty: privateClass;
|
|
}
|
|
|
|
class privateClassWithWithPublicPropertyTypes {
|
|
static myPublicStaticProperty: publicClass;
|
|
private static myPrivateStaticProperty: publicClass;
|
|
myPublicProperty: publicClass;
|
|
private myPrivateProperty: publicClass;
|
|
}
|
|
|
|
export var publicVarWithPrivatePropertyTypes: privateClass;
|
|
export var publicVarWithPublicPropertyTypes: publicClass;
|
|
var privateVarWithPrivatePropertyTypes: privateClass;
|
|
var privateVarWithPublicPropertyTypes: publicClass;
|
|
|
|
export declare var publicAmbientVarWithPrivatePropertyTypes: privateClass;
|
|
export declare var publicAmbientVarWithPublicPropertyTypes: publicClass;
|
|
declare var privateAmbientVarWithPrivatePropertyTypes: privateClass;
|
|
declare var privateAmbientVarWithPublicPropertyTypes: publicClass;
|
|
|
|
export interface publicInterfaceWithPrivateModulePropertyTypes {
|
|
myProperty: privateModule.publicClass;
|
|
}
|
|
export class publicClassWithPrivateModulePropertyTypes {
|
|
static myPublicStaticProperty: privateModule.publicClass;
|
|
myPublicProperty: privateModule.publicClass;
|
|
}
|
|
export var publicVarWithPrivateModulePropertyTypes: privateModule.publicClass;
|
|
export declare var publicAmbientVarWithPrivateModulePropertyTypes: privateModule.publicClass;
|
|
|
|
interface privateInterfaceWithPrivateModulePropertyTypes {
|
|
myProperty: privateModule.publicClass;
|
|
}
|
|
class privateClassWithPrivateModulePropertyTypes {
|
|
static myPublicStaticProperty: privateModule.publicClass;
|
|
myPublicProperty: privateModule.publicClass;
|
|
}
|
|
var privateVarWithPrivateModulePropertyTypes: privateModule.publicClass;
|
|
declare var privateAmbientVarWithPrivateModulePropertyTypes: privateModule.publicClass;
|
|
}
|
|
|
|
==== tests/cases/compiler/privacyVarDeclFile_GlobalFile.ts (10 errors) ====
|
|
class publicClassInGlobal {
|
|
}
|
|
interface publicInterfaceWithPublicPropertyTypesInGlobal {
|
|
myProperty: publicClassInGlobal;
|
|
}
|
|
class publicClassWithWithPublicPropertyTypesInGlobal {
|
|
static myPublicStaticProperty: publicClassInGlobal;
|
|
private static myPrivateStaticProperty: publicClassInGlobal;
|
|
myPublicProperty: publicClassInGlobal;
|
|
private myPrivateProperty: publicClassInGlobal;
|
|
}
|
|
var publicVarWithPublicPropertyTypesInGlobal: publicClassInGlobal;
|
|
declare var publicAmbientVarWithPublicPropertyTypesInGlobal: publicClassInGlobal;
|
|
|
|
module publicModuleInGlobal {
|
|
class privateClass {
|
|
}
|
|
|
|
export class publicClass {
|
|
}
|
|
|
|
module privateModule {
|
|
class privateClass {
|
|
}
|
|
|
|
export class publicClass {
|
|
}
|
|
|
|
export interface publicInterfaceWithPrivatePropertyTypes {
|
|
myProperty: privateClass;
|
|
}
|
|
|
|
export interface publicInterfaceWithPublicPropertyTypes {
|
|
myProperty: publicClass;
|
|
}
|
|
|
|
interface privateInterfaceWithPrivatePropertyTypes {
|
|
myProperty: privateClass;
|
|
}
|
|
|
|
interface privateInterfaceWithPublicPropertyTypes {
|
|
myProperty: publicClass;
|
|
}
|
|
|
|
export class publicClassWithWithPrivatePropertyTypes {
|
|
static myPublicStaticProperty: privateClass;
|
|
private static myPrivateStaticProperty: privateClass;
|
|
myPublicProperty: privateClass;
|
|
private myPrivateProperty: privateClass;
|
|
}
|
|
|
|
export class publicClassWithWithPublicPropertyTypes {
|
|
static myPublicStaticProperty: publicClass;
|
|
private static myPrivateStaticProperty: publicClass;
|
|
myPublicProperty: publicClass;
|
|
private myPrivateProperty: publicClass;
|
|
}
|
|
|
|
class privateClassWithWithPrivatePropertyTypes {
|
|
static myPublicStaticProperty: privateClass;
|
|
private static myPrivateStaticProperty: privateClass;
|
|
myPublicProperty: privateClass;
|
|
private myPrivateProperty: privateClass;
|
|
}
|
|
|
|
class privateClassWithWithPublicPropertyTypes {
|
|
static myPublicStaticProperty: publicClass;
|
|
private static myPrivateStaticProperty: publicClass;
|
|
myPublicProperty: publicClass;
|
|
private myPrivateProperty: publicClass;
|
|
}
|
|
|
|
export var publicVarWithPrivatePropertyTypes: privateClass;
|
|
export var publicVarWithPublicPropertyTypes: publicClass;
|
|
var privateVarWithPrivatePropertyTypes: privateClass;
|
|
var privateVarWithPublicPropertyTypes: publicClass;
|
|
|
|
export declare var publicAmbientVarWithPrivatePropertyTypes: privateClass;
|
|
export declare var publicAmbientVarWithPublicPropertyTypes: publicClass;
|
|
declare var privateAmbientVarWithPrivatePropertyTypes: privateClass;
|
|
declare var privateAmbientVarWithPublicPropertyTypes: publicClass;
|
|
|
|
export interface publicInterfaceWithPrivateModulePropertyTypes {
|
|
myProperty: privateModule.publicClass;
|
|
}
|
|
export class publicClassWithPrivateModulePropertyTypes {
|
|
static myPublicStaticProperty: privateModule.publicClass;
|
|
myPublicProperty: privateModule.publicClass;
|
|
}
|
|
export var publicVarWithPrivateModulePropertyTypes: privateModule.publicClass;
|
|
export declare var publicAmbientVarWithPrivateModulePropertyTypes: privateModule.publicClass;
|
|
|
|
interface privateInterfaceWithPrivateModulePropertyTypes {
|
|
myProperty: privateModule.publicClass;
|
|
}
|
|
class privateClassWithPrivateModulePropertyTypes {
|
|
static myPublicStaticProperty: privateModule.publicClass;
|
|
myPublicProperty: privateModule.publicClass;
|
|
}
|
|
var privateVarWithPrivateModulePropertyTypes: privateModule.publicClass;
|
|
declare var privateAmbientVarWithPrivateModulePropertyTypes: privateModule.publicClass;
|
|
}
|
|
|
|
export interface publicInterfaceWithPrivatePropertyTypes {
|
|
myProperty: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4033: Property 'myProperty' of exported interface has or is using private name 'privateClass'.
|
|
}
|
|
|
|
export interface publicInterfaceWithPublicPropertyTypes {
|
|
myProperty: publicClass;
|
|
}
|
|
|
|
interface privateInterfaceWithPrivatePropertyTypes {
|
|
myProperty: privateClass;
|
|
}
|
|
|
|
interface privateInterfaceWithPublicPropertyTypes {
|
|
myProperty: publicClass;
|
|
}
|
|
|
|
export class publicClassWithWithPrivatePropertyTypes {
|
|
static myPublicStaticProperty: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4028: Public static property 'myPublicStaticProperty' of exported class has or is using private name 'privateClass'.
|
|
private static myPrivateStaticProperty: privateClass;
|
|
myPublicProperty: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4031: Public property 'myPublicProperty' of exported class has or is using private name 'privateClass'.
|
|
private myPrivateProperty: privateClass;
|
|
}
|
|
|
|
export class publicClassWithWithPublicPropertyTypes {
|
|
static myPublicStaticProperty: publicClass;
|
|
private static myPrivateStaticProperty: publicClass;
|
|
myPublicProperty: publicClass;
|
|
private myPrivateProperty: publicClass;
|
|
}
|
|
|
|
class privateClassWithWithPrivatePropertyTypes {
|
|
static myPublicStaticProperty: privateClass;
|
|
private static myPrivateStaticProperty: privateClass;
|
|
myPublicProperty: privateClass;
|
|
private myPrivateProperty: privateClass;
|
|
}
|
|
|
|
class privateClassWithWithPublicPropertyTypes {
|
|
static myPublicStaticProperty: publicClass;
|
|
private static myPrivateStaticProperty: publicClass;
|
|
myPublicProperty: publicClass;
|
|
private myPrivateProperty: publicClass;
|
|
}
|
|
|
|
export var publicVarWithPrivatePropertyTypes: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4025: Exported variable 'publicVarWithPrivatePropertyTypes' has or is using private name 'privateClass'.
|
|
export var publicVarWithPublicPropertyTypes: publicClass;
|
|
var privateVarWithPrivatePropertyTypes: privateClass;
|
|
var privateVarWithPublicPropertyTypes: publicClass;
|
|
|
|
export declare var publicAmbientVarWithPrivatePropertyTypes: privateClass; // Error
|
|
~~~~~~~~~~~~
|
|
!!! error TS4025: Exported variable 'publicAmbientVarWithPrivatePropertyTypes' has or is using private name 'privateClass'.
|
|
export declare var publicAmbientVarWithPublicPropertyTypes: publicClass;
|
|
declare var privateAmbientVarWithPrivatePropertyTypes: privateClass;
|
|
declare var privateAmbientVarWithPublicPropertyTypes: publicClass;
|
|
|
|
export interface publicInterfaceWithPrivateModulePropertyTypes {
|
|
myProperty: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4033: Property 'myProperty' of exported interface has or is using private name 'privateModule'.
|
|
}
|
|
export class publicClassWithPrivateModulePropertyTypes {
|
|
static myPublicStaticProperty: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4028: Public static property 'myPublicStaticProperty' of exported class has or is using private name 'privateModule'.
|
|
myPublicProperty: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4031: Public property 'myPublicProperty' of exported class has or is using private name 'privateModule'.
|
|
}
|
|
export var publicVarWithPrivateModulePropertyTypes: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4025: Exported variable 'publicVarWithPrivateModulePropertyTypes' has or is using private name 'privateModule'.
|
|
export declare var publicAmbientVarWithPrivateModulePropertyTypes: privateModule.publicClass; // Error
|
|
~~~~~~~~~~~~~
|
|
!!! error TS4025: Exported variable 'publicAmbientVarWithPrivateModulePropertyTypes' has or is using private name 'privateModule'.
|
|
|
|
interface privateInterfaceWithPrivateModulePropertyTypes {
|
|
myProperty: privateModule.publicClass;
|
|
}
|
|
class privateClassWithPrivateModulePropertyTypes {
|
|
static myPublicStaticProperty: privateModule.publicClass;
|
|
myPublicProperty: privateModule.publicClass;
|
|
}
|
|
var privateVarWithPrivateModulePropertyTypes: privateModule.publicClass;
|
|
declare var privateAmbientVarWithPrivateModulePropertyTypes: privateModule.publicClass;
|
|
} |