by chi3 · 8y ago · 0 comments
Seems weird to me to say that Java "passes by value" when all objects being passed are actually references to objects.
Technically yes, but since the language doesn't let you talk about references directly, the concept rarely comes up. Like, in theory you could say "a is a reference that refers to a value of type Foo", but people don't actually say that; they just say "a is of type Foo".
> Seems weird to me to say that Java "passes by value" when all objects being passed are actually references to objects.
Indeed, completely agreed.