Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cython
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
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Gwenaël Samain
cython
Commits
f3f43b5d
Commit
f3f43b5d
authored
Jun 01, 2015
by
Robert Bradshaw
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Simplify enum default value.
parent
89519ab5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
4 deletions
+1
-4
Cython/Compiler/PyrexTypes.py
Cython/Compiler/PyrexTypes.py
+1
-4
No files found.
Cython/Compiler/PyrexTypes.py
View file @
f3f43b5d
...
@@ -3587,6 +3587,7 @@ class CEnumType(CType):
...
@@ -3587,6 +3587,7 @@ class CEnumType(CType):
self
.
cname
=
cname
self
.
cname
=
cname
self
.
values
=
[]
self
.
values
=
[]
self
.
typedef_flag
=
typedef_flag
self
.
typedef_flag
=
typedef_flag
self
.
default_value
=
"(%s) 0"
%
self
.
empty_declaration_code
()
def
__str__
(
self
):
def
__str__
(
self
):
return
self
.
name
return
self
.
name
...
@@ -3617,10 +3618,6 @@ class CEnumType(CType):
...
@@ -3617,10 +3618,6 @@ class CEnumType(CType):
typecast
(
self
,
c_long_type
,
rhs
),
typecast
(
self
,
c_long_type
,
rhs
),
' %s'
%
code
.
error_goto_if
(
error_condition
or
self
.
error_condition
(
result_code
),
error_pos
))
' %s'
%
code
.
error_goto_if
(
error_condition
or
self
.
error_condition
(
result_code
),
error_pos
))
@
property
def
default_value
(
self
):
if
self
.
values
:
return
self
.
values
[
0
]
class
CTupleType
(
CType
):
class
CTupleType
(
CType
):
# components [PyrexType]
# components [PyrexType]
...
...
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