🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: fr.comp.lang.ada
Article #68

Re: tableau à 2 dimensions

#68
From: Georg Bauhaus
Date: Wed, 16 Jan 2013 12:08
48 lines
2831 bytes
On 15.01.13 21:14, Ludovic Brenta wrote:
>> Qu'est ce qu'on fait dans le cas suivant, quand on utilise GNAT :
>> >
>> >  pragma Restrictions (No_Accocators) ?
> On crée un tableau statique:

Il me semble que ce n'est pas practique :

pragma Restrictions (No_Allocators);

with Ada.Numerics.Generic_Real_Arrays;

package Globals is
   pragma Preelaborate (Globals);
   type T is digits 6;
   package Linalg is new
     Ada.Numerics.Generic_Real_Arrays (T);

   subtype Carré is
     Linalg.Real_Matrix (1 .. 20_000, 1 .. 20_000);

   M1, M2, Résultat : Carré;
end Globals;

with Globals;

procedure Run_Using_Globals is
   use Globals;
   use type Carré;
begin
   Résultat := M1 * M2;  -- "*" de la bibliothèque
end Run_Using_Globals;


$ ~/News/run_using_globals 

raised STORAGE_ERROR : stack overflow
$

(Aucune réponse après de compiler avec -O.)


Alors, si on veut déclarer des objets, euh, grands,
et si le compilateur est GNAT, il faut être attentif !


--
Georg Bauhaus
Technical Details
Message-ID: <50f69821$0$6555$9b4e6d93@newsspool4.arcor-online.net>
Path: arc1-ca.pugleaf.net!i11ni8416wiw.0!nntp.google.com!feeder1.cambriumusenet.nl!82.197.223.103.MISMATCH!feeder3.cambriumusenet.nl!feed.tweaknews.nl!216.40.29.245.MISMATCH!novia!border4.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!nrc-news.nrc.ca!goblin1!goblin.stu.neva.ru!feeder1-2.proxad.net!proxad.net!feeder2-2.proxad.net!newsfeed.arcor.de!newsspool4.arcor-online.net!news.arcor.de.POSTED!not-for-mail
References: <9928001f-5230-457b-a321-01f5267d8835@googlegroups.com> <87zk0js6fp.fsf@ludovic-brenta.org> <42e95ba4-0e40-4c6c-b942-d89a806d203f@googlegroups.com> <87obgyrsu2.fsf@ludovic-brenta.org> <50f54d6d$0$6582$9b4e6d93@newsspool3.arcor-online.net> <87ehhmqk4x.fsf@ludovic-brenta.org>

Show Full Headers
Complete Article Headers
X-Google-Thread: 43d0c745c,28fd0724845873a8
X-Google-Attributes: gid43d0c745c,public,usenet
X-Google-NewGroupId: yes
X-Google-Language: FRENCH,UTF8
X-Received: by 10.181.12.35 with SMTP id en3mr1719025wid.2.1358655366155;
        Sat, 19 Jan 2013 20:16:06 -0800 (PST)
Path: arc1-ca.pugleaf.net!i11ni8416wiw.0!nntp.google.com!feeder1.cambriumusenet.nl!82.197.223.103.MISMATCH!feeder3.cambriumusenet.nl!feed.tweaknews.nl!216.40.29.245.MISMATCH!novia!border4.nntp.dca.giganews.com!border2.nntp.dca.giganews.com!nntp.giganews.com!nrc-news.nrc.ca!goblin1!goblin.stu.neva.ru!feeder1-2.proxad.net!proxad.net!feeder2-2.proxad.net!newsfeed.arcor.de!newsspool4.arcor-online.net!news.arcor.de.POSTED!not-for-mail
Date: Wed, 16 Jan 2013 13:08:01 +0100
From: Georg Bauhaus <rm.dash-bauhaus@futureapps.de>
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:17.0) Gecko/20130107 Thunderbird/17.0.2
MIME-Version: 1.0
Newsgroups: fr.comp.lang.ada
Subject: Re: tableau à 2 dimensions
References: <9928001f-5230-457b-a321-01f5267d8835@googlegroups.com> <87zk0js6fp.fsf@ludovic-brenta.org> <42e95ba4-0e40-4c6c-b942-d89a806d203f@googlegroups.com> <87obgyrsu2.fsf@ludovic-brenta.org> <50f54d6d$0$6582$9b4e6d93@newsspool3.arcor-online.net> <87ehhmqk4x.fsf@ludovic-brenta.org>
In-Reply-To: <87ehhmqk4x.fsf@ludovic-brenta.org>
X-Enigmail-Version: 1.5
Lines: 49
Message-ID: <50f69821$0$6555$9b4e6d93@newsspool4.arcor-online.net>
Organization: Arcor
NNTP-Posting-Date: 16 Jan 2013 13:08:01 CET
NNTP-Posting-Host: ecc0155c.newsspool4.arcor-online.net
X-Trace: DXC=7MNh61PIjPE@k=MdN::NBI4IUK<Cl32<A4Fo<]lROoRA8kF<OcfhCOK?kaliLGR5R@nc\616M64>JLh>_cHTX3jMO?9U^bObGTB
X-Complaints-To: usenet-abuse@arcor.de
Bytes: 2405
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit