Re: rangeOfString behaves wierd
Re: rangeOfString behaves wierd
- Subject: Re: rangeOfString behaves wierd
- From: Quincey Morris <email@hidden>
- Date: Mon, 09 Dec 2013 01:29:53 -0800
On Dec 9, 2013, at 01:00 , Stephen J. Butler <email@hidden> wrote:
> I don't get the same result. 10.9.0, Xcode 5.0.2. I created an empty
> command line utility, copied the code, and I get NSNotFound.
>
> 2013-12-09 02:50:19.822 Test[73850:303] main "见≠見" (3 shorts) occurs in
> "见=見見" (4 shorts) at {9223372036854775807, 0}
It’s not the same test if you just copy the code. I just tried that, and added the codepoint dump too:
> -[BPMAppDelegate applicationDidFinishLaunching:] "见≠見" (3 shorts) occurs in "见=見見" (4 shorts) at {9223372036854775807, 0}
> -[BPMAppDelegate printString:] "见=見見" has characters:
> {0, 1} = 0x89c1 = "见"
> {1, 1} = 0x003d = "="
> {2, 1} = 0x898b = "見"
> {3, 1} = 0x898b = "見"
> -[BPMAppDelegate printString:] "见≠見" has characters:
> {0, 1} = 0x89c1 = "见"
> {1, 1} = 0x2260 = "≠"
> {2, 1} = 0x898b = “見"
and the compatibility character has been changed to the unified one.
_______________________________________________
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