Swift Block value error

前端 未结 1 1121
萌比男神i
萌比男神i 2021-01-24 05:02

I keep getting a finish block error in swift. The error is:

Cannot call value of non-function type\'((Array,Array)->())!

There\'s an

1条回答
  •  没有蜡笔的小新
    2021-01-24 05:27

    Don't specify the argument labels when you call blockFinih. You've defined it to have no argument labels. The parameters selectedTags and unSelectedTags can only be used inside the function, not by the caller.

    Change:

    self.blockFinih(selectedTags: selected, unSelectedTags: unSelected)
    

    to:

    self.blockFinih(selected, unSelected)
    

    0 讨论(0)
提交回复
热议问题