tests/cases/compiler/file.js(11,1): error TS2322: Type '"z"' is not assignable to type '"x" | "y"'.


==== tests/cases/compiler/file.js (1 errors) ====
    // @ts-check
    const obj = {
        x: 1,
        y: 2
    };
    
    /**
     * @type {keyof typeof obj}
     */
    let selected = "x";
    selected = "z"; // should fail
    ~~~~~~~~
!!! error TS2322: Type '"z"' is not assignable to type '"x" | "y"'.
    