String>>contentsAsMethod

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

String>>contentsAsMethod

Rob Rothwell
The Aida 5.6 String>>contentsAsMethod should close the method with a ")" instead of a "]"...

contentsAsMethod
"return a body of method with a literal array with contents of that string"
| input output |
input := self readStream.
output := WriteStream with: String new.
output nextPutAll: '^#('.
[input atEnd] whileFalse: [output nextPutAll: input next asInteger asString; nextPut: $ ].
output nextPutAll: ')'.
^output contents

Rob

_______________________________________________
Aida mailing list
[hidden email]
http://lists.aidaweb.si/mailman/listinfo/aida
Reply | Threaded
Open this post in threaded view
|

Re: String>>contentsAsMethod

Nicolas Petton
Hi,

For Squeak, this method is replaced by a new one which works better.
it's in the squeaksource repository (http://mc.bioskop.fr).

Cheers!

Nico
--
Nicolas Petton
http://nico.bioskop.fr
            ___
          ooooooo
         OOOOOOOOO
        |Smalltalk|
         OOOOOOOOO
          ooooooo
           \   /
            [|]
--------------------------------
Ma clé PGP est disponible ici :
http://nico.bioskop.fr/pgp-key.html

_______________________________________________
Aida mailing list
[hidden email]
http://lists.aidaweb.si/mailman/listinfo/aida

signature.asc (196 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: String>>contentsAsMethod

Rob Rothwell
Is this a "different" package than the one you see with the Universe Browser?  Is it more "up-to-date?"

Rob 

On Sun, Mar 16, 2008 at 10:39 AM, Nicolas Petton <[hidden email]> wrote:
Hi,

For Squeak, this method is replaced by a new one which works better.
it's in the squeaksource repository (http://mc.bioskop.fr).

Cheers!

Nico
--
Nicolas Petton
http://nico.bioskop.fr
           ___
         ooooooo
        OOOOOOOOO
       |Smalltalk|
        OOOOOOOOO
         ooooooo
          \   /
           [|]
--------------------------------
Ma clé PGP est disponible ici :
http://nico.bioskop.fr/pgp-key.html



--
The foolish reject what they see, not what they think; the wise reject what they think, not what they see. -- Huang Po

_______________________________________________
Aida mailing list
[hidden email]
http://lists.aidaweb.si/mailman/listinfo/aida