Skip to content
Myr

stretch_test.c

This file

Path

deprecated/stretch_test.c

29 lines · 542 bytes · C

Last changed by

stb_hexwave added, stretchy_buffer.h deprecatedSean Barrettbefore adoption559d759

History of this file

Take it

1// check that stb_truetype compiles with no stb_rect_pack.h2#define STB_TRUETYPE_IMPLEMENTATION3#include "stb_truetype.h"45#define STB_DS_IMPLEMENTATION6#include "stb_ds.h"7#include <assert.h>89int main(int arg, char **argv)10{11   int i;12   int *arr = NULL;1314   for (i=0; i < 1000000; ++i)15      arrput(arr, i);1617   assert(arrlen(arr) == 1000000);18   for (i=0; i < 1000000; ++i)19      assert(arr[i] == i);2021   arrfree(arr);22   arr = NULL;2324   for (i=0; i < 1000; ++i)25      arrput(arr, 1000);26   assert(arrlen(arr) == 1000000);2728   return 0;29}