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
27ee0f85
Commit
27ee0f85
authored
May 17, 2019
by
David Carlier
Committed by
Cheryl Sabella
May 17, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix couple of dead code paths (GH-7418)
parent
e7b1136e
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
0 additions
and
7 deletions
+0
-7
Objects/bytesobject.c
Objects/bytesobject.c
+0
-2
Objects/stringlib/fastsearch.h
Objects/stringlib/fastsearch.h
+0
-1
Python/ast.c
Python/ast.c
+0
-3
Python/compile.c
Python/compile.c
+0
-1
No files found.
Objects/bytesobject.c
View file @
27ee0f85
...
...
@@ -1617,12 +1617,10 @@ bytes_richcompare(PyBytesObject *a, PyBytesObject *b, int op)
case
Py_GE
:
/* a string is equal to itself */
Py_RETURN_TRUE
;
break
;
case
Py_NE
:
case
Py_LT
:
case
Py_GT
:
Py_RETURN_FALSE
;
break
;
default:
PyErr_BadArgument
();
return
NULL
;
...
...
Objects/stringlib/fastsearch.h
View file @
27ee0f85
...
...
@@ -192,7 +192,6 @@ FASTSEARCH(const STRINGLIB_CHAR* s, Py_ssize_t n,
}
return
count
;
}
return
-
1
;
}
mlast
=
m
-
1
;
...
...
Python/ast.c
View file @
27ee0f85
...
...
@@ -2971,7 +2971,6 @@ ast_for_expr(struct compiling *c, const node *n)
return
Compare
(
expression
,
ops
,
cmps
,
LINENO
(
n
),
n
->
n_col_offset
,
n
->
n_end_lineno
,
n
->
n_end_col_offset
,
c
->
c_arena
);
}
break
;
case
star_expr
:
return
ast_for_starred
(
c
,
n
);
...
...
@@ -3618,7 +3617,6 @@ alias_for_import_name(struct compiling *c, const node *n, int store)
return
NULL
;
return
a
;
}
break
;
case
dotted_name
:
if
(
NCH
(
n
)
==
1
)
{
node
*
name_node
=
CHILD
(
n
,
0
);
...
...
@@ -3669,7 +3667,6 @@ alias_for_import_name(struct compiling *c, const node *n, int store)
}
return
alias
(
str
,
NULL
,
c
->
c_arena
);
}
break
;
case
STAR
:
str
=
PyUnicode_InternFromString
(
"*"
);
if
(
!
str
)
...
...
Python/compile.c
View file @
27ee0f85
...
...
@@ -4868,7 +4868,6 @@ compiler_visit_expr1(struct compiler *c, expr_ty e)
return
compiler_error
(
c
,
"can't use starred expression here"
);
}
break
;
case
Name_kind
:
return
compiler_nameop
(
c
,
e
->
v
.
Name
.
id
,
e
->
v
.
Name
.
ctx
);
/* child nodes of List and Tuple will have expr_context set */
...
...
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