1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99
|
tests/cases/compiler/qualify.ts(21,13): error TS2322: Type '3' is not assignable to type 'I'.
tests/cases/compiler/qualify.ts(30,13): error TS2322: Type '3' is not assignable to type 'I2'.
tests/cases/compiler/qualify.ts(45,13): error TS2322: Type 'I4' is not assignable to type 'I3'.
Property 'zeep' is missing in type 'I4'.
tests/cases/compiler/qualify.ts(46,13): error TS2322: Type 'I4' is not assignable to type 'I3[]'.
Property 'length' is missing in type 'I4'.
tests/cases/compiler/qualify.ts(47,13): error TS2322: Type 'I4' is not assignable to type '() => I3'.
Type 'I4' provides no match for the signature '(): I3'
tests/cases/compiler/qualify.ts(48,13): error TS2322: Type 'I4' is not assignable to type '(k: I3) => void'.
Type 'I4' provides no match for the signature '(k: I3): void'
tests/cases/compiler/qualify.ts(49,13): error TS2322: Type 'I4' is not assignable to type '{ k: I3; }'.
Property 'k' is missing in type 'I4'.
tests/cases/compiler/qualify.ts(58,5): error TS2322: Type 'I' is not assignable to type 'T.I'.
Property 'p' is missing in type 'I'.
==== tests/cases/compiler/qualify.ts (8 errors) ====
module M {
export var m=0;
export module N {
export var n=1;
}
}
module M {
export module N {
var y=m;
var x=n+y;
}
}
module T {
export interface I {
p;
}
export module U {
var z:I=3;
~
!!! error TS2322: Type '3' is not assignable to type 'I'.
export interface I2 {
q;
}
}
}
module Peer {
export module U2 {
var z:T.U.I2=3;
~
!!! error TS2322: Type '3' is not assignable to type 'I2'.
}
}
module Everest {
export module K1 {
export interface I3 {
zeep;
}
}
export module K2 {
export interface I4 {
z;
}
var v1:I4;
var v2:K1.I3=v1;
~~
!!! error TS2322: Type 'I4' is not assignable to type 'I3'.
!!! error TS2322: Property 'zeep' is missing in type 'I4'.
var v3:K1.I3[]=v1;
~~
!!! error TS2322: Type 'I4' is not assignable to type 'I3[]'.
!!! error TS2322: Property 'length' is missing in type 'I4'.
var v4:()=>K1.I3=v1;
~~
!!! error TS2322: Type 'I4' is not assignable to type '() => I3'.
!!! error TS2322: Type 'I4' provides no match for the signature '(): I3'
var v5:(k:K1.I3)=>void=v1;
~~
!!! error TS2322: Type 'I4' is not assignable to type '(k: I3) => void'.
!!! error TS2322: Type 'I4' provides no match for the signature '(k: I3): void'
var v6:{k:K1.I3;}=v1;
~~
!!! error TS2322: Type 'I4' is not assignable to type '{ k: I3; }'.
!!! error TS2322: Property 'k' is missing in type 'I4'.
}
}
interface I {
k;
}
var y:I;
var x:T.I=y;
~
!!! error TS2322: Type 'I' is not assignable to type 'T.I'.
!!! error TS2322: Property 'p' is missing in type 'I'.
|