60 lines
1.1 KiB
Plaintext
60 lines
1.1 KiB
Plaintext
==== tests/cases/conformance/internalModules/DeclarationMerging/ClassAndModuleThatMergeWithModuleMemberThatUsesClassTypeParameter.ts (5 errors) ====
|
|
// all expected to be errors
|
|
|
|
class clodule1<T>{
|
|
|
|
id: string;
|
|
value: T;
|
|
}
|
|
|
|
module clodule1 {
|
|
function f(x: T) { }
|
|
~
|
|
!!! Cannot find name 'T'.
|
|
}
|
|
|
|
class clodule2<T>{
|
|
|
|
id: string;
|
|
value: T;
|
|
}
|
|
|
|
module clodule2 {
|
|
var x: T;
|
|
~
|
|
!!! Cannot find name 'T'.
|
|
|
|
class D<U extends T>{
|
|
~
|
|
!!! Cannot find name 'T'.
|
|
id: string;
|
|
value: U;
|
|
}
|
|
}
|
|
|
|
class clodule3<T>{
|
|
|
|
id: string;
|
|
value: T;
|
|
}
|
|
|
|
module clodule3 {
|
|
export var y = { id: T };
|
|
~
|
|
!!! Cannot find name 'T'.
|
|
}
|
|
|
|
class clodule4<T>{
|
|
|
|
id: string;
|
|
value: T;
|
|
}
|
|
|
|
module clodule4 {
|
|
class D {
|
|
name: T;
|
|
~
|
|
!!! Cannot find name 'T'.
|
|
}
|
|
}
|
|
|