diff options
author | Jean Boussier <byroot@ruby-lang.org> | 2023-04-13 16:48:59 +0200 |
---|---|---|
committer | Jean Boussier <jean.boussier@gmail.com> | 2023-04-14 09:46:10 +0200 |
commit | 6a5c355e4e7deb76363f474041d00465be3b317b (patch) | |
tree | 19da01aa929f02799b834a4d2bb90f3c9cbff8cd /include | |
parent | 07428e7277b1d59dc1b1b237516b5495ac92bcdf (diff) | |
download | ruby-6a5c355e4e7deb76363f474041d00465be3b317b.tar.gz |
Add RB_WARN_CATEGORY_DEFAULT_BITS
Followup: ac123f167a364c3d7a43eca78d564e41f6dbb91e
RB_WARN_CATEGORY_ALL_BITS is exposed in a public header, so it
makes sense for it to be updated to contain all valid bits.
Instead we introduce RB_WARN_CATEGORY_DEFAULT_BITS to list the
categories that are enabled by default.
Diffstat (limited to 'include')
-rw-r--r-- | include/ruby/internal/error.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/ruby/internal/error.h b/include/ruby/internal/error.h index 8ebf7cd2ab..1ce9a30e6f 100644 --- a/include/ruby/internal/error.h +++ b/include/ruby/internal/error.h @@ -53,9 +53,15 @@ typedef enum { /** Warning is for performance issues (not enabled by -w). */ RB_WARN_CATEGORY_PERFORMANCE, + RB_WARN_CATEGORY_DEFAULT_BITS = ( + (1U << RB_WARN_CATEGORY_DEPRECATED) | + (1U << RB_WARN_CATEGORY_EXPERIMENTAL) | + 0), + RB_WARN_CATEGORY_ALL_BITS = ( (1U << RB_WARN_CATEGORY_DEPRECATED) | (1U << RB_WARN_CATEGORY_EXPERIMENTAL) | + (1U << RB_WARN_CATEGORY_PERFORMANCE) | 0) } rb_warning_category_t; |