A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://open-source-parsers.github.io/jsoncpp-docs/doxygen/assertions_8h.html below:

#include <cstdlib>
#include <sstream>
#include "config.h"
#define  JSON_ASSERT(condition)   It should not be possible for a maliciously designed file to cause an abort() or seg-fault, so these macros are used only for pre-condition violations and internal logic errors. More...
  #define  JSON_FAIL_MESSAGE(message)   #define  JSON_ASSERT_MESSAGE(condition, message)   ◆ JSON_ASSERT #define JSON_ASSERT (   condition ) Value:

do { \

if (!(condition)) { \

Json::throwLogicError("assert json failed"); \

} \

} while (0)

It should not be possible for a maliciously designed file to cause an abort() or seg-fault, so these macros are used only for pre-condition violations and internal logic errors.

◆ JSON_ASSERT_MESSAGE #define JSON_ASSERT_MESSAGE (   condition,   message  ) Value:

do { \

if (!(condition)) { \

JSON_FAIL_MESSAGE(message); \

} \

} while (0)

◆ JSON_FAIL_MESSAGE #define JSON_FAIL_MESSAGE (   message ) Value:

do { \

OStringStream oss; \

oss << message; \

Json::throwLogicError(oss.str()); \

abort(); \

} while (0)


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4