Q
Q
qw12017-03-10 11:11:38
IntelliJ IDEA
qw1, 2017-03-10 11:11:38

R# parser error or potential code error?

Do I understand correctly that the construction <expression> is <type name> cannot be true if <expression> = null?

Then why does the "Possible NullReferenceException" warning occur:
d9f9b2ef723b4d80bf4fd25b88d2f1f4.png

How to rewrite correctly so that the warning disappears?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question