]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Removed GNU gcc extensions in AliITSSortTrkl
authormasera <masera@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 7 Jan 2009 20:02:53 +0000 (20:02 +0000)
committermasera <masera@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 7 Jan 2009 20:02:53 +0000 (20:02 +0000)
ITS/AliITSSortTrkl.cxx
ITS/AliITSSortTrkl.h
ITS/CMake_libITSrec.txt
ITS/ITSrecLinkDef.h
ITS/libITSrec.pkg

index d2cf229c322acf684e5b2672f0da4315933fb771..13ad17b2e3935c13d5dd3df98832c6c65693601e 100644 (file)
@@ -190,15 +190,19 @@ Int_t AliITSSortTrkl::FindClusters(){
 void AliITSSortTrkl::Cleanup(){
   // empty arrays are eliminated, the others are sorted according
   // to cluster multiplicity
-  Int_t siz[fIndex-1];
-  Int_t index[fIndex-1];
+  Int_t *siz = new Int_t[fIndex-1];
+  Int_t *index = new Int_t[fIndex-1];
   fNoClus=0;
   for(Int_t i=0; i<fIndex-1;i++){
     Int_t *v=fClustersTmp[i];
     if(v[0]>0)fNoClus++;
     siz[i]=v[0];
   }
-  if(fNoClus == 0)return;
+  if(fNoClus == 0){
+    delete []siz;
+    delete [] index;
+    return;
+  }
   TMath::Sort(fIndex-1,siz,index);
   fClusters = new Int_t* [fNoClus];
   fSize = new Int_t [fNoClus];
@@ -211,6 +215,8 @@ void AliITSSortTrkl::Cleanup(){
     vext[0]=curind;
     for(Int_t j=1;j<fSize[i];j++)vext[j]=v[j];
   }
+  delete []siz;
+  delete [] index;
 }
 
 //______________________________________________________________________
@@ -252,9 +258,9 @@ void AliITSSortTrkl::SortAndClean(Int_t numb, Int_t *arr, Int_t& numb2){
   // of elements are eliminated. numb2 is the number of remaining elements
   // after cleanup.
   if(numb<=0)return;
-  Int_t index[numb];
+  Int_t* index = new Int_t[numb];
   TMath::Sort(numb,arr,index,kFALSE);
-  Int_t tmp[numb];
+  Int_t* tmp = new Int_t[numb];
   numb2 = 0;
   tmp[0] = arr[index[0]];
   for(Int_t i=1;i<numb;i++){
@@ -272,6 +278,8 @@ void AliITSSortTrkl::SortAndClean(Int_t numb, Int_t *arr, Int_t& numb2){
       arr[i]=0;
     }
   }
+  delete [] index;
+  delete [] tmp;
 }
 
 //______________________________________________________________________
index 8d9693b29e581f7220b2ee1898ee473cec232221..7bf36664f570402df44758686f347e9a0bc44424 100644 (file)
@@ -51,7 +51,7 @@ class AliITSSortTrkl : public TObject {
   void DeleteClustersTmp();
   void PrepareClustersTmp();
   void Clustering(Int_t i, Int_t *v);
-  Int_t* AliITSSortTrkl::FindLabels(Int_t *v, Int_t dimmax, Int_t& dim) const;
+  Int_t* FindLabels(Int_t *v, Int_t dimmax, Int_t& dim) const;
 
   const Int_t fkSize;         // Maximum number of tracklet pairs
   Int_t fIndex;               // Total number of tracklet pairs (<=fkSize)
index 9caf5482b94f29ae2909f6fedd86cf112ba1e464..a709118168cae11890635fe815a50e8bef73ff15 100644 (file)
@@ -20,6 +20,8 @@ set(SRCS
                AliITSVertexerIons.cxx 
                AliITSVertexerCosmics.cxx 
                AliITSVertexer3D.cxx
+               AliITSTracklPairs.cxx 
+               AliITSSortTrkl.cxx
                AliITSVertexerZ.cxx 
                AliITSVertexerFast.cxx 
                AliITSVertexerFixed.cxx 
index c0ad23035f480cdb9e73eb7635f2e13b7d9a3f28..968447b6a9f87f688e0c3f9c4175b5834fb2a043 100644 (file)
@@ -38,8 +38,8 @@
 #pragma link C++ class  AliITSVertexerZ+;
 #pragma link C++ class  AliITSVertexer3D+;
 #pragma link C++ class  AliITSVertexer3DTapan+;
-//#pragma link C++ class  AliITSTracklPairs+;
-//#pragma link C++ class  AliITSSortTrkl+;
+#pragma link C++ class  AliITSTracklPairs+;
+#pragma link C++ class  AliITSSortTrkl+;
 #pragma link C++ class AliITSVertexerFast+;
 #pragma link C++ class AliITSVertexerFixed+;
 #pragma link C++ class  AliITSMeanVertexer+;
index ca99219dce9b897592ba75b60e34ee0e3a30547d..1c6d1deaa57ae3d5a1b499cf2968f497a321b957 100644 (file)
@@ -19,6 +19,8 @@ SRCS =        AliITSDetTypeRec.cxx \
                AliITSVertexerIons.cxx \
                AliITSVertexerCosmics.cxx \
                AliITSVertexer3D.cxx \
+               AliITSTracklPairs.cxx \
+               AliITSSortTrkl.cxx \
                AliITSVertexerZ.cxx \
                AliITSVertexerFast.cxx \
                AliITSVertexerFixed.cxx \