<cstddef>

C 표준 라이브러리 헤더 <stddef.h> 를 포함하고 연결된 이름을 네임스페이스에 std 추가합니다. 이 헤더를 포함하면 C 표준 라이브러리 헤더의 외부 링크를 사용하여 선언된 이름이 네임스페이 std 스에 선언됩니다.

참고 항목

<cstddef>는 형식 바이트를 포함하며 형식wchar_t을 포함하지 않습니다.

구문

#include <cstddef>

네임스페이스 및 매크로

namespace std {
    using ptrdiff_t = see definition;
    using size_t = see definition;
    using max_align_t = see definition;
    using nullptr_t = decltype(nullptr);
}

#define NULL  // an implementation-defined null pointer constant
#define offsetof(type, member-designator)

매개 변수

ptrdiff_t
배열 개체에서 두 개의 아래 첨자의 차이를 유지할 수 있는 구현 정의 부속 정수 형식입니다.

Size_t
개체의 크기(바이트)를 포함할 수 있을 만큼 큰 구현 정의 부호 없는 정수 형식입니다.

max_align_t
맞춤 요구 사항이 모든 스칼라 형식만큼 크고 모든 컨텍스트에서 맞춤 요구 사항이 지원되는 POD 형식입니다.

nullptr_t
식 형식의 동의어입니다 nullptr . 주소를 사용할 nullptr 수는 없지만 lvalue인 다른 nullptr_t 개체의 주소를 사용할 수 있습니다.

byte 클래스

enum class byte : unsigned char {};

template <class IntType>
    constexpr byte& operator<<=(byte& b, IntType shift) noexcept;
    constexpr byte operator<<(byte b, IntType shift) noexcept;
    constexpr byte& operator>>=(byte& b, IntType shift) noexcept;
    constexpr byte operator>>(byte b, IntType shift) noexcept;

constexpr byte& operator|=(byte& left, byte right) noexcept;
constexpr byte operator|(byte left, byte right) noexcept;
constexpr byte& operator&=(byte& left, byte right) noexcept;
constexpr byte operator&(byte left, byte right) noexcept;
constexpr byte& operator^=(byte& left, byte right) noexcept;
constexpr byte operator^(byte left, byte right) noexcept;
constexpr byte operator~(byte b) noexcept;

template <class IntType>
    IntType to_integer(byte b) noexcept;

참고 항목

헤더 파일 참조
C++ 표준 라이브러리 개요
C++ 표준 라이브러리의 스레드 보안