Re: Public API method naming for NSString * / const char * parameters
Re: Public API method naming for NSString * / const char * parameters
- Subject: Re: Public API method naming for NSString * / const char * parameters
- From: Kyle Sluder <email@hidden>
- Date: Mon, 03 Mar 2014 11:23:04 -0800
On Mon, Mar 3, 2014, at 09:54 AM, Daniel DeCovnick wrote:
> Given that, UTF8Name actually sounds fine.
No it doesn't. There's nothing in Jonathan's links to suggest that the
CLS specifies that identifiers are stored in UTF-8 encoding. In fact, it
implies otherwise:
"""Before you compare identifiers, you should filter out formatting
codes and convert the identifiers to Unicode Normalization Form C,
because a single character can be represented by multiple UTF-16-encoded
code units. """
But Jonathan, why are you even exposing raw C pointer access to the
identifiers in the first place? Why wouldn't you convert them to
NSStrings and only expose them to Objective-C code that way?
--Kyle Sluder
_______________________________________________
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