mirror of
https://github.com/python/cpython.git
synced 2025-08-30 13:38:43 +00:00
Whitespace cleanup; now passes the regression test (the last checkin made
it fail on a TabError (inconsistent tab/space usage)). Removed a comment about including a test since there is a regression test for this module.
This commit is contained in:
parent
103d5268c2
commit
ff5364ac9d
1 changed files with 15 additions and 21 deletions
|
@ -309,7 +309,7 @@ _Translator = {
|
|||
}
|
||||
|
||||
def _quote(str, LegalChars=_LegalChars,
|
||||
join=string.join, idmap=string._idmap, translate=string.translate):
|
||||
join=string.join, idmap=string._idmap, translate=string.translate):
|
||||
#
|
||||
# If the string does not need to be double-quoted,
|
||||
# then just return the string. Otherwise, surround
|
||||
|
@ -317,9 +317,9 @@ def _quote(str, LegalChars=_LegalChars,
|
|||
# special characters.
|
||||
#
|
||||
if "" == translate(str, idmap, LegalChars):
|
||||
return str
|
||||
return str
|
||||
else:
|
||||
return '"' + join( map(_Translator.get, str, str), "" ) + '"'
|
||||
return '"' + join( map(_Translator.get, str, str), "" ) + '"'
|
||||
# end _quote
|
||||
|
||||
|
||||
|
@ -440,7 +440,7 @@ class Morsel(UserDict):
|
|||
# end __setitem__
|
||||
|
||||
def isReservedKey(self, K):
|
||||
return string.lower(K) in self._reserved_keys
|
||||
return string.lower(K) in self._reserved_keys
|
||||
# end isReservedKey
|
||||
|
||||
def set(self, key, val, coded_val,
|
||||
|
@ -645,8 +645,6 @@ class BaseCookie(UserDict):
|
|||
rval, cval = self.value_decode(V)
|
||||
self.__set(K, rval, cval)
|
||||
M = self[K]
|
||||
|
||||
return
|
||||
# end __ParseString
|
||||
# end BaseCookie class
|
||||
|
||||
|
@ -723,10 +721,6 @@ Cookie = SmartCookie
|
|||
|
||||
|
||||
|
||||
#
|
||||
# should add a test routine?
|
||||
#
|
||||
|
||||
#Local Variables:
|
||||
#tab-width: 4
|
||||
#end:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue