unreachable code detection for switch cases out of range of string literal types · Issue #6149 · microsoft/TypeScript (original) (raw)

Skip to content

Provide feedback

Saved searches

Use saved searches to filter your results more quickly

Sign up

@zpdDG4gta8XKpMCd

Description

@zpdDG4gta8XKpMCd

type foo = 'hey' | 'nay';

switch (undefined) { case 'boom': console.log('never the case'); break; // expected unreachable code, actual no problem }

Metadata

Metadata

Labels

Development

No branches or pull requests

Issue actions