本文整理汇总了C++中Unused函数的典型用法代码示例。如果您正苦于以下问题:C++ Unused函数的具体用法?C++ Unused怎么用?C++ Unused使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了Unused函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: DlgLine
INT_PTR
CALLBACK
DlgLine(
HWND hDlg,
UINT message,
WPARAM wParam,
LPARAM lParam
)
{
int y;
static DWORD HelpArray[]=
{
ID_LINE_LINE, IDH_LINE,
0, 0
};
Unused(lParam);
switch (message) {
case WM_HELP:
WinHelp((HWND)((LPHELPINFO) lParam)->hItemHandle, "windbg.hlp", HELP_WM_HELP,
(DWORD_PTR)(LPVOID) HelpArray );
return TRUE;
case WM_CONTEXTMENU:
WinHelp ((HWND) wParam, "windbg.hlp", HELP_CONTEXTMENU,
(DWORD_PTR)(LPVOID) HelpArray );
return TRUE;
case WM_COMMAND:
switch (wParam) {
case IDOK:
// Retrieve selected item text and compute line nbr
y = GetDlgItemInt(hDlg, ID_LINE_LINE, NULL, FALSE);
if (y <= 0) {
ErrorBox2(hDlg, MB_TASKMODAL, ERR_Goto_Line);
SetFocus(GetDlgItem(hDlg, ID_LINE_LINE));
} else {
GotoLine(curView, y, FALSE);
EndDialog(hDlg, TRUE);
}
return (TRUE);
case IDCANCEL :
EndDialog(hDlg, TRUE);
return (TRUE);
}
break;
}
return (FALSE);
} /* DlgLine() */
示例2: Unused
RodinBTNode::ETickStatus RodinBTNodeLog::Tick(float DeltaTime) {
Unused(DeltaTime);
PRINTF("BT Log (%.2f): %s (%s)\n", GetTime(), m_Message.CStr(),
GetEntity()->GetUniqueName().CStr());
return ETS_Success;
}
示例3: Unused
/*virtual*/ void EldritchFramework::GetInitialWindowIcon( uint& WindowIcon )
{
#if BUILD_WINDOWS
WindowIcon = IDI_ICON1;
#else
Unused( WindowIcon );
#endif
}
示例4: Unused
lookupTarget* mapLookupTarget::get_target_for_slot(slotDesc* s,
simpleLookup* L) {
Unused(L);
if ( s->is_map_slot() )
return new objectLookupTarget( s->data);
return NULL;
}
示例5: PRINTF
void MIDI::LogTrack( const uint TrackIndex ) const
{
const SMIDITrack& Track = m_Tracks[ TrackIndex ];
PRINTF( "Track %d:\n", TrackIndex );
// TODO
Unused( Track );
}
示例6: Unused
void CodeGen::loadArg(fint argNo, Location from, bool isPrimCall) {
Unused(isPrimCall);
if (argNo == -1) {
// weird arg numbering - 0 is 1st arg
move(ReceiverReg, from);
} else {
move(ArgLocation(argNo), from);
}
}
示例7: STATICHASH
void Framework3D::CreateSplashWindow(const uint WindowIcon,
const char* const Title) {
XTRACE_FUNCTION;
STATICHASH(Framework);
STATICHASH(SplashImage);
const char* const pSplashImage =
ConfigManager::GetString(sSplashImage, nullptr, sFramework);
if (!pSplashImage) {
return;
}
const Surface SplashSurface =
Surface(PackStream(pSplashImage), Surface::ESFT_BMP);
const int SplashWindowWidth = SplashSurface.GetWidth();
const int SplashWindowHeight = SplashSurface.GetHeight();
ASSERT(!m_SplashWindow);
m_SplashWindow = new Window;
#if BUILD_WINDOWS_NO_SDL
const DWORD WindowStyle = WS_POPUP;
const DWORD WindowExStyle =
WS_EX_TOOLWINDOW; // Prevents this window appearing in the taskbar
const int ScreenWidth =
m_Display->m_Fullscreen ? m_Display->m_Width : m_Display->m_ScreenWidth;
const int ScreenHeight =
m_Display->m_Fullscreen ? m_Display->m_Height : m_Display->m_ScreenHeight;
m_SplashWindow->Init(Title, "SplashWindowClass", WindowStyle, WindowExStyle,
SplashWindowWidth, SplashWindowHeight, m_hInstance, NULL,
WindowIcon, ScreenWidth, ScreenHeight);
// The window needs to be shown before we can blit to it.
m_SplashWindow->Show(m_CmdShow);
#endif
#if BUILD_SDL
// TODO SDL: Unify interface?
const uint Flags = SDL_WINDOW_SHOWN | SDL_WINDOW_BORDERLESS;
m_SplashWindow->Init(Title, Flags, SplashWindowWidth, SplashWindowHeight);
// Load icon from package file instead of compiled resource.
Unused(WindowIcon);
STATICHASH(IconImage);
const char* const pIconImage =
ConfigManager::GetString(sIconImage, nullptr, sFramework);
if(pIconImage) {
ASSERT(pIconImage);
const Surface IconSurface =
Surface(PackStream(pIconImage), Surface::ESFT_BMP);
SDL_SetWindowIcon(m_SplashWindow->GetSDLWindow(),
IconSurface.GetSDLSurface());
}
#endif
SplashSurface.BlitToWindow(m_SplashWindow);
}
示例8: add_obj_map_match
bool add_obj_map_match(oop* matching_cell, smi hit_num) {
Unused(hit_num);
// could be a real match with memOop::map_index,
// or could be a unwanted match with Map::my_index
oop* obj = matching_cell - (map_offset() + Mem_Tag)/oopSize;
assert((*obj)->is_mark(), "should only reference a map in map field");
theEnumeration->add_obj(as_oopsOop(obj));
return theEnumeration->is_ok();
}
示例9: moveInsts
void moveInsts(char* from, char* to, int size) {
Unused(size);
nmethod* n = (nmethod*) from;
nmethod* nTo = (nmethod*)to;
char* n1 = n->insts();
char* n2 = n->instsEnd();
n->moveTo(to, (char*)n->locsEnd() - (char*)n);
if (Universe::code->LRUhand == n) Universe::code->LRUhand = nTo;
}
示例10: Unused
void NodeGen::loadArg(fint argNo, PReg* from, bool isPrimCall) {
Unused(isPrimCall);
assert(currentScope()->isCodeScope(), "oops");
SCodeScope* s = (SCodeScope*)currentScope();
fint bci = s->bci();
Location l = argNo == -1 ? ReceiverReg : ArgLocation(argNo);
// weird arg numbering - 0 is 1st arg, not receiver
// uses aren't right yet (call should have use) -fix this
loadArg(from, new ArgSAPReg(s, l, true, false, bci, bci));
}
示例11: Unused
/*virtual*/ void WBCompEldThinkerPatrol::Tick(float DeltaTime) {
XTRACE_FUNCTION;
Unused(DeltaTime);
WBEntity* const pEntity = GetEntity();
DEVASSERT(pEntity);
WBCompEldTransform* const pTransform =
pEntity->GetTransformComponent<WBCompEldTransform>();
DEVASSERT(pTransform);
WBCompRodinKnowledge* const pKnowledge = GET_WBCOMP(pEntity, RodinKnowledge);
ASSERT(pKnowledge);
WBCompRodinBlackboard* const pBlackboard =
GET_WBCOMP(pEntity, RodinBlackboard);
ASSERT(pBlackboard);
const Vector CurrentLocation = pTransform->GetLocation();
// Select the furthest patrol point that we know about.
WBEntity* pFurthestPatrol = nullptr;
float FurthestDistSq = -1.0f;
const WBCompRodinKnowledge::TKnowledgeMap& KnowledgeMap =
pKnowledge->GetKnowledgeMap();
FOR_EACH_MAP(KnowledgeIter, KnowledgeMap, WBEntityRef,
WBCompRodinKnowledge::TKnowledge) {
WBEntity* pKnowledgeEntity = KnowledgeIter.GetKey().Get();
const WBCompRodinKnowledge::TKnowledge& Knowledge =
KnowledgeIter.GetValue();
if (!pKnowledgeEntity) {
continue;
}
// Filter out knowledge entities that aren't patrol markup.
STATIC_HASHED_STRING(KnowledgeType);
STATIC_HASHED_STRING(Patrol);
if (Knowledge.GetHash(sKnowledgeType) != sPatrol) {
continue;
}
WBCompEldTransform* const pKnowledgeTransform =
pKnowledgeEntity->GetTransformComponent<WBCompEldTransform>();
ASSERT(pKnowledgeTransform);
const float DistSq =
(pKnowledgeTransform->GetLocation() - CurrentLocation).LengthSquared();
if (DistSq > FurthestDistSq) {
FurthestDistSq = DistSq;
pFurthestPatrol = pKnowledgeEntity;
}
}
示例12: CustomUnhandledExceptionFilter
LONG WINAPI CustomUnhandledExceptionFilter( EXCEPTION_POINTERS* pExceptionPointers )
{
Unused( pExceptionPointers );
ASSERT( gIsEnabled );
// In case the exception was due to game being OOM.
Allocator::GetDefault().Enable( false );
PRINTF( "Exception handled:\n" );
EXCEPTION_RECORD* pExceptionRecord = pExceptionPointers->ExceptionRecord;
const DWORD FirstExceptionCode = pExceptionRecord ? pExceptionRecord->ExceptionCode : 0;
Unused( FirstExceptionCode );
while( pExceptionRecord )
{
PRINTF( "\tCode: 0x%08X\n", pExceptionRecord->ExceptionCode );
PRINTF( "\tAddr: 0x%08X\n", pExceptionRecord->ExceptionAddress );
pExceptionRecord = pExceptionRecord->ExceptionRecord;
}
ExceptionTrace::PrintTrace();
#if UPLOADLOG
static const DWORD kBreakpointCode = 0x80000003;
if( FirstExceptionCode == kBreakpointCode )
{
// Don't upload logs from asserts in dev mode.
}
else
{
ExceptionUploadLog::UploadLog();
}
#endif
#if BUILD_SDL
SDL_Quit();
#endif
return EXCEPTION_CONTINUE_SEARCH;
}
示例13: STATIC_HASHED_STRING
/*virtual*/ void WBCompEldIcicles::HandleEvent( const WBEvent& Event )
{
XTRACE_FUNCTION;
Super::HandleEvent( Event );
STATIC_HASHED_STRING( OnTouched );
const HashedString EventName = Event.GetEventName();
// TODO
Unused( EventName );
}
示例14: get_swap_space_prim
oop get_swap_space_prim(oop rcvrIgnored, void *FH) {
Unused(rcvrIgnored);
int totalK, freeK;
if (OS::get_swap_space_info(totalK, freeK)) {
objVectorOop arr= Memory->objVectorObj->cloneSize(2);
arr->obj_at_put(0, as_smiOop(totalK));
arr->obj_at_put(1, as_smiOop(freeK));
return arr;
} else {
failure(FH, "Couldn't get swap space info");
return 0;
}
}
示例15: DEBUGASSERT
/*virtual*/ void D3D9Renderer::SetZEnable(const EZEnable ZEnable) {
DEBUGASSERT(m_D3DDevice);
DEBUGASSERT(ZEnable > EZE_Unknown);
if (ZEnable == m_RenderState.m_ZEnable) {
return;
}
m_RenderState.m_ZEnable = ZEnable;
const HRESULT Result = m_D3DDevice->SetRenderState(
D3DRS_ZENABLE, (ZEnable == EZE_True) ? TRUE : FALSE);
DEBUGASSERT(Result == D3D_OK);
Unused(Result);
}