-
Notifications
You must be signed in to change notification settings - Fork 2k
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
1.1.3: existential @var? doesn't check for undefined #1869
Comments
Most minimal test case does work:
|
See #1631 |
Whoops, didn't realise it was you. Here's a more complete explanation: |
Apologies, I did search, but nothing came up that seemed relevant. There are so many closed issues now that searching through them is tiresome. Thanks for your patience. It is disappointing that there doesn't seem to be a good solution for this issue. I was hoping to write some code that checked for null or undefined and there doesn't seem to be a good syntactic way to do that in CS. |
@lookfirst:
|
What I'd like to do is write this:
What I ended up having to write is this:
Maybe I'm just not understanding things correctly. |
@lookfirst: you're not understanding things correctly. |
@lookfirst: Googling for |
Ok, thanks for the pointers. I'm understanding things a lot more clearly now. Again, thanks for your patience. |
@alpha123: wow, I'm surprised how effective that is. Google's amazing. Thanks for the tip. |
We should start a drinking game for every time this comes up ;) |
For all the beer I owe MF, we'd have to check him and his cute fuzzy bear into rehab after it. |
This seems like a pretty minimal test case:
outputs:
According to the documentation, "CoffeeScript's existential operator ? returns true unless a variable is null or undefined"
correctly outputs:
The text was updated successfully, but these errors were encountered: