Re: Getting a bullet into a NSString
Re: Getting a bullet into a NSString
- Subject: Re: Getting a bullet into a NSString
- From: mmalcolm crawford <email@hidden>
- Date: Wed, 15 Mar 2006 16:23:58 -0800
On Mar 15, 2006, at 12:08 PM, Camillo Lugaresi wrote:
Actually, what John suggested will either work or break at compile
time.
It's not clear why this is relevant.
You typically compile more than once during the lifetime of a
project, and often more than one person uses more than one set of tools.
A trivial example was given:
NSString *s = [NSString stringWithUTF8String:"Long — dash"];
If you use this, you are (as Ali pointed out) "at the mercy of the
tools". When someone uses a tool that reinterprets the file
encoding, or copies this line into a different file that isn't UTF-8
encoded, it'll stop working. You'll then have a hard-to-track-down
bug that it's quite possible will first be found by a customer
(generally Not A Good Thing)...
Over the last few years we've had more questions than I can remember
about this issue. Considerably more effort has been expended in this
thread and others like it to diagnose and remedy the "problem" than
would have been spent had developers simply used a better, fully
supported, "things won't go obscurely wrong" way in the first place.
"Don't do it" remains prudent advice...
mmalc
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden