diff --git a/tests/cases/compiler/partiallyDiscriminantedUnions.ts b/tests/cases/compiler/partiallyDiscriminantedUnions.ts index 48fac4a7ac99d..b4f89951f4cdb 100644 --- a/tests/cases/compiler/partiallyDiscriminantedUnions.ts +++ b/tests/cases/compiler/partiallyDiscriminantedUnions.ts @@ -38,9 +38,9 @@ function isShape(s : Shapes): s is Shape { } function fail(s: Shapes) { -if (isShape(s)) { - if (s.kind === "circle") { - let c: Circle = s; + if (isShape(s)) { + if (s.kind === "circle") { + let c: Circle = s; + } } -} } \ No newline at end of file