Mirror of :pserver:cvs@cvs.fefe.de:/cvs libowfat https://www.fefe.de/libowfat/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

19 lines
425 B

#include <assert.h>
#include "array.h"
#include "byte.h"
int main() {
static array x,y;
array_cats(&x,"fnord");
array_cats(&y,"foobar");
array_cat(&x,&y);
array_fail(&y);
array_cat(&y,&x);
assert(array_failed(&y));
array_reset(&y);
array_cats(&y,"fnord");
assert(byte_equal(x.p,11,"fnordfoobar"));
array_cate(&x,&y,1,4);
assert(x.initialized=14 && byte_equal(x.p,14,"fnordfoobarnor"));
return 0;
}