mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
.gdbinit: improve rp for class
* .gdbinit (rp): improve for class/iclass/module so print content of RClass. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36186 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
91fcdd1865
commit
5a7db50517
1 changed files with 6 additions and 0 deletions
6
.gdbinit
6
.gdbinit
|
@ -107,14 +107,20 @@ define rp
|
|||
if ($flags & RUBY_T_MASK) == RUBY_T_CLASS
|
||||
printf "T_CLASS%s: ", ($flags & RUBY_FL_SINGLETON) ? "*" : ""
|
||||
print (struct RClass *)($arg0)
|
||||
print *(struct RClass *)($arg0)
|
||||
print *((struct RClass *)($arg0))->ptr
|
||||
else
|
||||
if ($flags & RUBY_T_MASK) == RUBY_T_ICLASS
|
||||
printf "T_ICLASS: "
|
||||
print (struct RClass *)($arg0)
|
||||
print *(struct RClass *)($arg0)
|
||||
print *((struct RClass *)($arg0))->ptr
|
||||
else
|
||||
if ($flags & RUBY_T_MASK) == RUBY_T_MODULE
|
||||
printf "T_MODULE: "
|
||||
print (struct RClass *)($arg0)
|
||||
print *(struct RClass *)($arg0)
|
||||
print *((struct RClass *)($arg0))->ptr
|
||||
else
|
||||
if ($flags & RUBY_T_MASK) == RUBY_T_FLOAT
|
||||
printf "T_FLOAT: %.16g ", (((struct RFloat*)($arg0))->float_value)
|
||||
|
|
Loading…
Add table
Reference in a new issue