• 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: ASL & Unicode in Xcode's Console
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ASL & Unicode in Xcode's Console


  • Subject: Re: ASL & Unicode in Xcode's Console
  • From: Jason Coco <email@hidden>
  • Date: Wed, 29 Oct 2008 01:27:17 -0400


On Oct 29, 2008, at 00:29 , Adam R. Maxwell wrote:


On Oct 28, 2008, at 9:14 PM, Jason Coco wrote:


On Oct 28, 2008, at 16:53 , Sean McBride wrote:

On 10/28/08 4:03 PM, Jason Coco said:

Also, you should not be using non-ascii characters in string
literals :) hopefully you're just doing this to demonstrate the issue.
You should
be doing something like this:


char *hiragana_a = { 0xE3, 0x81, 0x82, 0x00 };
NSLog(@"%@", [NSString stringWithCString:a
encoding:NSUTF8StringEncoding]);

That is no longer necessary in 10.5 / Xcode 3. You can use Unicode in
string literals in Objective-C.

Why do you say this? I thought that I may have missed something, but looking
back through all the documentation, all the warnings about only including 7-bit ASCII
characters in string literals still exist... even in the most recent updated documentation.

ISTR seeing this in the release notes somewhere, but can't find it now either. Anyway, see


http://lists.apple.com/archives/Cocoa-dev/2008/Apr/msg01885.html

Well, I still can't find anything that says this other than somebody's statement on a mailing list... the three
most recently updated documents that apple put out dealing with strings all specifically say that string
literals (CFStringRef, NSConstantString and c style string constants) all must be 7-bit ascii encoded
or they may not work at all times, even if they appear to work for you. Since GCC itself is still struggling
with this, I'm just gonna go with those documents until I see them change or see something more
prominent come out from Apple. By the way, I also dug through the source for the gcc 4.0.1 compiler
that's used by default with Xcode 3.0 and there was nothing about this change in the apple change logs
or any of the other change logs or files that I could find. I didn't bother looking through the 4.2 stuff
since most people are probably not even using it yet :)


Attachment: smime.p7s
Description: S/MIME cryptographic signature

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: ASL & Unicode in Xcode's Console
      • From: "Sean McBride" <email@hidden>
References: 
 >ASL & Unicode in Xcode's Console (From: Karl Moskowski <email@hidden>)
 >Re: ASL & Unicode in Xcode's Console (From: Jason Coco <email@hidden>)
 >Re: ASL & Unicode in Xcode's Console (From: "Sean McBride" <email@hidden>)
 >Re: ASL & Unicode in Xcode's Console (From: Jason Coco <email@hidden>)
 >Re: ASL & Unicode in Xcode's Console (From: "Adam R. Maxwell" <email@hidden>)

  • Prev by Date: Re: Problem with NSData to NSString to NSData
  • Next by Date: Re: inter-object communication
  • Previous by thread: Re: ASL & Unicode in Xcode's Console
  • Next by thread: Re: ASL & Unicode in Xcode's Console
  • Index(es):
    • Date
    • Thread