Closed
Description
Having a singleton type type A = "a" | "b"
, a variable const a: A = "a"
, and an expression a === "c"
, the compiler should infer the type of "c"
as A
and make the expression unsound.
Currently (1.8.0 and 1.9.0-dev.20160206) it compiles, which makes usage of singleton types instead of enums less type safe.