summaryrefslogtreecommitdiff
path: root/numpy/core/src
diff options
context:
space:
mode:
authorTravis Oliphant <oliphant@enthought.com>2006-07-06 08:24:25 +0000
committerTravis Oliphant <oliphant@enthought.com>2006-07-06 08:24:25 +0000
commitfdd32af7eb958ae1bf055f1b36712f34dbfaf2a8 (patch)
treeed6f63395b5743bb8cc589a4ea41db63add76dc6 /numpy/core/src
parent2f4f567759dab5880c206ffa63bf3b8fdeceed82 (diff)
downloadnumpy-fdd32af7eb958ae1bf055f1b36712f34dbfaf2a8.tar.gz
Add comments for VOID_compare)
Diffstat (limited to 'numpy/core/src')
-rw-r--r--numpy/core/src/arraytypes.inc.src13
1 files changed, 11 insertions, 2 deletions
diff --git a/numpy/core/src/arraytypes.inc.src b/numpy/core/src/arraytypes.inc.src
index f183c7cc5..be8fa159d 100644
--- a/numpy/core/src/arraytypes.inc.src
+++ b/numpy/core/src/arraytypes.inc.src
@@ -1571,9 +1571,18 @@ UNICODE_compare(register PyArray_UCS4 *ip1, register PyArray_UCS4 *ip2,
}
/* possibly redefine compare in terms of fields and subarrays if any */
+/* this would have to properly align data (if needed for the type)
+ before passing on to the _compare function of sub-fields
-/* as it is, it compares raw-bytes as it they were strings */
-#define VOID_compare STRING_compare
+ More importantly, it's unclear what is meant by < and > so we really
+ can't implement it correctly.
+*/
+
+static int
+VOID_compare(char *ip1, char *ip2, PyArrayObject *ap)
+{
+ return STRING_compare(ip1, ip2, ap);
+}
/****************** argfunc **********************************/