<html><head><meta http-equiv="Content-Type" content="text/html; charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class=""><br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On Mar 28, 2018, at 3:07 PM, John McCall <<a href="mailto:rjmccall@apple.com" class="">rjmccall@apple.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class="">Now, there's an idea we've been kicking around for a long time to support typed selectors; I guess they would look something like</div><div style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""> SEL<NSString*()></div><div style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class="">for the type of</div><div style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""> - (NSString*) foo;</div></div></blockquote></div><br class=""><div class=""><br class=""></div><div class="">I'm not a stickler for exactly what gets done. My goal is to be able to write code like that below. I'm open to any idea that allows templating to utilize objc method declarations as easily as can utilize c++ class member function declarations. My end goal in posting to the list is to make the cocoa programming experience from c++ be as convenient and complete as possible. the objc++ compiler is one of the best pieces of software that Apple has engineered. The experience can be improved significantly by filling in a few gaps.</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""></div><div class="">std::packaged_task< int (cTest*, NSString*) > tmpTask( @lambda( -[cMyClass methodUsingString:] ) );<br class="">auto tmpCFuture = tmpTask.get_future();<br class=""><br class="">auto tmpCPtr = [[[cTest alloc] init] autorelease];<br class=""><br class="">tmpTask( tmpCPtr, @"hello world" );<br class=""><br class="">auto tmpResult = tmpCFuture.get();</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><br class=""></div></body></html>