gdbinit: add a new command and fix one
authorMartin Liska <mliska@suse.cz>
Thu, 30 May 2019 07:50:39 +0000 (09:50 +0200)
committerMartin Liska <marxin@gcc.gnu.org>
Thu, 30 May 2019 07:50:39 +0000 (07:50 +0000)
2019-05-30  Martin Liska  <mliska@suse.cz>

* gdbinit.in: Fix 'ptc' command.  Add trt
that prints TREE_TYPE($).

From-SVN: r271763

gcc/ChangeLog
gcc/gdbinit.in

index cc1b6b4..ecbb87f 100644 (file)
@@ -1,3 +1,8 @@
+2019-05-30  Martin Liska  <mliska@suse.cz>
+
+       * gdbinit.in: Fix 'ptc' command.  Add trt
+       that prints TREE_TYPE($).
+
 2019-05-29  Bill Schmidt  <wschmidt@linux.ibm.com>
            Alan Modra  <amodra@gmail.com>
 
index e16c3c8..440fd25 100644 (file)
@@ -113,7 +113,7 @@ Works only when an inferior is executing.
 end
 
 define ptc
-output (enum tree_code) $.common.code
+output (enum tree_code) $.base.code
 echo \n
 end
 
@@ -201,6 +201,14 @@ document pcfun
 Print current function.
 end
 
+define trt
+print ($.typed.type)
+end
+
+document trt
+Print TREE_TYPE of the tree node that is $
+end
+
 define break-on-diagnostic
 break diagnostic_show_locus
 end