comp.lang.ada
 help / color / mirror / Atom feed
From: "Björn Lundin" <b.f.lundin@gmail.com>
Subject: Re: problems parse (large) json file with gnatcoll.json
Date: Thu, 21 Apr 2016 10:44:22 +0200
Date: 2016-04-21T10:44:22+02:00	[thread overview]
Message-ID: <nfa3mt$qqk$1@dont-email.me> (raw)
In-Reply-To: <0d653ce4-c8da-4bf8-8ef4-94693c158447@googlegroups.com>

On 2016-04-19 21:48, Shark8 wrote:
> 
> return Result : JSON_String := Content.all do
>   Free( Content ); -- "Free" is the instantiation of Unchecked_Deallocation.
> end return;
> 
> *BUT*
> 
> You really shouldn't need it, IIRC when the type String_Ptr goes out of scope all instances should become invalid, thus allowing the compiler to reclaim it's memory from the storage pool.
> 

That implies that there is garbage collection in the compiler.
Is that really something I can trust is correct ?


Anyway, the final solution (or last incarnation of it)
is not reading from file, as the problem originates from.
Turns out that the total solutions becomes easier if
read directly from the web



 AWS_Reply := Aws.Client.Get (Url          => Token.URL_NAVIGATION_DATA,
                              Headers      => HTTP_Headers,
                              Timeouts     =>
                               Aws.Client.Timeouts (Each => 1200.0));

 Menu := Read (Strm     => Aws.Response.Message_Body(AWS_Reply),
               Filename => "");



-- 
--
Björn


  parent reply	other threads:[~2016-04-21  8:44 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-18 18:21 problems parse (large) json file with gnatcoll.json Björn Lundin
2016-04-18 18:51 ` Jeffrey R. Carter
2016-04-18 19:05   ` Björn Lundin
2016-04-19 19:48     ` Shark8
2016-04-20  7:50       ` AdaMagica
2016-04-21  8:44       ` Björn Lundin [this message]
2016-04-25 10:38     ` briot.emmanuel
2016-04-25 15:12       ` Björn Lundin
2016-04-18 18:59 ` joakimds
2016-04-18 19:23   ` Björn Lundin
2016-04-19  8:17 ` Jacob Sparre Andersen
2016-04-19  9:14   ` Björn Lundin
2016-04-19  9:56 ` gautier_niouzes
2016-04-19 12:49   ` G.B.
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox