dl
宏定义 | 函数
dl_platform.h 文件参考

平台宏 更多...

浏览源代码.

宏定义

#define DL_PLATFORM_ERROR   0
 
#define DL_PLATFORM_WIN32   1
 
#define DL_PLATFORM_LINUX   2
 
#define DL_PLATFORM_ANDROID   3
 
#define DL_PLATFORM   DL_PLATFORM_ERROR
 

函数

consteval bool is_x64 ()
 是否64位 更多...
 
consteval bool is_little_endian ()
 字节序是否小端 更多...
 

详细描述

平台宏

版本
1.0
作者
lveyou
日期
23-06-23
注解
必须使用 DL_PLATFORM == DL_PLATFORM_WIN32 来判断,避免未包含头文件引起误判

在文件 dl_platform.h 中定义.

宏定义说明

◆ DL_PLATFORM

#define DL_PLATFORM   DL_PLATFORM_ERROR

在文件 dl_platform.h 第 19 行定义.

◆ DL_PLATFORM_ANDROID

#define DL_PLATFORM_ANDROID   3

在文件 dl_platform.h 第 17 行定义.

◆ DL_PLATFORM_ERROR

#define DL_PLATFORM_ERROR   0

在文件 dl_platform.h 第 14 行定义.

◆ DL_PLATFORM_LINUX

#define DL_PLATFORM_LINUX   2

在文件 dl_platform.h 第 16 行定义.

◆ DL_PLATFORM_WIN32

#define DL_PLATFORM_WIN32   1

在文件 dl_platform.h 第 15 行定义.

函数说明

◆ is_little_endian()

consteval bool is_little_endian ( )

字节序是否小端

在文件 dl_platform.h 第 44 行定义.

◆ is_x64()

consteval bool is_x64 ( )

是否64位

在文件 dl_platform.h 第 38 行定义.