Index: /trunk/psLib/src/mathtypes/psVector.c
===================================================================
--- /trunk/psLib/src/mathtypes/psVector.c	(revision 11695)
+++ /trunk/psLib/src/mathtypes/psVector.c	(revision 11696)
@@ -9,6 +9,6 @@
 *  @author Robert DeSonia, MHPCC
 *
-*  @version $Revision: 1.91 $ $Name: not supported by cvs2svn $
-*  @date $Date: 2007-02-06 21:36:09 $
+*  @version $Revision: 1.92 $ $Name: not supported by cvs2svn $
+*  @date $Date: 2007-02-08 02:31:59 $
 *
 *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -73,7 +73,9 @@
 
 // Allocate a psVector; does not set vector->n (left to the caller)
-static psVector *vectorAlloc(long nalloc, // Number of elements to allocate
-                             psElemType type // Type of elements
-                            )
+static psVector *vectorAlloc(const char *file,
+                             unsigned int lineno,
+                             const char *func,
+                             long nalloc, // Number of elements to allocate
+                             psElemType type) // Type of elements
 {
     int elementSize = PSELEMTYPE_SIZEOF(type); // Size, in bytes, of element
@@ -85,5 +87,5 @@
 
     // Create vector struct
-    psVector *vector = (psVector*) psAlloc(sizeof(psVector));
+    psVector *vector = (psVector*) p_psAlloc(file, lineno, func, sizeof(psVector));
     psMemSetDeallocator(vector, (psFreeFunc) vectorFree);
 
@@ -98,8 +100,11 @@
 }
 
-psVector* psVectorAlloc(long nalloc,
-                        psElemType type)
-{
-    psVector *vector = vectorAlloc(nalloc, type);
+psVector* p_psVectorAlloc(const char *file,
+                          unsigned int lineno,
+                          const char *func,
+                          long nalloc,
+                          psElemType type)
+{
+    psVector *vector = vectorAlloc(file, lineno, func, nalloc, type);
     if (!vector) {
         return NULL;
@@ -109,8 +114,11 @@
 }
 
-psVector* psVectorAllocEmpty(long nalloc,
-                             psElemType type)
-{
-    psVector *vector = vectorAlloc(nalloc, type);
+psVector* p_psVectorAllocEmpty(const char *file,
+                               unsigned int lineno,
+                               const char *func,
+                               long nalloc,
+                               psElemType type)
+{
+    psVector *vector = vectorAlloc(file, lineno, func, nalloc, type);
     if (!vector) {
         return NULL;
Index: /trunk/psLib/src/mathtypes/psVector.h
===================================================================
--- /trunk/psLib/src/mathtypes/psVector.h	(revision 11695)
+++ /trunk/psLib/src/mathtypes/psVector.h	(revision 11696)
@@ -9,6 +9,6 @@
  * @author Ross Harman, MHPCC
  *
- * @version $Revision: 1.62 $ $Name: not supported by cvs2svn $
- * @date $Date: 2007-02-06 21:36:09 $
+ * @version $Revision: 1.63 $ $Name: not supported by cvs2svn $
+ * @date $Date: 2007-02-08 02:31:59 $
  * Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
  */
@@ -77,8 +77,25 @@
  * @return psVector*    Pointer to psVector.
  */
+#ifdef DOXYGEN
 psVector* psVectorAlloc(
     long nalloc,                       ///< Total number of elements to make available.
     psElemType type                    ///< Type of data to be held by vector.
 );
+#else // ifdef DOXYGEN
+psVector* p_psVectorAlloc(
+    const char *file,                   ///< File of caller
+    unsigned int lineno,                ///< Line number of caller
+    const char *func,                   ///< Function name of caller 
+    long nalloc,                        ///< Total number of elements to make available.
+    psElemType type                    ///< Type of data to be held by vector.
+//#ifdef __GNUC__
+//) __attribute__((malloc));
+//#else // ifdef __GNUC__
+);
+//#endif // ifdef __GNUC__
+#define psVectorAlloc(nalloc, type) \
+      p_psVectorAlloc(__FILE__, __LINE__, __func__, nalloc, type) 
+#endif // ifdef DOXYGEN
+
 
 /** Allocate a vector, with length set to zero
@@ -89,8 +106,25 @@
  * @return psVector*    Pointer to psVector.
  */
+#ifdef DOXYGEN
 psVector* psVectorAllocEmpty(
     long nalloc,                       ///< Total number of elements to make available.
     psElemType type                    ///< Type of data to be held by vector.
 );
+#else // ifdef DOXYGEN
+psVector* p_psVectorAllocEmpty(
+    const char *file,                   ///< File of caller
+    unsigned int lineno,                ///< Line number of caller
+    const char *func,                   ///< Function name of caller 
+    long nalloc,                       ///< Total number of elements to make available.
+    psElemType type                    ///< Type of data to be held by vector.
+//#ifdef __GNUC__
+//) __attribute__((malloc));
+//#else // ifdef __GNUC__
+);
+//#endif // ifdef __GNUC__
+#define psVectorAllocEmpty(nalloc, type) \
+      p_psVectorAllocEmpty(__FILE__, __LINE__, __func__, nalloc, type) 
+#endif // ifdef DOXYGEN
+
 
 /** Reallocate a vector.
@@ -107,4 +141,5 @@
     long nalloc                        ///< Total number of elements to make available.
 );
+
 
 /** Extend a vector's length.
@@ -123,4 +158,5 @@
 );
 
+
 /** Recycle a vector.
  *
@@ -141,4 +177,5 @@
 );
 
+
 /** Copy a vector, converting types.
  *
@@ -155,4 +192,5 @@
 );
 
+
 /** Sort an array of floats.
  *
@@ -167,4 +205,5 @@
 );
 
+
 /** Creates an array of indices based on sort ordered of array.
  *
@@ -179,4 +218,5 @@
 );
 
+
 /** Creates a string from a psVector's values in the form "[x0,x1,x2]".
  *
@@ -188,4 +228,5 @@
 );
 
+
 /** Returns an element in the vector as a psF64 value
  *
@@ -196,4 +237,5 @@
     int position                       ///< the vector position to get
 );
+
 
 /** Print a vector to a stream
@@ -207,7 +249,9 @@
 );
 
+
 /** Initializes the vector with the given value.
  *
- *  The input data is cast to match the vector datatype, allowing for integers to be preserved.
+ *  The input data is cast to match the vector datatype, allowing for integers
+ *  to be preserved.
  *
  *  @return bool:       True if successful, otherwise false.
@@ -218,9 +262,10 @@
 );
 
+
 /** Creates a new vector, or reallocates the provided vector if input is not NULL.
  *
- *  The created vector consists of the data range starting at lower, running to upper,
- *  in steps of delta.  The upper-end value is exclusive; the sequence is equivalent to
- *  for (x = lower; x <= upper - 1; x += delta).
+ *  The created vector consists of the data range starting at lower, running to
+ *  upper, in steps of delta.  The upper-end value is exclusive; the sequence
+ *  is equivalent to for (x = lower; x <= upper - 1; x += delta).
  *
  *  @return psVector*:       the newly created psVector
@@ -234,4 +279,5 @@
 );
 
+
 /** Sets the value of the input vector at the specified position to value.
  *
@@ -246,4 +292,5 @@
 );
 
+
 /** Returns the value of the input vector at the specified position.
  *
@@ -257,7 +304,9 @@
 );
 
+
 /** Returns the number of pixels in the vector which satisfy any of the mask bits.
  *
- *  An error (eg, invalid vector) results in a return value of -1.  The vector must be U8.
+ *  An error (eg, invalid vector) results in a return value of -1.  The vector
+ *  must be U8.
  *
  *  @return long:       the number of pixels counted
@@ -267,4 +316,5 @@
     psMaskType value                   ///< the mask value to satisfy
 );
+
 
 /** Get the number of elements in use from a specified psVector. (vector.n)
