Skip to content
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

Support single-line comment for "falls through" #2114

Open
cowwoc opened this issue Jan 20, 2015 · 2 comments
Open

Support single-line comment for "falls through" #2114

cowwoc opened this issue Jan 20, 2015 · 2 comments
Labels

Comments

@cowwoc
Copy link

cowwoc commented Jan 20, 2015

Following up on #18 please allow:

// falls through instead of just /* falls through */

@KylePDavis
Copy link

I would also like to see this. 👍

I've also noticed (also mentioned in #18) this seems to stop working if I add whitespace or comments between the two cases:

var t = typeof obj;
switch (t) {
  case "object":
    obj = String(obj);
    /* falls through */
    //  ...stops working if whitespace or comments are placed here...
  case "string":
    console.log(obj);
}

@pygy
Copy link

pygy commented Jun 20, 2015

I have this in my code, currently:

// fall through for handling declarations. The next line is for JSHint.
/* falls through */

It would b nice if it could simply be

// falls through for handling declarations.

or

/* falls through */
/* ... for handling declarations.*/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants