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
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
nexedi
cython
Commits
205ea59d
Commit
205ea59d
authored
Aug 12, 2008
by
Robert Bradshaw
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Merge fixes, fix constant unicode, string literal indexing.
All test pass but bufaccess, tnumpy, and r_mang1.
parent
82acc1f8
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
3 deletions
+8
-3
Cython/Compiler/ExprNodes.py
Cython/Compiler/ExprNodes.py
+6
-0
Cython/Compiler/Lexicon.py
Cython/Compiler/Lexicon.py
+1
-1
Cython/Compiler/Main.py
Cython/Compiler/Main.py
+0
-1
Cython/Compiler/Parsing.py
Cython/Compiler/Parsing.py
+1
-1
No files found.
Cython/Compiler/ExprNodes.py
View file @
205ea59d
...
...
@@ -760,6 +760,9 @@ class UnicodeNode(PyConstNode):
# result, because we might be coercing to an extension type,
# in which case a type test node will be needed.
def
compile_time_value
(
self
,
env
):
return
self
.
value
class
IdentifierStringNode
(
ConstNode
):
# A Python string that behaves like an identifier, e.g. for
...
...
@@ -1370,6 +1373,9 @@ class IndexNode(ExprNode):
self
.
is_buffer_access
=
False
self
.
base
.
analyse_types
(
env
)
# Handle the case where base is a literal char* (and we expect a string, not an int)
if
isinstance
(
self
.
base
,
StringNode
):
self
.
base
=
self
.
base
.
coerce_to_pyobject
(
env
)
skip_child_analysis
=
False
buffer_access
=
False
...
...
Cython/Compiler/Lexicon.py
View file @
205ea59d
...
...
@@ -63,7 +63,7 @@ def make_lexicon():
three_oct
=
octdigit
+
octdigit
+
octdigit
two_hex
=
hexdigit
+
hexdigit
four_hex
=
two_hex
+
two_hex
escapeseq
=
Str
(
"
\
\
"
)
+
(
two_oct
|
three_oct
|
two_hex
|
escapeseq
=
Str
(
"
\
\
"
)
+
(
two_oct
|
three_oct
|
Str
(
'u'
)
+
four_hex
|
Str
(
'x'
)
+
two_hex
|
Str
(
'U'
)
+
four_hex
+
four_hex
|
AnyChar
)
...
...
Cython/Compiler/Main.py
View file @
205ea59d
...
...
@@ -632,7 +632,6 @@ def compile_multiple(sources, options):
if
source
not
in
processed
:
# Compiling multiple sources in one context doesn't quite
# work properly yet.
context
=
Context
(
options
.
include_path
)
# to be removed later
if
not
timestamps
or
context
.
c_file_out_of_date
(
source
):
if
verbose
:
sys
.
stderr
.
write
(
"Compiling %s
\
n
"
%
source
)
...
...
Cython/Compiler/Parsing.py
View file @
205ea59d
...
...
@@ -603,7 +603,7 @@ def p_string_literal(s):
else
:
c
=
systr
[
1
]
if
c
in
"01234567"
:
chars
.
append
(
chr
(
int
(
systr
[
1
:])))
chars
.
append
(
chr
(
int
(
systr
[
1
:]
,
8
)))
elif
c
in
"'
\
"
\
\
"
:
chars
.
append
(
c
)
elif
c
in
"abfnrtv"
:
...
...
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