7 ms·
It is indeed ugly. Having switched full-time to Kotlin a little less than a year ago, I honestly prefer their approach to String interpolation using `${var}`.
by Alupis 4y ago
It is indeed ugly. Having switched full-time to Kotlin a little less than a year ago, I honestly prefer their approach to String interpolation using `${var}`.
I understand Java has a backwards compatibility issue that Kotlin does not though, which would make breaking changes to all the hard-coded strings containing `$` that would now need to be escaped. This is discussed in the JEP.
Backwards compatibility - simultaneously Java's strongest and weakest asset.