[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: stringWithString question
From: |
Sherm Pendley |
Subject: |
Re: stringWithString question |
Date: |
Sun, 03 Jul 2005 16:58:25 -0400 |
User-agent: |
Gnus/5.1007 (Gnus v5.10.7) XEmacs/21.4.17 (Jumbo Shrimp, linux) |
Rob Burns <foobix@comcast.net> writes:
> NSString str = [NSString stringWithString: @"\10, 11, 12, 13"];
Shouldn't that be:
NSString *str ...
^
> If I have that line of code, the first character of str will be a
> comma. if I add another backslash at the beginning, the first
> character of str will be a backslash. I would expect that behaviour
> for stringWithFormat: But, should escaping the backslash be necessary
> when using stringWithString?
Yes, since constant strings can contain escapes such as "\t" (tab).
sherm--
--
Due to the amount of unreadable gibberish being posted from Google Groups,
I seldom read messages posted from there.
Cocoa/Perl: http://camelbones.sf.net Hire Me: http://www.dot-app.org