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

Some issues to discuss #6

Closed
mwager opened this issue Feb 26, 2016 · 1 comment
Closed

Some issues to discuss #6

mwager opened this issue Feb 26, 2016 · 1 comment

Comments

@mwager
Copy link

mwager commented Feb 26, 2016

Hey, I really like your project and it looks good to our team. There are some issues though I want to discuss here:

1) Loop variables are never read

for key, val of someObject
  doSomethingWith(val)

gives me:

✗ #1: Variable "key" is never read ( first defined on line 1).

Is there an option to ignore this? I know I could write this in another way but it's nice to use the for ... of syntax here.

2) Undefined identifier if used before defined

foo()

foo = ->
  return 1

gives:

✗ #1: Undefined identifier "foo".
✗ #3: Variable "foo" is never read ( first defined on line 3).

This cannot be correct because foo is defined within the scope.

3) Variable never read

describe 'some spec', ->

  foo = null

  beforeEach ->
    foo = 1

gives:

✗ #3: Variable "foo" is never read ( first defined on line 3).
✗ #6: Variable "foo" is never read ( first defined on line 3).

Same:

intervalId = setInterval ->
  clearInterval intervalId
, 50

-> Variable "intervalId" is never read

@za-creature
Copy link
Owner

Thanks for the reports!

To ease communication and tracking, I'm going to split all mentioned issues in separate requests!

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

No branches or pull requests

2 participants