• 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
unicode warning in ObjC
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

unicode warning in ObjC


  • Subject: unicode warning in ObjC
  • From: Hans van der Meer <email@hidden>
  • Date: Tue, 11 Sep 2007 11:09:39 +0200

The following statement:
unichar character = [[NSString stringWithUTF8String: "\u03C0"] characterAtIndex: 0];
gives me a warning message in XCode:
warning: universal character names are only valid in C++ and C99


This confuses me. I was under the impression that NSString can contain and can handle characters in 16bit Unicode. Either I am doing something wrong or I misunderstood something.

What do I have to do to get \u03C0 (the character pi) correctly and without warning in my NSString's?

Hans van der Meer



_______________________________________________

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: unicode warning in ObjC
      • From: Martin Wierschin <email@hidden>
  • Prev by Date: CoreData NSPersistentDocument Tutorial question
  • Next by Date: Re: unicode warning in ObjC
  • Previous by thread: Re: CoreData NSPersistentDocument Tutorial question
  • Next by thread: Re: unicode warning in ObjC
  • Index(es):
    • Date
    • Thread