Welcome to mirror list, hosted at ThFree Co, Russian Federation.

type-test.c « tests - github.com/mumble-voip/celt-0.7.0.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 792b155fc3e47dc4aa56573116ed2c90a0da4960 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif

#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;
}