Use of * in Objective C Syntax
- by user263097
I'm struggling a bit with some objective c syntax. Can someone please elaborate on the usage of * in the following instance method.
- (IBAction)sliderChanged:(id)sender{
UISlider *slider = (UISlider *)sender;
}
I realize that we are creating a variable typed as UISlider and then setting it to sender once it is cast as a UISlider. However, I don't understand what the * are for and why
UISlider slider = (UISlider)sender;
won't work.