tests/cases/compiler/propertyElementAccessOnVoidNoImplicitAnyFalse01.ts(6,5): error TS2797: Object is possibly 'void'.
tests/cases/compiler/propertyElementAccessOnVoidNoImplicitAnyFalse01.ts(7,5): error TS2797: Object is possibly 'void'.
tests/cases/compiler/propertyElementAccessOnVoidNoImplicitAnyFalse01.ts(7,12): error TS2339: Property 'world' does not exist on type 'void'.
tests/cases/compiler/propertyElementAccessOnVoidNoImplicitAnyFalse01.ts(10,17): error TS2797: Object is possibly 'void'.
tests/cases/compiler/propertyElementAccessOnVoidNoImplicitAnyFalse01.ts(11,17): error TS2797: Object is possibly 'void'.
tests/cases/compiler/propertyElementAccessOnVoidNoImplicitAnyFalse01.ts(11,24): error TS2339: Property 'world' does not exist on type 'void'.


==== tests/cases/compiler/propertyElementAccessOnVoidNoImplicitAnyFalse01.ts (6 errors) ====
    let result = [1, 2, 3, 4].forEach(x => {
        console.log(x);
    });
    
    if (Math.random()) {
        result["hello"] = "foo";
        ~~~~~~
!!! error TS2797: Object is possibly 'void'.
        result.world = "foo";
        ~~~~~~
!!! error TS2797: Object is possibly 'void'.
               ~~~~~
!!! error TS2339: Property 'world' does not exist on type 'void'.
    }
    else {
        console.log(result["hello"]);
                    ~~~~~~
!!! error TS2797: Object is possibly 'void'.
        console.log(result.world);
                    ~~~~~~
!!! error TS2797: Object is possibly 'void'.
                           ~~~~~
!!! error TS2339: Property 'world' does not exist on type 'void'.
    }