Bonjour

En TurboPascal, j'utilisais GetMem pur créér des tableaux de grande taille (limités à 32000 octets environ).
Pour transposer en FreePascal, j'ai procédé de même. Pour d'autres adaptations dont un programme jumeau cela fonctionne, mais pas ici.

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
 
type indCourt = record
		          nom     : string6;
                  	  adresse : smallInt;
                	  nbFFB   : longint;
                	end;
         tabIndCourt = array [1..1] of indCourt;
 
var CIndex : ^tabIndCourt;
 
procedure CIndex_Filou;
var Nb_W : word;
      vu : boolean;
begin
  vu:=true;
  nb9899:=1850;
  if vu then Erreurs(30,'début de CIndex_Filou');
 
  nb_w:=nb9899*sizeof(indcourt);
  if vu then writeln('total = ',nb_w);      { soit environ 29000 octets }
  if vu then Erreurs(30,'avant getmem');
  GetMem (CIndex, nb_w);
  if vu then Erreurs(30,'fin de CIndex_Filou'); 
end;
Pourriez-vous me donner un conseil ?
Merci
Bernard