From: "ldries46" <bertus.dries@planet.nl>
Subject: Re: Length of unbounded_string.
Date: Tue, 18 Oct 2011 13:47:15 +0200
Date: 2011-10-18T13:47:15+02:00 [thread overview]
Message-ID: <4e9d6722$0$3244$703f8584@news.kpn.nl> (raw)
In-Reply-To: <9g3f3kFfr7U1@mid.individual.net>
The program I am writing is a window oriented program. I am using GTKADA for
the windows. When I write the string to the window it also misses the comma.
Also further on in the program before writing to the window I check for the
comma but the function I need to do is not performed so that is another
reason why I think the comma is not present.
"Niklas Holsti" schreef in bericht news:9g3f3kFfr7U1@mid.individual.net...
On 11-10-17 09:39 , ldries46 wrote:
> I have to strings I want to concatenate with a space in between. The
> first (str) ends with a ','.
> The output seems to be a concatenation where the ',' is missing.
> A can see with the debugging facilities that before the concatenation
> there is a ',' and after the concatenation depending on the type of
> facility I use the comma is present (debug\print) or is not
> (debug\display).
And what happens if you simply print it with Ada.Text_IO?
In my experience, gdb sometimes (well, rather often) prints complex Ada
structures incorrectly or incompletely.
> The last one is consistent with the display of the line in a gtk window.
> For further use I need that comma, but I cannot add it explicitly
> because as can beseen in the code I can reach rhat code also in some
> other cases.
Of course you could divide the code inte more cases, separating the
comma case from the other cases.
>
> L. Dries
> "Niklas Holsti" schreef in bericht news:9g02plFrnlU1@mid.individual.net...
>
> On 11-10-16 14:52 , ldries46 wrote:
>> Sorry I just thought to simplify the problem but did that the wrong way
>> my real problem is in the following code:
>>
>> ch := Element(str, len);
>> if ch = ',' or (ch /= ';' and ch /= '{' and ch /= '}') then
>> nr := nr + 1;
>> str := str & " " & Next_Line;
That code is incomplete. Where is the "end if"?
If you want more help, please try to make a small, self-contained
example in which the problem occurs, and show the whole code.
>>
>> where in the first line
>> print str.reference.data
>> $24 = "static void gtk_print_job_set_property (GObject *object", ','
Why is gdb speaking of GObject? I tought "str" was mean to be
Ada.Strings.Unbounded.Unbounded_String, not some Gtk type.
--
Niklas Holsti
Tidorum Ltd
niklas holsti tidorum fi
. @ .
next prev parent reply other threads:[~2011-10-18 11:47 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-16 8:48 Length of unbounded_string ldries46
2011-10-16 9:59 ` Niklas Holsti
2011-10-16 12:06 ` ldries46
2011-10-16 12:52 ` ldries46
2011-10-16 13:00 ` Niklas Holsti
2011-10-17 7:39 ` ldries46
2011-10-17 19:49 ` Niklas Holsti
2011-10-18 11:47 ` ldries46 [this message]
2011-10-18 17:54 ` Niklas Holsti
2011-10-19 2:38 ` ldries46
2011-10-19 6:07 ` Niklas Holsti
2011-10-24 15:10 ` ldries46
2011-10-19 6:37 ` Simon Wright
2011-10-19 14:48 ` Alex Mentis
2011-10-24 17:04 ` ldries46
2011-10-16 10:14 ` Vinzent Hoefler
-- strict thread matches above, loose matches on Subject: below --
2011-10-25 9:37 ldries46
2011-10-25 17:57 ` Jeffrey Carter
2011-10-28 2:54 ` ldries46
2011-10-28 4:55 ` Jeffrey Carter
2011-10-25 20:23 ` Vadim Godunko
2011-10-25 21:28 ` Simon Wright
2011-10-26 4:41 ` Simon Wright
2011-10-26 22:47 ` Randy Brukardt
2011-10-27 8:05 ` AdaMagica
2011-10-27 8:56 ` Simon Wright
2011-10-27 11:05 ` Brian Drummond
2011-10-28 3:12 ` ldries46
[not found] ` <4eafc489$0$3081$703f8584@textnews.kpn.nl>
2011-11-01 18:22 ` Jeffrey Carter
2011-10-27 11:28 ` Georg Bauhaus
2011-10-27 12:17 ` Dmitry A. Kazakov
2011-10-27 13:31 ` Georg Bauhaus
2011-10-27 14:34 ` Dmitry A. Kazakov
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox