Want to know the whole character set whose characters have to be escaped in an Objective-C NSString object in order to be recognized properly, e.g. "
has to be escaped as \"
, as in
NSString *temporaryString = @"That book is dubbed as \"the little book\".";
Is the character set same with the one in C
language char *
string?
Thanks for your help :D
The only characters that have to be escaped are the "
(double-quote) and \
(backslash) characters.
There are other special character literals such as \n
that have special meaning but those are really a separate issue.
Objective-C NSString
values use the same set of special character literals as C.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With