[#BloombergLP-bsls-BslExceptionUtil]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bsls.adoc[bsls]::BslExceptionUtil
:relfileprefix: ../../
:mrdocs:

This `struct` provides a namespace for `static` utility functions that throw standard library exceptions&period;

== Synopsis

Declared in `&lt;bsls&lowbar;bslexceptionutil&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
struct BslExceptionUtil;
----

== Static Member Functions

[cols="1,4"]
|===
| Name| Description
| xref:BloombergLP/bsls/BslExceptionUtil/throwBadAlloc.adoc[`throwBadAlloc`]  [.small]#[noreturn]#
| Throw a `bsl&colon;&colon;bad&lowbar;alloc` exception if exceptions are enabled in the current build mode, otherwise abort the program&period; `bsl&colon;&colon;bad&lowbar;alloc` will be an alias for the platform&apos;s `std&colon;&colon;bad&lowbar;alloc` class, to ensure both ABI and API compatibility with non&hyphen;BDE code relying on the standard exception hierarchy&period;
| xref:BloombergLP/bsls/BslExceptionUtil/throwBadCast.adoc[`throwBadCast`]  [.small]#[noreturn]#
| Throw a `bsl&colon;&colon;bad&lowbar;cast` exception if exceptions are enabled in the current build mode, otherwise abort the program&period; `bsl&colon;&colon;bad&lowbar;cast` will be an alias for the platform&apos;s `std&colon;&colon;bad&lowbar;cast` class, to ensure both ABI and API compatibility with non&hyphen;BDE code relying on the standard exception hierarchy&period;
| xref:BloombergLP/bsls/BslExceptionUtil/throwBadException.adoc[`throwBadException`]  [.small]#[noreturn]#
| Throw a `bsl&colon;&colon;bad&lowbar;exception` exception if exceptions are enabled in the current build mode, otherwise abort the program&period; `bsl&colon;&colon;bad&lowbar;exception` will be an alias for the platform&apos;s `std&colon;&colon;bad&lowbar;exception` class, to ensure both ABI and API compatibility with non&hyphen;BDE code relying on the standard exception hierarchy&period;
| xref:BloombergLP/bsls/BslExceptionUtil/throwBadTypeid.adoc[`throwBadTypeid`]  [.small]#[noreturn]#
| Throw a `bsl&colon;&colon;bad&lowbar;typeid` exception if exceptions are enabled in the current build mode, otherwise abort the program&period; `bsl&colon;&colon;bad&lowbar;typeid` will be an alias for the platform&apos;s `std&colon;&colon;bad&lowbar;typeid` class, to ensure both ABI and API compatibility with non&hyphen;BDE code relying on the standard exception hierarchy&period;
| xref:BloombergLP/bsls/BslExceptionUtil/throwException.adoc[`throwException`]  [.small]#[noreturn]#
| Throw a `bsl&colon;&colon;exception` exception if exceptions are enabled in the current build mode, otherwise abort the program&period; `bsl&colon;&colon;exception` will be an alias for the platform&apos;s `std&colon;&colon;exception` class, to ensure both ABI and API compatibility with non&hyphen;BDE code relying on the standard exception hierarchy&period;
|===



[.small]#Created with https://www.mrdocs.com[MrDocs]#
