[squeak-dev] String>expandMacros rules?

tim Rowledge tim at rowledge.org
Mon Mar 6 00:58:44 UTC 2017


> On 05-03-2017, at 3:08 PM, Levente Uzonyi <leves at caesar.elte.hu> wrote:
> 
> We already have #format:, which is why #expandMacros* is not being used at all.

OK; then we should remove the redundant stuff some time.

> I don't think we need a third implementation unless it provides
> something the other two doesn’t.

Oh, the printf stuff most definitely adds something; 

       ‘%-0.1e’ printf: x
is a whole lot nicer than 
      (x printShowingDecimalPlaces: 1) padded: #left to: 1 with: $0

.. and having all the other options provided nice and cleanly is a real bonus. It’s well worth quickly loading to take a look at. I suspect quite a bit of code could be cleaned up by using this instead of assorted ad hoc methods.

tim
--
tim Rowledge; tim at rowledge.org; http://www.rowledge.org/tim
Change is inevitable....except from vending machines.




More information about the Squeak-dev mailing list