In my UITableViewCell subclass, I have the following code:
-(void)updateConstraints
{
static dispatch_once_t once;
dispatch_once(&once, ^ {
// Set constraints here
});
[super updateConstraints];
}
The constraints are only set for the first instance of the custom cell class. I don't really understand what's happening with the static token. I was under the impression that it is an instance-specific variable, but apparently it is class-scoped. Can anyone explain this?