Implicit 'this' return for void methods

Eirik Lygre eirik.lygre at
Tue Apr 1 21:20:34 UTC 2014

On Tue, Apr 1, 2014 at 6:37 PM, Guy Steele <guy.steele at> wrote:

> Then it sounds as if the three of us, at least, are very much in agreement
> about what is the appropriate scope for such a "naked dot" feature.
> > Am 01.04.2014 11:28, schrieb Bruce Chapman:
> >> More formally, the naked dot  (at the start of an expression, not
> following an invocation to a void method) would refer to the receiver of
> the innermost surrounding invocation expression.
> >>
> >> and so to answer Guy's question below in terms of my original intention
> rather than Ulf's proposal, .indexof("Q") would use myVeryLongNamedString
> as its receiver.
> >
> > My proposal was meant exactly as that. Maybe my wording was not clear
> enough in that.
> > -Ulf
> >
What is the relationship between this "naked dot" proposal and the
"chaining of void methods" proposal? The reason for asking is not to be
negative, but rather to find out if these issues are best dealt with
together, or as independent proposals.

I think that if either of these are going to happen, then they must be
specified with the appropriate level of isolation: That which belongs
together must be processed together; that which belongs apart must be
processed apart.

More information about the core-libs-dev mailing list