[Pharo-users] Re: PrintString in PBE8

2020-12-24 Thread Richard Sargent
You should be able to replace
nextPutAll: count printString
with
print: count


On December 24, 2020 9:32:38 AM PST, g_patrickb--- via Pharo-users 
 wrote:
>I started working through PBE8, and in section 3.13 there is a method:
>
>`Counter >> printOn: aStream `
>
>`super printOn: aStream. `
>
>`aStream nextPutAll: ' with value: ', count printString.`
>
>But it returns two warnings:
>
>\[printString\] No printString inside printOn
>
>Use cascaded nextPutAll:’s instead of #, in #nextPutAll:
>
>It has the option to automatically resolve the cascaded nextPutAll:
>which results in:
>
>`printOn: aStream`
>
>`  super printOn: aStream.`
>
>`  aStream`
>
>`  nextPutAll: ' with value: ';`
>
>`  nextPutAll: count printString`
>
>But it still has the warning about printString.


[Pharo-users] PrintString in PBE8

2020-12-24 Thread g_patrickb--- via Pharo-users
I started working through PBE8, and in section 3.13 there is a method:

`Counter >> printOn: aStream `

`super printOn: aStream. `

`aStream nextPutAll: ' with value: ', count printString.`

But it returns two warnings:

\[printString\] No printString inside printOn

Use cascaded nextPutAll:’s instead of #, in #nextPutAll:

It has the option to automatically resolve the cascaded nextPutAll: which 
results in:

`printOn: aStream`

`   super printOn: aStream.`

`   aStream`

`   nextPutAll: ' with value: ';`

`   nextPutAll: count printString`

But it still has the warning about printString.