Anyone on the core team like to say anything?<br><div class="gmail_quote"><div dir="ltr">On Fri, Dec 30, 2016 at 9:15 AM Derrick Ho <<a href="mailto:wh1pch81n@gmail.com">wh1pch81n@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I'm trying to revive an old thread. I'd like to hear from the community.<br class="gmail_msg"><br class="gmail_msg">Can we make a swift enum string interoperable with Objective-C?<br class="gmail_msg"><br class="gmail_msg">Currently NS_STRING_ENUM ports from objective-c to swift but not the other way around.<br class="gmail_msg"><br class="gmail_msg">I feel that if you can go one direction you should be able to go back.<br class="gmail_msg"><br class="gmail_msg">@objc<br class="gmail_msg">enum City: String {<br class="gmail_msg"> case NewYork = "New York"<br class="gmail_msg">} <br class="gmail_msg"><br class="gmail_msg">Make this available as a global string in objective -c ?<br class="gmail_msg"><div class="gmail_quote gmail_msg"><div dir="ltr" class="gmail_msg">On Wed, Nov 23, 2016 at 5:55 AM Derrick Ho <<a href="mailto:wh1pch81n@gmail.com" class="gmail_msg" target="_blank">wh1pch81n@gmail.com</a>> wrote:<br class="gmail_msg"></div><blockquote class="gmail_quote gmail_msg" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="white-space:pre-wrap" class="gmail_msg">I think enum strings should gain better interoperability with swift. Something like this:
enum City: String {
case NewYork = "New York"
}
This can be ported over to Objective-c like this:
typedef NSString * City;
static City const City_NewYork = @"New York";<br class="gmail_msg"></div>
</blockquote></div></blockquote></div>