YSTest
PreAlpha_b400_20130424
The YSLib Test Project
|
系统环境和公用类型和宏的基础定义。 更多...
#include <cstddef>
#include <climits>
#include <cassert>
#include <cstdint>
#include <cwchar>
#include <utility>
#include <type_traits>
类 | |
class | ystdex::nullptr_t |
空指针类。 更多... | |
struct | ystdex::empty_base<> |
空基类模板。 更多... | |
class | ystdex::offsetof_check< _bMemObjPtr, _bNoExcept, _type > |
成员偏移计算静态类型检查。 更多... | |
命名空间 | |
namespace | ystdex |
宏定义 | |
#define | YB_HAS_ALIGNAS (YB_IMPL_GNUCPP >= 40800) |
内建 alignas 支持。 | |
#define | YB_HAS_ALIGNOF (YB_IMPL_CPP >= 201103L || YB_IMPL_GNUCPP >= 40500) |
内建 alignof 支持。 | |
#define | YB_HAS_BUILTIN_NULLPTR |
内建 nullptr 支持。 | |
#define | YB_HAS_CONSTEXPR (YB_IMPL_CPP >= 201103L || YB_IMPL_GNUCPP >= 40600) |
constexpr 支持。 | |
#define | YB_HAS_NOEXCEPT (YB_IMPL_CPP >= 201103L || YB_IMPL_GNUCPP >= 40600) |
#define | YB_ATTR(...) |
属性。 | |
#define | YB_ALLOCATOR |
指示修饰的是分配器,或返回分配器调用的函数或函数模板。 | |
#define | YB_EXPECT(expr, constant) (expr) |
#define | YB_LIKELY (expr) (expr) |
#define | YB_UNLIKELY (expr) (expr) |
分支预测提示。 | |
#define | YB_NORETURN |
指定无返回值函数。 | |
#define | YB_PURE |
指示函数或函数模板实例为纯函数。 | |
#define | YB_STATELESS |
指示函数或函数模板实例为无状态函数。 | |
#define | YB_API |
YBase 应用程序编程接口:用于向库文件约定链接。 | |
#define | YB_USE_YASSERT |
#define | YB_USE_EXCEPTION_SPECIFICATION 1 |
使用 YBase 断言。 | |
#define | yalignof(_type) std::alignment_of<_type>::value |
指定特定类型的对齐。 | |
#define | yconstexpr const |
指定编译时常量表达式。 | |
#define | yconstfn inline |
指定编译时常量函数。 | |
#define | ythrow throw |
YSLib 动态异常规范:根据是否使用异常规范宏指定或忽略动态异常规范。 | |
#define | ynothrow ynoexcept |
YSLib 无异常抛出保证:若支持 noexcept 关键字,指定特定的 noexcept 异常规范。 | |
#define | ynoexcept(...) |
YSLib 无异常抛出保证:指定特定的异常规范。 | |
#define | yconstraint assert |
约束:接口语义。 | |
#define | yassume assert |
假定:环境语义。 | |
#define | yoffsetof(_type, _member) |
带有静态类型检查的成员偏移计算。 | |
#define | yforward(_expr) std::forward<decltype(_expr)>(_expr) |
根据参数类型使用 std::forward 传递对应参数。 | |
#define | yunseq ystdex::unsequenced |
无序列依赖表达式组求值。 | |
类型定义 | |
typedef unsigned char | ystdex::byte |
字节类型。 | |
typedef int | ystdex::errno_t |
函数 | |
template<typename _type , typename... _tParams> | |
auto | ystdex::unsequenced (_type &&arg, _tParams &&...) -> decltype(std::forward< decltype(arg)>(arg)) |
无序列依赖表达式组求值实现。 | |
template<typename _type > | |
bool | ystdex::operator== (nullptr_t lhs, const _type &rhs) |
template<typename _type > | |
bool | ystdex::operator== (const _type &lhs, nullptr_t rhs) |
template<typename _type > | |
bool | ystdex::operator!= (nullptr_t lhs, const _type &rhs) |
template<typename _type > | |
bool | ystdex::operator!= (const _type &lhs, nullptr_t rhs) |
变量 | |
class ystdex::nullptr_t | ystdex::nullptr = {} |
系统环境和公用类型和宏的基础定义。
在文件 ydef.h 中定义.