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
d4dd8baa
Commit
d4dd8baa
authored
Oct 17, 2008
by
Lisandro Dalcin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix test suite reducing the signal-to-noise ratio of GCC warnings
parent
b8fa1e46
Changes
46
Hide whitespace changes
Inline
Side-by-side
Showing
46 changed files
with
123 additions
and
39 deletions
+123
-39
tests/compile/arrayptrcompat.pyx
tests/compile/arrayptrcompat.pyx
+4
-2
tests/compile/arraytoptrarg.pyx
tests/compile/arraytoptrarg.pyx
+1
-0
tests/compile/ass2longlong.pyx
tests/compile/ass2longlong.pyx
+2
-0
tests/compile/behnel4.pyx
tests/compile/behnel4.pyx
+3
-1
tests/compile/belchenko1.pyx
tests/compile/belchenko1.pyx
+2
-0
tests/compile/builtinfuncs.pyx
tests/compile/builtinfuncs.pyx
+2
-0
tests/compile/cascmp.pyx
tests/compile/cascmp.pyx
+3
-1
tests/compile/cassign.pyx
tests/compile/cassign.pyx
+5
-4
tests/compile/casttoexttype.pyx
tests/compile/casttoexttype.pyx
+2
-0
tests/compile/cenum.pyx
tests/compile/cenum.pyx
+3
-2
tests/compile/cnumop.pyx
tests/compile/cnumop.pyx
+6
-4
tests/compile/coercearraytoptr.pyx
tests/compile/coercearraytoptr.pyx
+2
-0
tests/compile/coercetovoidptr.pyx
tests/compile/coercetovoidptr.pyx
+2
-1
tests/compile/complexbasetype.pyx
tests/compile/complexbasetype.pyx
+3
-1
tests/compile/cstructreturn.pyx
tests/compile/cstructreturn.pyx
+2
-0
tests/compile/cunsignedlong.pyx
tests/compile/cunsignedlong.pyx
+3
-1
tests/compile/declarations.pyx
tests/compile/declarations.pyx
+4
-1
tests/compile/delslice.pyx
tests/compile/delslice.pyx
+2
-0
tests/compile/doda1.pyx
tests/compile/doda1.pyx
+2
-0
tests/compile/emptytry.pyx
tests/compile/emptytry.pyx
+2
-0
tests/compile/enumintcompat.pyx
tests/compile/enumintcompat.pyx
+6
-4
tests/compile/eqcmp.pyx
tests/compile/eqcmp.pyx
+5
-4
tests/compile/ewing1.pyx
tests/compile/ewing1.pyx
+3
-1
tests/compile/ewing4.pyx
tests/compile/ewing4.pyx
+2
-0
tests/compile/ewing5.pyx
tests/compile/ewing5.pyx
+2
-0
tests/compile/ewing6.pyx
tests/compile/ewing6.pyx
+2
-0
tests/compile/excvalcheck.pyx
tests/compile/excvalcheck.pyx
+1
-0
tests/compile/excvaldecl.pyx
tests/compile/excvaldecl.pyx
+7
-0
tests/compile/excvalreturn.pyx
tests/compile/excvalreturn.pyx
+1
-0
tests/compile/extcmethcall.pyx
tests/compile/extcmethcall.pyx
+2
-0
tests/compile/extern.pyx
tests/compile/extern.pyx
+2
-0
tests/compile/forfromelse.pyx
tests/compile/forfromelse.pyx
+3
-1
tests/compile/gustafsson2.pyx
tests/compile/gustafsson2.pyx
+2
-1
tests/compile/huss2.pyx
tests/compile/huss2.pyx
+2
-0
tests/compile/ia_cdefblock.pyx
tests/compile/ia_cdefblock.pyx
+2
-0
tests/compile/index.pyx
tests/compile/index.pyx
+5
-3
tests/compile/ishimoto4.pyx
tests/compile/ishimoto4.pyx
+2
-0
tests/compile/jiba5.pyx
tests/compile/jiba5.pyx
+1
-1
tests/compile/jiba6.pyx
tests/compile/jiba6.pyx
+2
-0
tests/compile/johnson1.pyx
tests/compile/johnson1.pyx
+2
-0
tests/compile/khavkine1.pyx
tests/compile/khavkine1.pyx
+1
-0
tests/compile/kleckner1.pyx
tests/compile/kleckner1.pyx
+2
-0
tests/compile/magcmp.pyx
tests/compile/magcmp.pyx
+3
-3
tests/compile/nogil.pyx
tests/compile/nogil.pyx
+4
-1
tests/compile/none.pyx
tests/compile/none.pyx
+1
-0
tests/compile/typecast.pyx
tests/compile/typecast.pyx
+3
-2
No files found.
tests/compile/arrayptrcompat.pyx
View file @
d4dd8baa
...
...
@@ -5,8 +5,8 @@ cdef void f():
cdef
int
*
p
cdef
void
*
v
cdef
int
a
[
5
]
cdef
int
i
cdef
E
e
cdef
int
i
=
0
cdef
E
e
=
z
p
=
a
v
=
a
p
=
a
+
i
...
...
@@ -15,3 +15,5 @@ cdef void f():
p
=
e
+
a
p
=
a
-
i
p
=
a
-
e
f
()
tests/compile/arraytoptrarg.pyx
View file @
d4dd8baa
...
...
@@ -4,3 +4,4 @@ cdef void f1(char *argv[]):
cdef
void
f2
(
char
*
argv
[]):
pass
f1
(
NULL
)
tests/compile/ass2longlong.pyx
View file @
d4dd8baa
...
...
@@ -6,3 +6,5 @@ cdef void spam():
x
=
L
U
=
x
x
=
U
spam
()
tests/compile/behnel4.pyx
View file @
d4dd8baa
...
...
@@ -2,4 +2,6 @@ cdef enum E:
spam
,
eggs
cdef
E
f
()
except
spam
:
pass
return
eggs
f
()
tests/compile/belchenko1.pyx
View file @
d4dd8baa
...
...
@@ -3,3 +3,5 @@ cdef extern from *:
cdef
int
_is_aligned
(
void
*
ptr
):
return
((
<
intptr_t
>
ptr
)
&
((
sizeof
(
int
))
-
1
))
==
0
_is_aligned
(
NULL
)
tests/compile/builtinfuncs.pyx
View file @
d4dd8baa
...
...
@@ -21,3 +21,5 @@ cdef int f() except -1:
#i = typecheck(x, y)
#i = issubtype(x, y)
x
=
abs
f
()
tests/compile/cascmp.pyx
View file @
d4dd8baa
cdef
void
foo
():
cdef
int
bool
,
int1
,
int2
,
int3
,
int4
cdef
int
bool
,
int1
=
0
,
int2
=
0
,
int3
=
0
,
int4
=
0
cdef
object
obj1
,
obj2
,
obj3
,
obj4
obj1
=
1
obj2
=
2
...
...
@@ -11,3 +11,5 @@ cdef void foo():
bool
=
obj1
<
2
<
3
bool
=
obj1
<
2
<
3
<
4
bool
=
int1
<
(
int2
==
int3
)
<
int4
foo
()
tests/compile/cassign.pyx
View file @
d4dd8baa
cdef
void
foo
():
cdef
int
i1
,
i2
cdef
char
c1
,
c2
cdef
char
*
p1
,
*
p2
cdef
int
i1
,
i2
=
0
cdef
char
c1
=
0
,
c2
cdef
char
*
p1
,
*
p2
=
NULL
i1
=
i2
i1
=
c1
p1
=
p2
...
...
@@ -9,4 +9,5 @@ cdef void foo():
i1
=
obj1
p1
=
obj1
p1
=
"spanish inquisition"
\ No newline at end of file
foo
()
tests/compile/casttoexttype.pyx
View file @
d4dd8baa
...
...
@@ -7,3 +7,5 @@ cdef void foo(object x):
cdef
void
blarg
(
void
*
y
,
object
z
):
foo
(
<
Spam
>
y
)
foo
(
<
Spam
>
z
)
blarg
(
<
void
*>
None
,
None
)
tests/compile/cenum.pyx
View file @
d4dd8baa
...
...
@@ -5,9 +5,10 @@ cdef enum Spam:
g
=
42
cdef
void
eggs
():
cdef
Spam
s1
,
s2
cdef
Spam
s1
,
s2
=
a
cdef
int
i
s1
=
s2
s1
=
c
i
=
s1
\ No newline at end of file
eggs
()
tests/compile/cnumop.pyx
View file @
d4dd8baa
def
f
():
cdef
int
int1
,
int2
,
int3
cdef
char
char1
cdef
long
long1
,
long2
cdef
float
float1
,
float2
cdef
int
int1
,
int2
=
0
,
int3
=
1
cdef
char
char1
=
0
cdef
long
long1
,
long2
=
0
cdef
float
float1
,
float2
=
0
cdef
double
double1
int1
=
int2
*
int3
int1
=
int2
/
int3
long1
=
long2
*
char1
float1
=
int1
*
float2
double1
=
float1
*
int2
f
()
tests/compile/coercearraytoptr.pyx
View file @
d4dd8baa
...
...
@@ -8,3 +8,5 @@ cdef void eggs():
cdef
Grail
grail
spam
(
silly
)
spam
(
grail
.
silly
)
eggs
()
tests/compile/coercetovoidptr.pyx
View file @
d4dd8baa
cdef
void
f
():
cdef
void
*
p
cdef
char
*
q
cdef
char
*
q
=
NULL
p
=
q
f
()
tests/compile/complexbasetype.pyx
View file @
d4dd8baa
cdef
extern
(
int
*
[
42
])
spam
,
grail
,
swallow
cdef
(
int
(
*
)())
brian
():
pass
return
NULL
brian
()
tests/compile/cstructreturn.pyx
View file @
d4dd8baa
...
...
@@ -3,3 +3,5 @@ ctypedef struct Foo:
cdef
Foo
f
():
blarg
=
1
+
2
f
()
tests/compile/cunsignedlong.pyx
View file @
d4dd8baa
cdef
void
f
():
cdef
unsigned
long
x
cdef
object
y
cdef
object
y
=
0
x
=
y
y
=
x
f
()
tests/compile/declarations.pyx
View file @
d4dd8baa
...
...
@@ -12,9 +12,12 @@ cdef extern char *(*cpapfn())[5]
cdef
extern
int
fnargfn
(
int
())
cdef
void
f
():
cdef
void
*
p
cdef
void
*
p
=
NULL
global
ifnp
,
cpa
ifnp
=
<
int
(
*
)()
>
p
cdef
char
*
g
():
pass
f
()
g
()
tests/compile/delslice.pyx
View file @
d4dd8baa
cdef
void
spam
():
cdef
object
x
del
x
[
17
:
42
]
spam
()
tests/compile/doda1.pyx
View file @
d4dd8baa
...
...
@@ -9,3 +9,5 @@ cdef Spam foo():
cdef
object
blarg
():
pass
foo
()
tests/compile/emptytry.pyx
View file @
d4dd8baa
...
...
@@ -3,3 +3,5 @@ cdef void f():
pass
finally
:
pass
f
()
tests/compile/enumintcompat.pyx
View file @
d4dd8baa
...
...
@@ -5,10 +5,10 @@ cdef enum G:
b
cdef
void
f
():
cdef
E
e
cdef
G
g
cdef
int
i
,
j
cdef
float
f
,
h
cdef
E
e
=
a
cdef
G
g
=
b
cdef
int
i
,
j
=
0
cdef
float
f
,
h
=
0
i
=
j
|
e
i
=
e
|
j
i
=
j
^
e
...
...
@@ -23,3 +23,5 @@ cdef void f():
# f = j ** e # Cython prohibits this
i
=
e
+
g
f
=
h
f
()
tests/compile/eqcmp.pyx
View file @
d4dd8baa
cdef
void
foo
():
cdef
int
bool
,
int1
,
int2
cdef
float
float1
,
float2
cdef
char
*
ptr1
,
*
ptr2
cdef
int
bool
,
int1
=
0
,
int2
=
0
cdef
float
float1
=
0
,
float2
=
0
cdef
char
*
ptr1
=
NULL
,
*
ptr2
=
NULL
cdef
int
*
ptr3
bool
=
int1
==
int2
bool
=
int1
!=
int2
...
...
@@ -10,4 +10,5 @@ cdef void foo():
bool
=
int1
==
float2
bool
=
ptr1
is
ptr2
bool
=
ptr1
is
not
ptr2
\ No newline at end of file
foo
()
tests/compile/ewing1.pyx
View file @
d4dd8baa
...
...
@@ -2,7 +2,9 @@ cdef int blarg(int i):
pass
cdef
void
foo
():
cdef
float
f
cdef
float
f
=
0
cdef
int
i
if
blarg
(
<
int
>
f
):
pass
foo
()
tests/compile/ewing4.pyx
View file @
d4dd8baa
cdef
void
f
():
"This is a pseudo doc string."
f
()
tests/compile/ewing5.pyx
View file @
d4dd8baa
cdef
char
*
f
():
raise
Exception
f
()
tests/compile/ewing6.pyx
View file @
d4dd8baa
...
...
@@ -19,3 +19,5 @@ cdef class E:
cdef
void
f
(
D
d
,
E
e
):
d
.
m
(
e
)
f
(
D
(),
E
())
tests/compile/excvalcheck.pyx
View file @
d4dd8baa
...
...
@@ -9,3 +9,4 @@ cdef void eggs():
grail
()
p
=
tomato
()
eggs
()
tests/compile/excvaldecl.pyx
View file @
d4dd8baa
...
...
@@ -15,3 +15,10 @@ cdef int brian() except? 0:
cdef
int
silly
()
except
-
1
:
pass
spam
()
eggs
()
grail
()
tomato
()
brian
()
silly
()
tests/compile/excvalreturn.pyx
View file @
d4dd8baa
cdef
int
spam
()
except
-
1
:
eggs
=
42
spam
()
tests/compile/extcmethcall.pyx
View file @
d4dd8baa
...
...
@@ -16,3 +16,5 @@ cdef void tomato():
spam
=
superspam
spam
.
add_tons
(
42
)
superspam
.
add_tons
(
1764
)
tomato
()
tests/compile/extern.pyx
View file @
d4dd8baa
...
...
@@ -7,3 +7,5 @@ cdef extern int eggs():
cdef
int
grail
():
pass
grail
()
tests/compile/forfromelse.pyx
View file @
d4dd8baa
cdef
void
spam
():
cdef
int
i
,
j
,
k
cdef
int
i
,
j
=
0
,
k
=
0
for
i
from
0
<=
i
<
10
:
j
=
k
else
:
...
...
@@ -10,3 +10,5 @@ cdef void spam():
j
=
i
else
:
j
=
k
spam
()
tests/compile/gustafsson2.pyx
View file @
d4dd8baa
...
...
@@ -6,4 +6,5 @@ cdef somefunction(someenum_t val):
if
val
==
ENUMVALUE_1
:
pass
somefunction
(
ENUMVALUE_1
)
somefunction
(
ENUMVALUE_2
)
tests/compile/huss2.pyx
View file @
d4dd8baa
...
...
@@ -13,3 +13,5 @@ cdef void f():
e
=
white
i
=
e
i
=
e
+
1
f
()
tests/compile/ia_cdefblock.pyx
View file @
d4dd8baa
...
...
@@ -31,3 +31,5 @@ cdef public api:
void
pub_api_f
():
pass
priv_f
()
tests/compile/index.pyx
View file @
d4dd8baa
def
f
(
obj1
,
obj2
,
obj3
):
cdef
int
int1
,
int2
,
int3
cdef
float
flt1
,
*
ptr1
cdef
int
int1
,
int2
=
0
,
int3
=
0
cdef
float
flt1
,
*
ptr1
=
NULL
cdef
int
array1
[
42
]
array1
[
int2
]
=
0
int1
=
array1
[
int2
]
flt1
=
ptr1
[
int2
]
array1
[
int1
]
=
int2
...
...
@@ -13,4 +14,5 @@ def f(obj1, obj2, obj3):
array1
[
obj2
]
=
int3
obj1
[
int2
]
=
obj3
obj1
[
obj2
]
=
42
\ No newline at end of file
f
(
None
,
None
,
None
)
tests/compile/ishimoto4.pyx
View file @
d4dd8baa
cdef
void
__stdcall
f
():
pass
f
()
tests/compile/jiba5.pyx
View file @
d4dd8baa
def
f
():
cdef
int
i
cdef
int
i
=
0
global
mylist
del
mylist
[
i
]
return
tests/compile/jiba6.pyx
View file @
d4dd8baa
...
...
@@ -6,3 +6,5 @@ cdef void f():
cdef
float
*
f2
f2
=
f1
+
1
memcpy
(
f1
,
f2
,
1
)
f
()
tests/compile/johnson1.pyx
View file @
d4dd8baa
...
...
@@ -5,3 +5,5 @@ cdef void func():
cdef
foo
x
map
=
[
FOO
]
x
=
map
[
0
]
func
()
tests/compile/khavkine1.pyx
View file @
d4dd8baa
...
...
@@ -7,3 +7,4 @@ cdef void f(void *obj):
(
<
T
>
obj
).
a
[
0
]
=
1
b
=
None
f
(
NULL
)
tests/compile/kleckner1.pyx
View file @
d4dd8baa
...
...
@@ -3,3 +3,5 @@ def f(x,):
cdef
void
g
(
int
x
,):
pass
g
(
0
)
tests/compile/magcmp.pyx
View file @
d4dd8baa
cdef
void
foo
():
cdef
int
bool
,
int1
,
int2
cdef
int
bool
,
int1
=
0
,
int2
=
0
bool
=
int1
<
int2
bool
=
int1
>
int2
bool
=
int1
<=
int2
bool
=
int1
>=
int2
foo
()
tests/compile/nogil.pyx
View file @
d4dd8baa
...
...
@@ -10,9 +10,12 @@ cdef void f(int x) nogil:
y
=
42
cdef
void
h
(
object
x
)
nogil
:
cdef
void
*
p
cdef
void
*
p
=<
void
*>
None
g2
(
x
)
g2
(
<
object
>
p
)
p
=
<
void
*>
x
e1
()
e2
()
f
(
0
)
h
(
None
)
tests/compile/none.pyx
View file @
d4dd8baa
cdef
void
spam
():
eggs
=
None
spam
()
tests/compile/typecast.pyx
View file @
d4dd8baa
cdef
void
f
(
obj
):
cdef
int
i
cdef
int
i
=
0
cdef
char
*
p
p
=
<
char
*>
i
obj
=
<
object
>
p
p
=
<
char
*>
obj
\ No newline at end of file
f
(
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