GCC requires C++14 and C++ supports enum bitfield so ENUM_BITFIELD is 
deprecated macro.

Bootstrapped and regtested on x86_64-pc-linux-gnu.

        PR middle-end/125507

gcc/rust/ChangeLog:

        * backend/rust-tree.h (struct lang_decl_base): Remove ENUM_BITFIELD.
        (struct rust_cp_binding_level): Ditto.

Signed-off-by: Kael Andrew Franco <[email protected]>
---
 gcc/rust/backend/rust-tree.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gcc/rust/backend/rust-tree.h b/gcc/rust/backend/rust-tree.h
index b995d0afd8a..21edfe389f4 100644
--- a/gcc/rust/backend/rust-tree.h
+++ b/gcc/rust/backend/rust-tree.h
@@ -1971,7 +1971,7 @@ enum lang_decl_selector
 
 struct GTY (()) lang_decl_base
 {
-  ENUM_BITFIELD (lang_decl_selector) selector : 3;
+  enum lang_decl_selector selector : 3;
   unsigned use_template : 2;
   unsigned not_really_extern : 1;    /* var or fn */
   unsigned initialized_in_class : 1; /* var or fn */
@@ -2189,7 +2189,7 @@ struct GTY (()) rust_cp_binding_level
   /* The kind of scope that this object represents.  However, a
       SK_TEMPLATE_SPEC scope is represented with KIND set to
       SK_TEMPLATE_PARMS and EXPLICIT_SPEC_P set to true.  */
-  ENUM_BITFIELD (scope_kind) kind : 4;
+  enum scope_kind kind : 4;
 
   /* True if this scope is an SK_TEMPLATE_SPEC scope.  This field is
       only valid if KIND == SK_TEMPLATE_PARMS.  */
-- 
2.55.0

Reply via email to