Instance Variable scope rules


#1

Hi,

I suppose the default scope for ivars is @protected.

I declared a variable like this in the header file of a class:

{
int _test1;
}

But I could print this variable _test1 using NSLog in a totally unrelated object.

NSLog(@"%d", _test1);

Why is _test1 available to the second object?

Thanks in advance.