YSTest
PreAlpha_b500_20140530
The YSLib Test Project
|
YBase 指定的替代关键字。 更多...
宏定义 | |
#define | yalignof(_type) std::alignment_of<_type>::value |
指定特定类型的对齐。 更多... | |
#define | yconstexpr const |
指定编译时常量表达式。 更多... | |
#define | yconstfn inline |
指定编译时常量函数。 更多... | |
#define | ythrow(...) |
YSLib 动态异常规范:根据是否使用异常规范宏指定或忽略动态异常规范。 更多... | |
#define | ynothrowv |
YSLib 无异常抛出保证验证:有条件地使用无异常抛出规范。 更多... | |
#define | ynothrow ythrow() |
YSLib 无异常抛出保证:若支持 noexcept 关键字, 指定特定的 noexcept 异常规范。 更多... | |
#define | ynoexcept(...) |
YSLib 无异常抛出保证:指定特定的异常规范。 更多... | |
#define | ythread static |
线程局部存储:若实现支持,指定为 thread_local 。 更多... | |
#define | yoffsetof(_type, _member) |
带有静态类型检查的成员偏移计算。 更多... | |
#define | yforward(_expr) std::forward<decltype(_expr)>(_expr) |
根据参数类型使用 std::forward 传递对应参数。 更多... | |
#define | yunseq ystdex::unsequenced |
无序列依赖表达式组求值。 更多... | |
#define | yconstraint assert |
约束:接口语义。 更多... | |
#define | yassume assert |
假定:环境语义。 更多... | |
YBase 指定的替代关键字。
#define yalignof | ( | _type | ) | std::alignment_of<_type>::value |
#define yassume assert |
假定:环境语义。
运行时检查的环境条件约束断言。用于明确地非 yconstraint 适用的情形。
参考自 NPL::SContext::Analyze(), platform_ex::Attach(), ystdex::any_input_iterator< _type, _tDifference, _tPointer, _tReference >::equals(), ystdex::nifty_counter< _type >::get(), ystdex::call_once_init< _type, _tOnceFlag >::get(), ystdex::get_mid(), CHRLib::GUCS2Mapper< CharSet::GBK >::Map(), ystdex::path< _tSeqCon, _tNorm >::merge_parents(), ystdex::container_inserter< _tCon >::operator()(), ystdex::any_input_iterator< _type, _tDifference, _tPointer, _tReference >::operator*(), ystdex::subscriptive_iterator< _tCon, _type >::operator+(), ystdex::ifile_iterator::operator++(), ystdex::any_input_iterator< _type, _tDifference, _tPointer, _tReference >::operator++(), ystdex::bitseg_iterator< _vN, _bEndian >::operator++(), ystdex::bitseg_iterator< _vN, _bEndian >::operator+=(), ystdex::subscriptive_iterator< _tCon, _type >::operator-(), ystdex::any_bidirectional_iterator< _type, _tDifference, _tPointer, _tReference >::operator--(), ystdex::bitseg_iterator< _vN, _bEndian >::operator--(), ystdex::subscriptive_iterator< _tCon, _type >::operator-=(), ystdex::subscriptive_iterator< _tCon, _type >::operator[](), ystdex::polymorphic_crosscast() , 以及 ystdex::polymorphic_downcast().
#define yconstexpr const |
指定编译时常量表达式。
参考自 platform::ImplRet(), YSLib::InitializeEnviornment(), YReader::ShlExplorer::OnPaint() , 以及 YSLib::UI::HexViewArea::Refresh().
#define yconstraint assert |
约束:接口语义。
运行时检查的接口语义约束断言。不满足此断言的行为是接口明确地未定义的,行为不可预测。
参考自 platform_ex::COMPtr< _iCOM >::As(), platform_ex::COMPtr< _iCOM >::Cast(), platform::KeyCategory::ClassifyKey(), platform_ex::COMException::COMException(), ystdex::concat(), platform_ex::COMPtr< _iCOM >::Copy(), platform_ex::COMPtr< _iCOM >::CopyTo(), platform_ex::COMPtr< _iCOM >::DefGetter(), CHRLib::FetchBiCharBE(), CHRLib::FetchBiCharLE(), ystdex::fexists(), ystdex::path< _tSeqCon, _tNorm >::get_norm(), platform::GetFileSizeOf(), ystdex::ifile_iterator::ifile_iterator(), CHRLib::MakeUCS2LEString(), CHRLib::MBCSToUCS2(), CHRLib::MBCToUC(), ystdex::next_if(), ystdex::next_if_eq(), ystdex::ntctscmp(), ystdex::ntctsicmp(), ystdex::ntctslen(), platform_ex::COMPtr< _iCOM >::operator*(), ystdex::pointer_iterator< _type >::operator*(), ystdex::indirect_input_iterator< _tIterator >::operator*(), ystdex::bitseg_iterator< _vN, _bEndian >::operator*(), ystdex::pointer_iterator< _type >::operator++(), ystdex::indirect_input_iterator< _tIterator >::operator++(), ystdex::bitseg_iterator< _vN, _bEndian >::operator++(), ystdex::pointer_iterator< _type >::operator+=(), ystdex::bitseg_iterator< _vN, _bEndian >::operator+=(), ystdex::bitseg_iterator< _vN, _bEndian >::operator--(), ystdex::pointer_iterator< _type >::operator-=(), ystdex::pointer_iterator< _type >::operator[](), CHRLib::strdup(), CHRLib::UCS2Mapper(), CHRLib::UCS2ToMBCS(), CHRLib::UCS4ToUCS2(), CHRLib::ucsdup(), CHRLib::UCToMBC(), platform::ufexists(), platform::ufopen(), ystdex::any::unsafe_any_cast() , 以及 platform::uopen().
#define yforward | ( | _expr | ) | std::forward<decltype(_expr)>(_expr) |
根据参数类型使用 std::forward 传递对应参数。
传递参数:按类型保持值类别(value catory) 和 const 修饰符。 当表达式类型为函数或函数引用类型时,结果为左值(lvalue) ,否则: 当且仅当左值引用类型时结果为左值(此时类型不变); 否则结果为对应的右值引用类型的消亡值(xvalue) 。
参考自 YSLib::UI::AccessWidget(), YSLib::UI::Styles::AddHandlers(), YSLib::AddUnique(), ystdex::any::any(), ystdex::any_input_iterator< _type, _tDifference, _tPointer, _tReference >::any_input_iterator(), ystdex::assign(), ytest::timing::average(), YSLib::CacheLookup(), ystdex::call_once(), ystdex::call_once_init< _type, _tOnceFlag >::call_once_init(), YSLib::CollectNodes(), YSLib::UI::CreateUniqueWidget(), YSLib::UI::Styles::StyleMap::DefGetter(), YSLib::GMRUCache< YSLib::Drawing::Typeface::BitmapKey, YSLib::Drawing::Typeface::SmallBitmapData, YSLib::Drawing::Typeface::BitmapKeyHash >::emplace(), ystdex::forward_as_array(), ystdex::variadic_param< _vN >::get(), ystdex::variadic_param< 0U >::get(), ystdex::get_init(), YSLib::GHEvent< _tRet(_tParams...)>::GHEvent(), YSLib::GEventWrapper< EventT(HPaintEvent), YSLib::UI::UIEventArgs && >::ImplI(), ystdex::call_once_init< _type, _tOnceFlag >::init(), ystdex::initializer_cast(), YSLib::UI::InsertWidget(), platform::Logger::Log(), ystdex::make_expanded(), ystdex::make_shared(), ystdex::transformed_iterator< _tIterator, _fTransformer >::make_transform(), ystdex::make_unique(), YSLib::ValueNode::MakeNode(), YSLib::UI::MakeWidgetHandlerAdaptor(), ystdex::nifty_counter< _type >::nifty_counter(), ytest::timing::once(), ytest::timing::once_c(), YSLib::ExpandMemberFirst< _type, _tRet, _tPara, _tNew >::operator()(), YSLib::ExpandMemberFirstBinder< _type, _tRet, _tPara, _tNew >::operator()(), ystdex::container_inserter< _tCon >::operator()(), ystdex::expanded_caller< _fHandler, _fCallable >::operator()(), YSLib::GDependencyEvent< _tEvent, _tOwnerPointer >::operator()(), YSLib::GHandlerAdaptor< _type, _fCallable >::operator()(), ystdex::transformed_iterator< _tIterator, _fTransformer >::operator*(), ystdex::pod_storage< non_aggregate_pod >::operator=(), ystdex::operator|(), YSLib::PackNodes(), ystdex::pod_storage< non_aggregate_pod >::pod_storage(), YSLib::PostTask(), YSLib::Drawing::PutText(), YSLib::UI::GAnimationSession< YSLib::UI::InvalidationUpdater >::Reset(), YSLib::Drawing::ScrDraw(), ystdex::seq_apply(), ystdex::seq_insert(), YSLib::StringifyToNode(), YSLib::UI::Styles::StyleMap::StyleMap(), ytest::timing::total(), ytest::timing::total_c(), YSLib::UnpackToNode(), ystdex::unseq_apply(), ystdex::unsequenced(), ystdex::varg() , 以及 YSLib::GEvent< _tRet(_tParams...)>::yimpl().
#define ynothrow ythrow() |
#define ynothrowv |
#define yoffsetof | ( | _type, | |
_member | |||
) |
带有静态类型检查的成员偏移计算。
#define ythread static |
线程局部存储:若实现支持,指定为 thread_local
。
__thread
和 __declspec(thread)
。 参考自 ystdex::nifty_counter< _type >::get_count() , 以及 ystdex::nifty_counter< _type >::get_object_ptr().
#define ythrow | ( | ... | ) |
#define yunseq ystdex::unsequenced |
无序列依赖表达式组求值。
参考自 YSLib::DS::UI::DualScreenReader::AdjustMargins(), YSLib::UI::AScrollBar::AScrollBar(), YSLib::Drawing::Shaders::BlendCore(), YSLib::Drawing::BlitBounds(), YSLib::UI::Caret::Caret(), YSLib::UI::GUIState::CheckHeldState(), platform_ex::ClearKeyStates(), YSLib::Drawing::TextRegion::ClearLine(), YSLib::UI::Control::Control(), YSLib::Text::CopySliceFrom(), YSLib::UI::DecorateAsCloseButton(), YSLib::UI::DialogBox::DialogBox(), YSLib::UI::DialogPanel::DialogPanel(), YSLib::Drawing::Rect::Diminish(), YSLib::UI::DrawItems(), YSLib::Drawing::DrawPolygon(), YSLib::Drawing::FetchStringOffsets(), CHRLib::FillByte(), YSLib::UI::HoverUpdater::HoverUpdater(), YSLib::DS::UI::DualScreenReader::LoadText(), main(), YSLib::UI::Menu::Menu(), ystdex::ntctscmp(), ystdex::ntctsicmp(), YSLib::DS::ShlDS::OnInput(), ystdex::openmode_conv(), YSLib::Drawing::CopyLine< _bPositiveScan >::operator()(), ystdex::pair_iterator< _tMaster, _tSlave, _tTraits >::operator+(), YSLib::Text::TextFileBuffer::iterator::operator++(), ystdex::pair_iterator< _tMaster, _tSlave, _tTraits >::operator++(), ystdex::bitseg_iterator< _vN, _bEndian >::operator++(), YSLib::Drawing::Padding::operator+=(), YSLib::Drawing::GBinaryGroup< SPos >::operator+=(), YSLib::UI::MenuHost::operator+=(), ystdex::pair_iterator< _tMaster, _tSlave, _tTraits >::operator+=(), ystdex::bitseg_iterator< _vN, _bEndian >::operator+=(), ystdex::pair_iterator< _tMaster, _tSlave, _tTraits >::operator-(), ystdex::pair_iterator< _tMaster, _tSlave, _tTraits >::operator--(), ystdex::bitseg_iterator< _vN, _bEndian >::operator--(), YSLib::Drawing::GBinaryGroup< SPos >::operator-=(), ystdex::pair_iterator< _tMaster, _tSlave, _tTraits >::operator-=(), YReader::SettingPanel::operator<<(), YReader::SettingPanel::operator>>(), YSLib::UI::ProgressBar::ProgressBar(), NPL::LexicalAnalyzer::PushEscape(), YSLib::UI::ProgressBar::Refresh(), YSLib::UI::HexViewArea::Refresh(), YSLib::UI::InputTimer::RefreshHeld(), YSLib::UI::MTextList::RefreshTextState(), YSLib::UI::GUIState::Reset(), YSLib::Drawing::ScrDraw(), YSLib::Drawing::TextRegion::Scroll(), YSLib::UI::ColorBox::SetColor(), YSLib::DS::UI::DualScreenReader::SetLineGap(), YSLib::Drawing::Font::SetStyle(), YReader::ShlTextReader::SettingSession::SettingSession(), YSLib::Drawing::Typeface::SmallBitmapData::SmallBitmapData(), ystdex::starts_width(), platform::StartTicks(), YSLib::UI::TextBox::TextBox(), YSLib::TextFile::TextFile(), YSLib::UI::Thumb::Thumb(), NPL::TransformNPLA1(), YSLib::DS::UI::DualScreenReader::UnloadText(), ystdex::unseq_apply(), YSLib::Devices::InputManager::Update(), YReader::ShlTextReader::UpdateButtons(), YSLib::UI::GUIState::UpdateChar(), YReader::ReaderBox::UpdateData(), YReader::TextInfoBox::UpdateData(), YSLib::UI::HexViewArea::UpdateData(), YSLib::UI::TabControl::UpdateTabPages(), YSLib::UI::View::View(), YSLib::UI::BorderResizer::Wrap() , 以及 YSLib::UI::GUIState::Wrap().