I have found a strange as for me way to declare a method in Objective C.

Method declaration in .h file:

-(void)methodName:(NSString *)str, int i;

Method implementation in .m file:

-(void)methodName:(NSString *)str, int i
{
     NSLog(@"str = %@, int = %d", str, i);
}

I can call this method like this:

[self methodName:@"stringExample", 99];

And it would work fine.

My question is when should I use such syntax. Is there any difference between it and usual declaration?

Edit
Report