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
Boxiang Sun
cython
Commits
160151b3
Commit
160151b3
authored
Nov 26, 2016
by
Robert Bradshaw
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixes bug with enum attribute resolution.
Closes github issue #1533.
parent
ea1939d4
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
1 deletion
+5
-1
Cython/Compiler/ExprNodes.py
Cython/Compiler/ExprNodes.py
+5
-1
No files found.
Cython/Compiler/ExprNodes.py
View file @
160151b3
...
@@ -6396,7 +6396,11 @@ class AttributeNode(ExprNode):
...
@@ -6396,7 +6396,11 @@ class AttributeNode(ExprNode):
return
self
.
as_name_node
(
env
,
ubcm_entry
,
target
=
False
)
return
self
.
as_name_node
(
env
,
ubcm_entry
,
target
=
False
)
elif
type
.
is_enum
:
elif
type
.
is_enum
:
if
self
.
attribute
in
type
.
values
:
if
self
.
attribute
in
type
.
values
:
return
self
.
as_name_node
(
env
,
env
.
lookup
(
self
.
attribute
),
target
=
False
)
for
entry
in
type
.
entry
.
enum_values
:
if
entry
.
name
==
self
.
attribute
:
return
self
.
as_name_node
(
env
,
entry
,
target
=
False
)
else
:
error
(
self
.
pos
,
"%s not a known value of %s"
%
(
self
.
attribute
,
type
))
else
:
else
:
error
(
self
.
pos
,
"%s not a known value of %s"
%
(
self
.
attribute
,
type
))
error
(
self
.
pos
,
"%s not a known value of %s"
%
(
self
.
attribute
,
type
))
return
None
return
None
...
...
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