Transferred from: http://blog.csdn.net/shenshen123jun/article/details/38315755
Bookmark it for your own convenience.
Accidentally in the development process, got (null) and the return value of <null>, looked for a long time only found a about <null>.
Because it is necessary to determine the response based on the return value, you must know the specific character that the return value represents, and when you get (NULL) Take advantage of isequal: and @ "", null,@ "(null)", Nil,nil not get the correct result after comparison, But still feel like nil, forced to create a string, assignment to nil, printout, sure enough is (null), what is not the reason for the difference. Finally tried "= =", success. After a struggle to understand the original to use:
if (M_result==nil)
{
NSLog (@ "kda!");
}
There is <null>, from the Internet to find the usage:
if ([M_result isequal:[nsnull null]])
{
NSLog (@ "kda!");
}
The problem is simple, can not find the reason to solve the difficult, not by sigh, the basis of the most important AH.
Write down, hope can help others a little bit is enough.
Processing in IOS development (null) and <null>