Hi Jasper !
As per your code, firstly in the main() method you have created two references variable
"one" and
"two" which are pointing to the object of
"A" and
"B" respectively.
Then you have invoked the method setB() and you are passing the reference variable
"two" which is pointing to Object of class B
to the reference variable
"b" which is also of type B (class B)
So
"two" and "b" both are pointing to Class B object
so how come there is a circular reference.?
Same is done with the reference variable
"one"