Excuse the double-entendre-filled subject for this post

I read an interesting tidbit on the PHP site:

"Objects of the same type will have access to each others private and protected members even though they are not the same instances. This is because the implementation specific details are already known when inside those objects."

PHP Code:

class Foo {
    public function 
__construct($value) {
$this->bar $value;
    public function 
getOtherBar($otherObject) {

$a = new Foo('baz');
$b = new Foo('ban');


Am I wrong in thinking that the above code should (in theory/ a perfect world) cause an error? Or am I missing something fundemental with relation to OO?