@@ -23,7 +23,7 @@ template class _template_::weak<boxed>;
23template class _template_::recur<boxed>;
23template class _template_::recur<boxed>;
25boxed::boxed(const long n) : _int_(static_cast<int>(n)) {
25boxed::boxed(const long n) : _int_(static_cast<int>(n)) {
26−#if !defined(NDEBUG)
26+#if !defined(NDEBUG) && !defined(PURESCRIPT_DISABLE_EXCEPTIONS)
27 if (n < std::numeric_limits<int>::min() || n > std::numeric_limits<int>::max()) {
27 if (n < std::numeric_limits<int>::min() || n > std::numeric_limits<int>::max()) {
28 throw std::runtime_error("integer out of range");
28 throw std::runtime_error("integer out of range");
@@ -31,7 +31,7 @@ boxed::boxed(const long n) : _int_(static_cast<int>(n)) {
33boxed::boxed(const unsigned long n) : _int_(static_cast<int>(n)) {
33boxed::boxed(const unsigned long n) : _int_(static_cast<int>(n)) {
34−#if !defined(NDEBUG)
34+#if !defined(NDEBUG) && !defined(PURESCRIPT_DISABLE_EXCEPTIONS)
35 if (n > std::numeric_limits<int>::max()) {
35 if (n > std::numeric_limits<int>::max()) {
36 throw std::runtime_error("integer out of range");
36 throw std::runtime_error("integer out of range");