[swift-users] disambiguate selector
jtbandes at gmail.com
Fri Jan 13 14:29:41 CST 2017
I filed a bug for this recently: https://bugs.swift.org/browse/SR-3550
On Fri, Jan 13, 2017 at 12:16 PM, J.E. Schotsman via swift-users <
swift-users at swift.org> wrote:
> When I wrote this:
> table.performSelector( onMainThread:#selector(NSTableView.reloadData) )
> I got a message “Ambiguous reference to member 'reloadData()”
> With a little help from Stackoverflow I managed to fix it:
> #selector(NSTableView.reloadData as (NSTableView) -> ((Void)->Void)))
> My question is: why can’t I just write
> as opposed to
> Jan E.
> BTW the use of “onMainThread" as a label for a selector appears a bit
> strange to me.
> swift-users mailing list
> swift-users at swift.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the swift-users