On this page
  1. int32_t
  2. Include
  3. Signature & Overview
  4. Notes & Pitfalls
  5. Example

int32_t

Prev: stdint.h | Up: stdint.h | Next: int64_t
Rel: stdint.h, stdint, stdbool & limits Guide
Ref: cppreference — int32_t
Tags: #public #prog #c #stdlib #stdint #tier/core


Include

#include <stdint.h>

Signature & Overview

typedef /* signed 32-bit */ int32_t;

Exact 32-bit two's complement signed integer.

Notes & Pitfalls

Example

#include <assert.h>
#include <stdint.h>

int main(void) {
    int32_t x = -100000;
    assert(sizeof(x) == 4 && x < 0);
}

Linked from

Related notes