I agree to your statement that yield_self is not a good, descriptive

name.

Though I have to admit that I never used yield_self so far. I can

not even say what it does, either. :)

I like yield and self. I don't like the name yield_self so I could

not use it so far. I use only a subset of ruby that makes sense

to me and I find appealing. Thankfully one can use ruby just fine

without having to use everything.

After reconsidering a lot of options, my current

proposal is: #then.

I dislike that as well. I also do not think that "then"

makes a lot of sense.

For example:

File.read(filename).then(&JSON.method(:parse))

This is regular method chaining. But it sounds like

you are using a conditional there.

"then" is already a keyword in ruby isn't it?

https://docs.ruby-lang.org/en/2.5.0/keywords_rdoc.html

I think it is confusing to have keywords and method names,

even more so when they do different things.

In many languages, .then or .and_then is useful construct, meaning

the same (calculate next value from the result of the previous

operation), just in a narrower context of futures/promises.

Realistically ruby should strive for intrinsic consistency first,

not for what features or anti-features other languages may or

may not have.

I believe that even when/if Ruby will have those as a

language feature, that syntax will play well:

value.then(&:computation) # => value promise.then(&:computation) # => promise

I don't think it reads nicely really.

yield_self is not a good name but your proposal is also

not good, in my opinion. But it's just a personal opinion,

feel free to ignore it. At the end of the day you only have

to convince matz. :)

The name yield_self is however had indeed not a good name.

Finding good names is quite difficult. Single words are

also almost always better than combined names, even though

one is a bit limited with single words alone. There are

exceptions though. For example .each_with_index or

.each_index are good names, IMO.