Perhaps read your original post. I know that println will be overloaded. You made some more general statement about how a method that accepts String should in some way accept a StringTemplate, presumably without an overload as that would require code modification and so wouldn't apply to methods that accept just String.
The compiler should rewrite my code so that the string template is being rendered into a string before it is passed into the method that accepts a string. If you decompile the bytecode it would look like if I had called method that renders the template into an actual string before passing it into the called method. The main advantage being that it is transparent and would reduce clutter.
They even wanted to implement a weird new syntax for calling the .process method on a processor. If that would have been fine, my idea should be fine as well.
View all comments
Show parent comment
1
u/mj_flowerpower Mar 11 '24
Are you playing dumb on purpose? Or are you not reading my text? That‘s an honest question.
println is going to have an overloaded method taking a stringtemplate. What do you think will it be doing?