diff options
author | Koichi Sasada <[email protected]> | 2020-05-20 17:20:59 +0900 |
---|---|---|
committer | Koichi Sasada <[email protected]> | 2020-05-26 03:21:14 +0900 |
commit | 4ac42874bc5b39b82199d9d86eea1c64efe4d73d (patch) | |
tree | bcb32f244be359113e9a8295325fbad7661d1596 /include/ruby/assert.h | |
parent | 21991e6ca59274e41a472b5256bd3245f6596c90 (diff) |
Update include/ruby/assert.h
Co-authored-by: 卜部昌平 <[email protected]>
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/3124
Diffstat (limited to 'include/ruby/assert.h')
-rw-r--r-- | include/ruby/assert.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/include/ruby/assert.h b/include/ruby/assert.h index 41ecbd8936..14a6e280ce 100644 --- a/include/ruby/assert.h +++ b/include/ruby/assert.h @@ -32,7 +32,13 @@ #endif #if RUBY_DEBUG > 0 && defined(NDEBUG) -#warning NDEBUG is ignored because RUBY_DEBUG>0. +#if defined(_MSC_VER) +# pragma message("NDEBUG is ignored because RUBY_DEBUG>0.") +#elif defined(__GNUC__) +# pragma GCC warning "NDEBUG is ignored because RUBY_DEBUG>0." +#else +# error NDEBUG is ignored because RUBY_DEBUG>0. +#endif #endif /* |