Skip to content

Completions in switch: don't include already-covered cases #13711

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ghost opened this issue Jan 27, 2017 · 0 comments · Fixed by #51790
Closed

Completions in switch: don't include already-covered cases #13711

ghost opened this issue Jan 27, 2017 · 0 comments · Fixed by #51790
Assignees
Labels
Domain: Completion Lists The issue relates to showing completion lists in an editor Experience Enhancement Noncontroversial enhancements Fix Available A PR has been opened for this issue Suggestion An idea for TypeScript
Milestone

Comments

@ghost
Copy link

ghost commented Jan 27, 2017

TypeScript Version: nightly (2.2.0-dev.20170126)

Code

/// <reference path='fourslash.ts'/>

////enum E { A, B }
////declare const e: E;
////switch (e) {
////    case E.A:
////        return 0;
////    case E./**/
////}

verify.completionsAt("", ["B"]);

Currently we get get both A and B.

@DanielRosenwasser DanielRosenwasser added Domain: Completion Lists The issue relates to showing completion lists in an editor Suggestion An idea for TypeScript labels Jan 27, 2017
@RyanCavanaugh RyanCavanaugh added the Experience Enhancement Noncontroversial enhancements label Aug 13, 2018
@RyanCavanaugh RyanCavanaugh added this to the Future milestone Aug 13, 2018
@weswigham weswigham removed the Suggestion An idea for TypeScript label Nov 6, 2018
@RyanCavanaugh RyanCavanaugh added the Suggestion An idea for TypeScript label Mar 7, 2019
@gabritto gabritto self-assigned this Feb 2, 2022
zardoy added a commit to zardoy/typescript-vscode-plugins that referenced this issue Sep 30, 2022
@typescript-bot typescript-bot added the Fix Available A PR has been opened for this issue label Dec 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Domain: Completion Lists The issue relates to showing completion lists in an editor Experience Enhancement Noncontroversial enhancements Fix Available A PR has been opened for this issue Suggestion An idea for TypeScript
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants