mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-01-26 15:44:46 +00:00
28 lines
522 B
C++
28 lines
522 B
C++
#ifndef AL_ERROR_H
|
|
#define AL_ERROR_H
|
|
|
|
#include "AL/al.h"
|
|
|
|
#include "core/except.h"
|
|
|
|
namespace al {
|
|
|
|
class context_error final : public al::base_exception {
|
|
ALenum mErrorCode{};
|
|
|
|
public:
|
|
#ifdef __MINGW32__
|
|
[[gnu::format(__MINGW_PRINTF_FORMAT, 3, 4)]]
|
|
#else
|
|
[[gnu::format(printf, 3, 4)]]
|
|
#endif
|
|
context_error(ALenum code, const char *msg, ...);
|
|
~context_error() final;
|
|
|
|
[[nodiscard]] auto errorCode() const noexcept -> ALenum { return mErrorCode; }
|
|
};
|
|
|
|
} /* namespace al */
|
|
|
|
#endif /* AL_ERROR_H */
|