tests/cases/conformance/statements/returnStatements/invalidReturnStatements.ts(2,17): error TS2355: A function whose declared type is neither 'undefined', 'void', nor 'any' must return a value.
tests/cases/conformance/statements/returnStatements/invalidReturnStatements.ts(3,17): error TS2355: A function whose declared type is neither 'undefined', 'void', nor 'any' must return a value.
tests/cases/conformance/statements/returnStatements/invalidReturnStatements.ts(4,17): error TS2355: A function whose declared type is neither 'undefined', 'void', nor 'any' must return a value.
tests/cases/conformance/statements/returnStatements/invalidReturnStatements.ts(5,17): error TS2355: A function whose declared type is neither 'undefined', 'void', nor 'any' must return a value.
tests/cases/conformance/statements/returnStatements/invalidReturnStatements.ts(16,22): error TS2739: Type '{ id: number; }' is missing the following properties from type 'D': name, dispose
tests/cases/conformance/statements/returnStatements/invalidReturnStatements.ts(18,22): error TS2741: Property 'name' is missing in type 'C' but required in type 'D'.


==== tests/cases/conformance/statements/returnStatements/invalidReturnStatements.ts (6 errors) ====
    // all the following should be error
    function fn1(): number {  }
                    ~~~~~~
!!! error TS2355: A function whose declared type is neither 'undefined', 'void', nor 'any' must return a value.
    function fn2(): string { }
                    ~~~~~~
!!! error TS2355: A function whose declared type is neither 'undefined', 'void', nor 'any' must return a value.
    function fn3(): boolean { }
                    ~~~~~~~
!!! error TS2355: A function whose declared type is neither 'undefined', 'void', nor 'any' must return a value.
    function fn4(): Date {  }
                    ~~~~
!!! error TS2355: A function whose declared type is neither 'undefined', 'void', nor 'any' must return a value.
    function fn7(): any {  } // should be valid: any includes void
    
    interface I { id: number }
    class C implements I {
        id: number;
        dispose() {}
    }
    class D extends C {
        name: string;
    }
    function fn10(): D { return { id: 12 }; } 
                         ~~~~~~
!!! error TS2739: Type '{ id: number; }' is missing the following properties from type 'D': name, dispose
    
    function fn11(): D { return new C(); }
                         ~~~~~~
!!! error TS2741: Property 'name' is missing in type 'C' but required in type 'D'.
!!! related TS2728 tests/cases/conformance/statements/returnStatements/invalidReturnStatements.ts:14:5: 'name' is declared here.
    
    