std.zlib.Compress / UnCompress are not working
    Lionello Lunesu 
    lio at lunesu.remove.com
       
    Fri May 26 07:18:56 PDT 2006
    
    
  
I can't get the Compress and UnCompress classes in std.zlib to work. 
I've checked the source and noticed they have no unittest.
Should the following code work? If so, please add it to the std.zlib in 
a unittest {...}..
import std.zlib;
void main()
{
	Compress cmp = new Compress;
	UnCompress decmp = new UnCompress;
	void[] input;
	input = "tesatdffadf";
	void[] buf = cmp.compress(input);
	buf ~= cmp.flush();
	void[] output = decmp.uncompress(buf);
	assert( output[] == input[] );
}
L.
    
    
More information about the Digitalmars-d-bugs
mailing list