Login  Register

Re: PrintString in PBE8

Posted by Richard Sargent (again) on Dec 24, 2020; 5:58pm
URL: https://forum.world.st/PrintString-in-PBE8-tp5125601p5125602.html

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 <[hidden email]> 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.