This feels like a work around for bad coders to avoid fixing their code-smell. If I saw this in code I was working on, I’d change the underlying code to not be bad.
I agree with you. This post has the scope to explain the Non-null assertion operator.
In a real case, maybe you can't change the code behind because it's in an external dependence; in this case, I would prefer to use an Assert Function, but it is a topic of a future post.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
This feels like a work around for bad coders to avoid fixing their code-smell. If I saw this in code I was working on, I’d change the underlying code to not be bad.
I agree with you. This post has the scope to explain the Non-null assertion operator.
In a real case, maybe you can't change the code behind because it's in an external dependence; in this case, I would prefer to use an Assert Function, but it is a topic of a future post.