[前][次][番号順一覧][スレッド一覧]

ruby-changes:60817

From: Nobuyoshi <ko1@a...>
Date: Sat, 18 Apr 2020 17:36:25 +0900 (JST)
Subject: [ruby-changes:60817] 0f7d3e4e40 (master): RUBY_SPECIAL_SHIFT and RUBY_FL_USHIFT are mandatory for rp in lldb_cruby.py

https://git.ruby-lang.org/ruby.git/commit/?id=0f7d3e4e40

From 0f7d3e4e405d17a1ea7db4862a1e6d65e1dfc86e Mon Sep 17 00:00:00 2001
From: Nobuyoshi Nakada <nobu@r...>
Date: Sat, 18 Apr 2020 16:35:20 +0900
Subject: RUBY_SPECIAL_SHIFT and RUBY_FL_USHIFT are mandatory for rp in
 lldb_cruby.py


diff --git a/debug.c b/debug.c
index 9b5dc01..d6c8069 100644
--- a/debug.c
+++ b/debug.c
@@ -44,6 +44,7 @@ const union { https://github.com/ruby/ruby/blob/trunk/debug.c#L44
     enum ruby_method_ids        method_ids;
     enum ruby_id_types          id_types;
     enum ruby_fl_type           fl_types;
+    enum ruby_fl_ushift         fl_ushift;
     enum ruby_encoding_consts   encoding_consts;
     enum ruby_coderange_type    enc_coderange_types;
     enum ruby_econv_flag_type   econv_flag_types;
diff --git a/include/ruby/3/fl_type.h b/include/ruby/3/fl_type.h
index 2adb600..6366e70 100644
--- a/include/ruby/3/fl_type.h
+++ b/include/ruby/3/fl_type.h
@@ -146,7 +146,7 @@ https://github.com/ruby/ruby/blob/trunk/include/ruby/3/fl_type.h#L146
 /** @} */
 
 /* This is an enum because GDB wants it (rather than a macro) */
-enum { RUBY_FL_USHIFT = 12 };
+enum ruby_fl_ushift { RUBY_FL_USHIFT = 12 };
 
 /* > The expression that defines the value  of an enumeration constant shall be
  * > an integer constant expression that has a value representable as an `int`.
diff --git a/include/ruby/3/special_consts.h b/include/ruby/3/special_consts.h
index 683cebf..3ef7b57 100644
--- a/include/ruby/3/special_consts.h
+++ b/include/ruby/3/special_consts.h
@@ -82,7 +82,7 @@ ruby_special_consts { https://github.com/ruby/ruby/blob/trunk/include/ruby/3/special_consts.h#L82
     RUBY_FIXNUM_FLAG    = 0x01, /* ...xxxx xxx1 */
     RUBY_FLONUM_MASK    = 0x03, /* ...0000 0011 */
     RUBY_FLONUM_FLAG    = 0x02, /* ...xxxx xx10 */
-    RUBY_SYMBOL_FLAG    = 0x0c  /* ...xxxx 1100 */
+    RUBY_SYMBOL_FLAG    = 0x0c, /* ...xxxx 1100 */
 #else
     RUBY_Qfalse         = 0x00, /* ...0000 0000 */
     RUBY_Qtrue          = 0x02, /* ...0000 0010 */
@@ -92,12 +92,11 @@ ruby_special_consts { https://github.com/ruby/ruby/blob/trunk/include/ruby/3/special_consts.h#L92
     RUBY_FIXNUM_FLAG    = 0x01, /* ...xxxx xxx1 */
     RUBY_FLONUM_MASK    = 0x00, /* any values ANDed with FLONUM_MASK cannot be FLONUM_FLAG */
     RUBY_FLONUM_FLAG    = 0x02, /* ...0000 0010 */
-    RUBY_SYMBOL_FLAG    = 0x0e  /* ...0000 1110 */
+    RUBY_SYMBOL_FLAG    = 0x0e, /* ...0000 1110 */
 #endif
-};
 
-/** Least significant 8 bits are reserved. */
-enum { RUBY_SPECIAL_SHIFT  = 8 };
+    RUBY_SPECIAL_SHIFT  = 8 /** Least significant 8 bits are reserved. */
+};
 
 RUBY3_ATTR_CONST()
 RUBY3_ATTR_CONSTEXPR(CXX11)
-- 
cgit v0.10.2


--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]