Re: using MD5 parrot library in Q:PIR block

2010-06-10 Thread Cosimo Streppone
On Thu, 10 Jun 2010 09:17:23 +0200, Gerd Pokorra wrote: #!/usr/bin/perl6 Q:PIR { load_bytecode 'Digest/MD5.pbc' .local pmc md5sum, md5_sum_get md5sum = get_root_global ['parrot'; 'Digest'], '_md5sum' $P0 = md5sum('foo') md5_sum_get = get_root_global ['parrot'; 'Digest'],

Re: using MD5 parrot library in Q:PIR block

2010-06-10 Thread Gerd Pokorra
I am wrong. As I just looked at the source code I saw that there is already a method (_md5_hex) that can be used to get the checksum as string. #!/usr/bin/perl6 Q:PIR { load_bytecode 'Digest/MD5.pbc' .local pmc md5sum, md5_sum_get md5sum = get_root_global ['parrot'; 'Digest'], '_md5su

Re: using MD5 parrot library in Q:PIR block

2010-06-09 Thread Cosimo Streppone
In data 10 giugno 2010 alle ore 08:48:42, Gerd Pokorra ha scritto: I think the easiest way would be to add a method in the file "runtime/parrot/library/Digest/MD5.pir" that gives the md5 checksum back as a string. I can look at the source code and try to do this for you if you want and add a

Re: using MD5 parrot library in Q:PIR block

2010-06-09 Thread Gerd Pokorra
I think the easiest way would be to add a method in the file "runtime/parrot/library/Digest/MD5.pir" that gives the md5 checksum back as a string. I can look at the source code and try to do this for you if you want and add a method may be called "_md5_sum_get". -- Gerd Am Mittwoch, den 09.06.20

Re: using MD5 parrot library in Q:PIR block

2010-06-09 Thread Cosimo Streppone
On Wed, 09 Jun 2010 16:00:42 +0200, Gerd Pokorra wrote: Here is a simple example that works. #!/usr/bin/perl6 Q:PIR { load_bytecode 'Digest/MD5.pbc' .local pmc md5sum, md5print md5sum = get_root_global ['parrot'; 'Digest'], '_md5sum' $P0 = md5sum('foo') md5print = get_ro

using MD5 parrot library in Q:PIR block

2010-06-09 Thread Gerd Pokorra
Here is a simple example that works. #!/usr/bin/perl6 Q:PIR { load_bytecode 'Digest/MD5.pbc' .local pmc md5sum, md5print md5sum = get_root_global ['parrot'; 'Digest'], '_md5sum' $P0 = md5sum('foo') md5print = get_root_global ['parrot'; 'Digest'], '_md5_print' md5print($P0)