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
d23effc0
Commit
d23effc0
authored
Sep 11, 2016
by
Ethan Furman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
issue28083: add IntFlag constants
parent
deec4d0a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
1 deletion
+11
-1
Lib/socket.py
Lib/socket.py
+11
-1
No files found.
Lib/socket.py
View file @
d23effc0
...
...
@@ -50,7 +50,7 @@ import _socket
from
_socket
import
*
import
os
,
sys
,
io
,
selectors
from
enum
import
IntEnum
from
enum
import
IntEnum
,
IntFlag
try
:
import
errno
...
...
@@ -80,6 +80,16 @@ IntEnum._convert(
__name__
,
lambda
C
:
C
.
isupper
()
and
C
.
startswith
(
'SOCK_'
))
IntFlag
.
_convert
(
'MsgFlag'
,
__name__
,
lambda
C
:
C
.
isupper
()
and
C
.
startswith
(
'MSG_'
))
IntFlag
.
_convert
(
'AddressInfo'
,
__name__
,
lambda
C
:
C
.
isupper
()
and
C
.
startswith
(
'AI_'
))
_LOCALHOST
=
'127.0.0.1'
_LOCALHOST_V6
=
'::1'
...
...
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