⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 wassert.c

📁 计算器源代码c。和windows自带的功能差不多。很多科学计算还没有加入。
💻 C
字号:
/****************************Module*Header***********************************\
* Module Name: WASSERT
*
* Module Descripton: Quick Win32 assert code.
*
* Warnings:
*
* Created: 15 July 1993
*
* Author: Raymond E. Endres   [rayen@microsoft.com]
\****************************************************************************/

#include <windows.h>
#include "wassert.h"

#ifdef _DEBUG

void vAssert(TCHAR * pszExp, TCHAR * pszFile, int iLine)
{
   TCHAR  szTmp[1024];
   int iReply;

   wsprintf(szTmp, TEXT("Assertion (%s) at line %d, file %s failed.\nPress Abort to quit the program, Retry to debug the program, or Ignore to continue."),
            pszExp, iLine, pszFile);
   iReply = MessageBox(NULL, szTmp, TEXT("Assertion failed:"), MB_ABORTRETRYIGNORE | MB_TASKMODAL );
   switch ( iReply )
   {
   case IDABORT:
       PostQuitMessage( -1 );
       break;
 
   case IDRETRY:
       DebugBreak();
       break;

   case IDIGNORE:
   default:
       // do nothing, program will try to continue;
       break;
   }
}

#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -