-1
    const UIView * vLocalBottomButton = self.BottomButton;

    vLocalBottomButton =nil;

Basically I want to pass on self.BottomButton to a method that will run at outside the main thread. When the view is used, it'll be done at the main thread.

I just need to ensure that the view doesn't change. That's all. So I put it to a local variable and then pass that local variable to ensure that vLocalBottomButton didn't change.

Wolf
  • 9,246
  • 7
  • 59
  • 101
user4951
  • 31,039
  • 51
  • 162
  • 275

1 Answers1

3

You should create constant pointer. In your case:

UIView * const vLocalBottomButton = self.BottomButton;

//this won't compile therefore

vLocalBottomButton =nil;
Alexander Tkachenko
  • 3,192
  • 1
  • 32
  • 46