Index: trunk/psLib/src/collections/psSort.c
===================================================================
--- trunk/psLib/src/collections/psSort.c	(revision 811)
+++ trunk/psLib/src/collections/psSort.c	(revision 831)
@@ -14,6 +14,6 @@
  *  @author Ross Harman, MHPCC
  *   
- *  @version $Revision: 1.9 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2004-05-13 22:47:52 $
+ *  @version $Revision: 1.10 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2004-06-02 23:29:14 $
  *
  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -129,6 +129,6 @@
     inN = inVector->n;
     outN = outVector->n;
-    inVec = inVector->vec.f;
-    outVec = outVector->vec.f;
+    inVec = inVector->data.F32;
+    outVec = outVector->data.F32;
     elSize = sizeof(float);
 
@@ -188,6 +188,6 @@
     inN = inVector->n;
     outN = outVector->n;
-    inVec = inVector->vec.f;
-    outVec = outVector->vec.i32;
+    inVec = inVector->data.F32;
+    outVec = outVector->data.S32;
 
     if(inN != outN) {
@@ -197,10 +197,10 @@
     }
 
-    tmpFloatVector = psVectorAlloc(PS_TYPE_FLOAT, inN);
+    tmpFloatVector = psVectorAlloc(inN, PS_TYPE_F32);
     tmpFloatVector->n = inN;
     tmpFloatVector = psSort(tmpFloatVector, inVector);
 
     for(i=0; i<inN; i++) {
-        tempVal = tmpFloatVector->vec.f[i];
+        tempVal = tmpFloatVector->data.F32[i];
         for(j=0; j<inN; j++) {
             diff = fabsf(tempVal - inVec[j]);
Index: trunk/psLib/src/collections/psVector.c
===================================================================
--- trunk/psLib/src/collections/psVector.c	(revision 811)
+++ trunk/psLib/src/collections/psVector.c	(revision 831)
@@ -19,6 +19,6 @@
  *  @author Ross Harman, MHPCC
  *   
- *  @version $Revision: 1.6 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2004-05-29 01:08:46 $
+ *  @version $Revision: 1.7 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2004-06-02 23:29:14 $
  *
  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -64,5 +64,5 @@
 /* FUNCTION IMPLEMENTATION - PUBLIC                                          */
 /*****************************************************************************/
-psVector* psVectorAlloc(psElemType elemType, unsigned int nalloc)
+psVector* psVectorAlloc(unsigned int nalloc, psElemType elemType)
 {
     psVector *psVec = NULL;
@@ -86,10 +86,10 @@
 
     // Create vector data array
-    psVec->vec.v = psAlloc(nalloc*elementSize);
+    psVec->data.V = psAlloc(nalloc*elementSize);
 
     return psVec;
 }
 
-psVector *psVectorRealloc(psVector *restrict in, unsigned int nalloc)
+psVector *psVectorRealloc(unsigned int nalloc, psVector *restrict in)
 {
     int elementSize = 0;
@@ -110,5 +110,5 @@
             if (elemType == PS_TYPE_PTR) {
                 for (int i = nalloc; i < in->n; i++) {   // For reduction in vector size
-                    psMemDecrRefCounter(in->vec.vp[i]);
+                    psMemDecrRefCounter(in->data.PTR[i]);
                 }
             }
@@ -117,5 +117,5 @@
 
         // Realloc after decrementation to avoid accessing freed array elements
-        in->vec.v = psRealloc(in->vec.v,nalloc*elementSize);
+        in->data.V = psRealloc(in->data.V,nalloc*elementSize);
         in->nalloc = nalloc;
     }
@@ -129,5 +129,5 @@
 
     if (in == NULL) {
-        return psVectorAlloc(type,nalloc);
+        return psVectorAlloc(nalloc, type);
     }
 
@@ -150,10 +150,10 @@
     if (elemType == PS_TYPE_PTR) {
         for (int i = 0; i < in->n; i++) {   // For reduction in vector size
-            psMemDecrRefCounter(in->vec.vp[i]);
-            in->vec.vp[i] = NULL;
+            psMemDecrRefCounter(in->data.PTR[i]);
+            in->data.PTR[i] = NULL;
         }
     }
 
-    in->vec.v = psRealloc(in->vec.v,nalloc*PSELEMTYPE_SIZEOF(elemType));
+    in->data.V = psRealloc(in->data.V,nalloc*PSELEMTYPE_SIZEOF(elemType));
 
     in->n = 0;
@@ -170,5 +170,5 @@
     }
 
-    psFree(psVec->vec.v);
+    psFree(psVec->data.V);
     psFree(psVec);
 }
@@ -188,9 +188,9 @@
     for(int i = 0; i < psVec->nalloc; i++) {
         if(elemFree == NULL) {
-            psMemDecrRefCounter(psVec->vec.vp[i]);
+            psMemDecrRefCounter(psVec->data.PTR[i]);
         } else {
-            elemFree(psMemDecrRefCounter(psVec->vec.vp[i]));
+            elemFree(psMemDecrRefCounter(psVec->data.PTR[i]));
         }
-        psVec->vec.vp[i] = NULL;
+        psVec->data.PTR[i] = NULL;
     }
 }
Index: trunk/psLib/src/collections/psVector.h
===================================================================
--- trunk/psLib/src/collections/psVector.h	(revision 811)
+++ trunk/psLib/src/collections/psVector.h	(revision 831)
@@ -1,24 +1,14 @@
 /** @file  psVector.h
  *
- *  @brief Contains support for basic vector types
+ *  @brief Contains basic vector definitions and operations
  *
- *  This file defines types and functions for one dimensional vectors which include:
- *      char
- *      short
- *      int
- *      long
- *      unsigned char
- *      unsigned short
- *      unsigned int
- *      unsigned long
- *      float
- *      double
- *      complex float
- *      void **
+ *  This file defines the basic type for a vector struct and functions useful
+ *  in manupulating vectors.
  *
+ *  @author Robert DeSonia, MHPCC
  *  @author Ross Harman, MHPCC
  *
- *  @version $Revision: 1.7 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2004-05-29 01:08:46 $
+ *  @version $Revision: 1.8 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2004-06-02 23:29:14 $
  *
  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -42,18 +32,19 @@
 
     union {
-        int8_t *i8;                     ///< Pointers to char integer data.
-        int16_t *i16;                   ///< Pointers to short integer data.
-        int32_t *i32;                   ///< Pointers to integer data.
-        int64_t *i64;                   ///< Pointers to long integer data.
-        uint8_t *ui8;                   ///< Pointers to unsigned char integer data.
-        uint16_t*ui16;                  ///< Pointers to unsigned short integer data.
-        uint32_t *ui32;                 ///< Pointers to unsigned integer data.
-        uint64_t *ui64;                 ///< Pointers to unsigned long integer data.
-        float *f;                       ///< Pointers to floating point data.
-        double *d;                      ///< Pointers to double precision data.
-        complex float *cf;              ///< Pointers to complex floating point data.
-        void *v;                        ///< Pointers to generic void data
-        void **vp;                      ///< Void pointer vector.
-    }vec;                               ///< Union for data types.
+        psU8    *U8;                    ///< Unsigned 8-bit integer data.
+        psU16   *U16;                   ///< Unsigned 16-bit integer data.
+        psU32   *U32;                   ///< Unsigned 32-bit integer data.
+        psU64   *U64;                   ///< Unsigned 64-bit integer data.
+        psS8    *S8;                    ///< Signed 8-bit integer data.
+        psS16   *S16;                   ///< Signed 16-bit integer data.
+        psS32   *S32;                   ///< Signed 32-bit integer data.
+        psS64   *S64;                   ///< Signed 64-bit integer data.
+        psF32   *F32;                   ///< Single-precision float data.
+        psF64   *F64;                   ///< Double-precision float data.
+        psC32   *C32;                   ///< Single-precision complex data.
+        psC64   *C64;                   ///< Double-precision complex data.
+        psPTR   *PTR;                   ///< Void pointers
+        psPTR    V;                     ///< Pointer to data
+    } data;                             ///< Union for data types.
 }
 psVector;
@@ -71,6 +62,6 @@
  */
 psVector *psVectorAlloc(
-    psElemType dataType,                ///< Type of data to be held by vector.
-    unsigned int nalloc                 ///< Total number of elements to make available.
+    unsigned int nalloc,                ///< Total number of elements to make available.
+    psElemType dataType                 ///< Type of data to be held by vector.
 );
 
@@ -84,6 +75,6 @@
  */
 psVector *psVectorRealloc(
-    psVector *restrict psVec,           ///< Vector to reallocate.
-    unsigned int nalloc                 ///< Total number of elements to make available.
+    unsigned int nalloc,                ///< Total number of elements to make available.
+    psVector *restrict psVec            ///< Vector to reallocate.
 );
 
