Mercurial > cpython-lru_cache-weakref
diff Lib/SimpleXMLRPCServer.py @ 41480:99027c2b3fd2
Remove functions in string module that are also string methods. Also remove:
* all calls to functions in the string module (except maketrans)
* everything from stropmodule except for maketrans() which is still used
| author | Neal Norwitz <nnorwitz@gmail.com> |
|---|---|
| date | Tue, 17 Apr 2007 08:48:32 +0000 |
| parents | 4cdf21a0dbbc |
| children | 06145fbc7ab9 |
line wrap: on
line diff
--- a/Lib/SimpleXMLRPCServer.py Tue Apr 17 08:42:15 2007 +0000 +++ b/Lib/SimpleXMLRPCServer.py Tue Apr 17 08:48:32 2007 +0000 @@ -21,15 +21,14 @@ class MyFuncs: def __init__(self): - # make all of the string functions available through - # string.func_name - import string - self.string = string + # make all of the sys functions available through sys.func_name + import sys + self.sys = sys def _listMethods(self): # implement this method so that system.listMethods - # knows to advertise the strings methods + # knows to advertise the sys methods return list_public_methods(self) + \ - ['string.' + method for method in list_public_methods(self.string)] + ['sys.' + method for method in list_public_methods(self.sys)] def pow(self, x, y): return pow(x, y) def add(self, x, y) : return x + y
