• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: checking for line ending types
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: checking for line ending types


  • Subject: Re: checking for line ending types
  • From: mmalcolm crawford <email@hidden>
  • Date: Sat, 27 Nov 2004 19:37:25 -0800


On Nov 27, 2004, at 5:03 PM, Andrew Farmer wrote:

Good day, Hunter. Your code looks fine, but you should note that the method -[NSString cString] will, according too Apple's NSString class docs, be 'deprecated in the near future.' They instead recommend that one use 'UTF8String to convert arbitrary NSStrings to a lossless 8-bit representation.'
Except that if your input isn't UTF-8, -[NSString UTF8String] may give you screwed-up results. -[NSString cString] has its place.

As noted in another thread, cString should be considered deprecated (it's flagged as thus in the documentation). If you're not using UTF8, you are encouraged to use dataUsingEncoding:allowLossyConversion: etc. instead.

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


References: 
 >Re: checking for line ending types (From: Andrew Merenbach <email@hidden>)
 >Re: checking for line ending types (From: Andrew Farmer <email@hidden>)

  • Prev by Date: Re: checking for line ending types
  • Next by Date: Re: IBPalette refuses to bring up inspector [SOLVED]
  • Previous by thread: Re: checking for line ending types
  • Next by thread: Re: Checking for line ending types
  • Index(es):
    • Date
    • Thread