From ec6d0629236081a4e24e632f603aa4a0b56926a3 Mon Sep 17 00:00:00 2001 From: Travis Oliphant Date: Wed, 26 Jul 2006 21:14:14 +0000 Subject: Make version number 0.9.9 until 1.0 comes out --- numpy/lib/function_base.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'numpy/lib/function_base.py') diff --git a/numpy/lib/function_base.py b/numpy/lib/function_base.py index 44b7858f5..4789f0d0c 100644 --- a/numpy/lib/function_base.py +++ b/numpy/lib/function_base.py @@ -511,6 +511,8 @@ def unique(x): """ try: tmp = x.flatten() + if tmp.size == 0: + return tmp tmp.sort() idx = concatenate(([True],tmp[1:]!=tmp[:-1])) return tmp[idx] -- cgit v1.2.1