Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Joel Brobecker <brobecker@adacore.com>
To: mike tiberium <mike.tiberium@gmail.com>
Cc: gdb@sourceware.org
Subject: Re: GDB with Ada doesn't print variables neither works with GPS
Date: Mon, 30 Jul 2007 03:21:00 -0000	[thread overview]
Message-ID: <20070729232307.GA3758@adacore.com> (raw)
In-Reply-To: <5fd4beb00707291536k64988989t4d029e4390790ea0@mail.gmail.com>

> It seems I'm unable to print variables properly in GDB when debugging
> an Ada application. This is the best I can get:
> 
> (gdb) p /c Hello_String.all
> $1 = (72 'H', 101 'e', 108 'l', 108 'l', 111 'o')

The only thing that you are missing here is the fact that this string
is not printed as a usual string but instead an array of characters.
I suspect that the reason that GDB does not identify your object as
a string is incomplete/incorrect debugging info.

What does ptype Hello_String.all say? It should say "array of
character". If it doesn't then, the GDB output is expected.

For your GPS issues, it's most likely an issue with your kernel
configuration, but I can't help you with that.

-- 
Joel


  reply	other threads:[~2007-07-29 23:20 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <5fd4beb00707291452j430533b1q37f924b63fdc456c@mail.gmail.com>
2007-07-29 23:20 ` mike tiberium
2007-07-30  3:21   ` Joel Brobecker [this message]
     [not found]     ` <5fd4beb00707311220s36442a40lf45b0857bfa9196d@mail.gmail.com>
2007-08-01  6:40       ` Joel Brobecker
2007-08-01  0:10   ` debugging the multithreads on PPC embedded platfom Jayasri Sangu
2007-08-01  3:15     ` Eli Zaretskii
2007-08-01  3:22     ` Daniel Jacobowitz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20070729232307.GA3758@adacore.com \
    --to=brobecker@adacore.com \
    --cc=gdb@sourceware.org \
    --cc=mike.tiberium@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox