Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
Pyston
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
Boxiang Sun
Pyston
Commits
4dad82a0
Commit
4dad82a0
authored
Sep 04, 2015
by
Kevin Modzelewski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Last few fixes to make sqlalchemy_declarative work
parent
0227fde8
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
2 deletions
+5
-2
minibenchmarks/sqlalchemy_declarative.py
minibenchmarks/sqlalchemy_declarative.py
+1
-1
src/runtime/set.cpp
src/runtime/set.cpp
+3
-0
test/tests/set.py
test/tests/set.py
+1
-1
No files found.
minibenchmarks/sqlalchemy_declarative.py
View file @
4dad82a0
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
import
os
import
os
import
sys
import
sys
sys
.
path
.
append
(
os
.
path
.
join
(
os
.
path
.
dirname
(
__file__
),
"../test/
testsuite/
lib/sqlalchemy/lib"
))
sys
.
path
.
append
(
os
.
path
.
join
(
os
.
path
.
dirname
(
__file__
),
"../test/lib/sqlalchemy/lib"
))
from
sqlalchemy
import
Column
,
ForeignKey
,
Integer
,
String
from
sqlalchemy
import
Column
,
ForeignKey
,
Integer
,
String
from
sqlalchemy.ext.declarative
import
declarative_base
from
sqlalchemy.ext.declarative
import
declarative_base
...
...
src/runtime/set.cpp
View file @
4dad82a0
...
@@ -659,8 +659,11 @@ void setupSet() {
...
@@ -659,8 +659,11 @@ void setupSet() {
set_cls
->
giveAttr
(
"difference_update"
,
set_cls
->
giveAttr
(
"difference_update"
,
new
BoxedFunction
(
boxRTFunction
((
void
*
)
setDifferenceUpdate
,
UNKNOWN
,
1
,
0
,
true
,
false
)));
new
BoxedFunction
(
boxRTFunction
((
void
*
)
setDifferenceUpdate
,
UNKNOWN
,
1
,
0
,
true
,
false
)));
set_cls
->
giveAttr
(
"issubset"
,
new
BoxedFunction
(
boxRTFunction
((
void
*
)
setIssubset
,
UNKNOWN
,
2
)));
set_cls
->
giveAttr
(
"issubset"
,
new
BoxedFunction
(
boxRTFunction
((
void
*
)
setIssubset
,
UNKNOWN
,
2
)));
frozenset_cls
->
giveAttr
(
"issubset"
,
set_cls
->
getattr
(
internStringMortal
(
"issubset"
)));
set_cls
->
giveAttr
(
"issuperset"
,
new
BoxedFunction
(
boxRTFunction
((
void
*
)
setIssuperset
,
UNKNOWN
,
2
)));
set_cls
->
giveAttr
(
"issuperset"
,
new
BoxedFunction
(
boxRTFunction
((
void
*
)
setIssuperset
,
UNKNOWN
,
2
)));
frozenset_cls
->
giveAttr
(
"issuperset"
,
set_cls
->
getattr
(
internStringMortal
(
"issuperset"
)));
set_cls
->
giveAttr
(
"isdisjoint"
,
new
BoxedFunction
(
boxRTFunction
((
void
*
)
setIsdisjoint
,
UNKNOWN
,
2
)));
set_cls
->
giveAttr
(
"isdisjoint"
,
new
BoxedFunction
(
boxRTFunction
((
void
*
)
setIsdisjoint
,
UNKNOWN
,
2
)));
frozenset_cls
->
giveAttr
(
"isdisjoint"
,
set_cls
->
getattr
(
internStringMortal
(
"isdisjoint"
)));
set_cls
->
giveAttr
(
"copy"
,
new
BoxedFunction
(
boxRTFunction
((
void
*
)
setCopy
,
UNKNOWN
,
1
)));
set_cls
->
giveAttr
(
"copy"
,
new
BoxedFunction
(
boxRTFunction
((
void
*
)
setCopy
,
UNKNOWN
,
1
)));
set_cls
->
giveAttr
(
"pop"
,
new
BoxedFunction
(
boxRTFunction
((
void
*
)
setPop
,
UNKNOWN
,
1
)));
set_cls
->
giveAttr
(
"pop"
,
new
BoxedFunction
(
boxRTFunction
((
void
*
)
setPop
,
UNKNOWN
,
1
)));
...
...
test/tests/set.py
View file @
4dad82a0
...
@@ -128,7 +128,7 @@ for i in xrange(10):
...
@@ -128,7 +128,7 @@ for i in xrange(10):
for
s1
in
set
(
range
(
5
)),
frozenset
(
range
(
5
)):
for
s1
in
set
(
range
(
5
)),
frozenset
(
range
(
5
)):
for
s2
in
compare_to
:
for
s2
in
compare_to
:
print
type
(
s2
),
sorted
(
s2
),
s
.
issubset
(
s2
),
s
.
issuperset
(
s2
),
s
==
s2
,
s
!=
s2
,
sorted
(
s
.
difference
(
s2
)),
s
.
isdisjoint
(
s2
),
sorted
(
s1
.
union
(
s2
)),
sorted
(
s1
.
intersection
(
s2
))
print
type
(
s2
),
sorted
(
s2
),
s
1
.
issubset
(
s2
),
s1
.
issuperset
(
s2
),
s1
==
s2
,
s1
!=
s2
,
sorted
(
s1
.
difference
(
s2
)),
s1
.
isdisjoint
(
s2
),
sorted
(
s1
.
union
(
s2
)),
sorted
(
s1
.
intersection
(
s2
))
f
=
float
(
'nan'
)
f
=
float
(
'nan'
)
s
=
set
([
f
])
s
=
set
([
f
])
...
...
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