Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
8e69bdac
Commit
8e69bdac
authored
Jun 29, 2002
by
Barry Warsaw
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
__unicode__(): Patch # 541263 by Mikhail Zabaluev, implementation
modified by Barry.
parent
ae64f3ad
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
0 deletions
+6
-0
Lib/email/Header.py
Lib/email/Header.py
+6
-0
No files found.
Lib/email/Header.py
View file @
8e69bdac
...
...
@@ -142,6 +142,12 @@ class Header:
"""A synonym for self.encode()."""
return
self
.
encode
()
def
__unicode__
(
self
):
"""Helper for the built-in unicode function."""
# charset item is a Charset instance so we need to stringify it.
uchunks
=
[
unicode
(
s
,
str
(
charset
))
for
s
,
charset
in
self
.
_chunks
]
return
u''
.
join
(
uchunks
)
def
append
(
self
,
s
,
charset
=
None
):
"""Append string s with Charset charset to the MIME header.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment