opus/tests/type-test.c
Jean-Marc Valin 2fecbdf084 Fixed the default int32 type which was wrong on amd64 (and added testcase).
Also, added an Ogg encoder (doesn't work quite yet).
2008-01-31 23:43:10 +11:00

24 lines
448 B
C

#include "celt_types.h"
#include <stdio.h>
int main()
{
celt_int16_t i = 1;
i <<= 14;
if (i>>14 != 1)
{
fprintf(stderr, "celt_int16_t isn't 16 bits\n");
return 1;
}
if (sizeof(celt_int16_t)*2 != sizeof(celt_int32_t))
{
fprintf(stderr, "16*2 != 32\n");
return 1;
}
if (sizeof(celt_int32_t)*2 != sizeof(celt_int64_t))
{
fprintf(stderr, "32*2 != 64\n");
return 1;
}
return 0;
}