Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Added test.
  • Loading branch information
DanielRosenwasser committed May 1, 2019
1 parent c9eb846 commit 60962a8
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions tests/cases/compiler/omitTypeHelperModifiers01.ts
@@ -0,0 +1,22 @@
// @strict: true

type A = {
a: number;
b?: string;
readonly c: boolean;
d: unknown;
};

type B = Omit<A, 'a'>;

function f(x: B) {
const b = x.b;
x.b = "hello";
x.b = undefined;

const c = x.c;
x.c = true;

const d = x.d;
x.d = d;
}

0 comments on commit 60962a8

Please sign in to comment.