[Matrix-SIG] Small patch to UserArray.py in LLNLDistribution11
Neel Krishnaswami
neelk@alum.mit.edu
Thu, 20 May 1999 21:18:54 -0500 (EST)
Hi,
I just downloaded and built the Numeric package in LLNL Distribution
11. I found a small problem in the UserArray.py module though -- it
wasn't working correctly because of inconsistent indentation in the
UserArray.__init__() method. (The indentation incorrectly defined all
the methods *inside* __init__()'s scope.)
Here's a small diff demonstrating the fix.
--- UserArray.py~ Thu May 20 20:49:44 1999
+++ UserArray.py Thu May 20 21:03:33 1999
@@ -2,11 +2,11 @@
import string
class UserArray:
- def __init__(self, data, typecode = None):
- self.array = array(data, typecode)
- self.shape = self.array.shape
- self._typecode = self.array.typecode()
- self.name = string.split(str(self.__class__))[0]
+ def __init__(self, data, typecode = None):
+ self.array = array(data, typecode)
+ self.shape = self.array.shape
+ self._typecode = self.array.typecode()
+ self.name = string.split(str(self.__class__))[0]
def __repr__(self):
return self.name+repr(self.array)[len("array"):]
--
Neel Krishnaswami
neelk@alum.mit.edu