azure-core
Loading...
Searching...
No Matches
Namespaces | Macros
azure_assert.hpp File Reference

Provide assert macros to use with pre-conditions. More...

#include "azure/core/platform.hpp"
#include <cstdlib>
#include <string>
#include <cassert>

Go to the source code of this file.

Namespaces

namespace  Azure
 Compute the hash value for the input binary data, using SHA256, SHA384 and SHA512.
 

Macros

#define AZURE_ASSERT(exp)   assert((exp))
 Azure specific assert macro.
 
#define AZURE_ASSERT_MSG(exp, msg)   assert(((void)(msg), (exp)))
 Azure specific assert macro with message.
 
#define AZURE_ASSERT_FALSE(exp)   AZURE_ASSERT(!(exp))
 Assert that the exp parameter is always false.
 
#define AZURE_UNREACHABLE_CODE()   ::Azure::Core::_internal::AzureNoReturnPath("unreachable code!")
 Indicate that the code cannot be reached.
 
#define AZURE_NOT_IMPLEMENTED()   ::Azure::Core::_internal::AzureNoReturnPath("not implemented code!")
 Indicate that the function is not implemented.
 
#define _azure_NODISCARD
 Generate a warning if the value is ignored by the caller.
 

Detailed Description

Attention
These macros are deprecated for public use - they should NOT be used by any callers outside of the SDK.
Remarks
Asserts are turned ON when NDEBUG is NOT defined (for Debug build). For Release build, std::abort() is directly called if the condition is false, without calling assert().