deno_lint icon indicating copy to clipboard operation
deno_lint copied to clipboard

fix: allow blank lines and comments in cases that do not stop execution

Open koh28 opened this issue 1 month ago • 3 comments

Fixes #1196

This PR allows:

switch (number) {
  case 1:
    // comment
  case 2:
    doSomething();
}
switch (number) {
  case 1:
    
  case 2:
    doSomething();
}

but does not allow:

switch (number) {
  case 1:
    // comment
    doSomething();
  case 2:
    doSomething();
}

koh28 avatar May 13 '24 07:05 koh28

CLA assistant check
All committers have signed the CLA.

CLAassistant avatar May 13 '24 07:05 CLAassistant

Hey @koh28, thanks for the PR. Can you please sign the CLA so we can land this PR?

bartlomieju avatar May 14 '24 20:05 bartlomieju

I signed it

koh28 avatar May 15 '24 07:05 koh28