[1740] Fix for possible null reference in Linq results in invalid code


This is working code.  When I hover over the 'entry' parameter on each line, R# is warning me that there is a "Possible 'System.NullReferenceException'" and offers a action list with "check if 'entry' is not null"
8-12-2010 1-34-43 PM.png
When I allow R# to fix it, it gives me this, which is _NOT_ working code

8-12-2010 1-39-03 PM.png

Attached is a .zip with the solution containing this code in Controllers\TwitterController.cs



Attachment(s):
Twitter Solution.zip
1 comment
Comment actions Permalink

Hello Richard,

Thank you very much for reporting this problem! I've created a bug-report
in our tracker: http://youtrack.jetbrains.net/issue/RSRP-188296 and you're
welcome to monitor its status.

Andrey Serebryansky
Support Engineer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"

This is working code.  When I hover over the 'entry' parameter on each
line, R# is warning me that there is a "Possible
'System.NullReferenceException'" and offers a action list with "check
if 'entry' is not null"
Image:8-12-2010 1-34-43 PM.png
When I allow R# to fix it, it gives me this, which is NOT working
code
Image:8-12-2010 1-39-03 PM.png

Attached is a .zip with the solution containing this code in
Controllers\TwitterController.cs

---
Original message URL:
http://devnet.jetbrains.net/message/5270047#5270047



0

Please sign in to leave a comment.