summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHye-Shik Chang <hyeshik@gmail.com>2004-06-04 04:23:29 (GMT)
committerHye-Shik Chang <hyeshik@gmail.com>2004-06-04 04:23:29 (GMT)
commit6838c557faaffc9fb54091dd3fa8e37ca70ab069 (patch)
treed6cb44bcb067c198f3e5d524794a10ada9e35ccd
parent7bd860655f8343fe02439a457bc59f7cd7d9eda8 (diff)
downloadcpython-6838c557faaffc9fb54091dd3fa8e37ca70ab069.zip
cpython-6838c557faaffc9fb54091dd3fa8e37ca70ab069.tar.gz
cpython-6838c557faaffc9fb54091dd3fa8e37ca70ab069.tar.bz2
Add comments for unicode-only methods to give hints on AttributeError
tracebacks. (Suggested by Walter Dörwald)
-rwxr-xr-xLib/UserString.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/UserString.py b/Lib/UserString.py
index 914f3ce..1f1e87c 100755
--- a/Lib/UserString.py
+++ b/Lib/UserString.py
@@ -127,8 +127,8 @@ class UserString:
def zfill(self, width): return self.__class__(self.data.zfill(width))
# the following methods are defined for unicode objects only:
- def iswide(self): return self.data.iswide()
- def width(self): return self.data.width()
+ def iswide(self): return self.data.iswide() # unicode only
+ def width(self): return self.data.width() # unicode only
class MutableString(UserString):
"""mutable string objects