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
cc56f17c
Commit
cc56f17c
authored
Aug 07, 2015
by
Robert Bradshaw
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add nullptr to libcpp declarations.
parent
2e32985e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
17 deletions
+18
-17
Cython/Includes/libcpp/__init__.pxd
Cython/Includes/libcpp/__init__.pxd
+2
-0
Cython/Includes/libcpp/memory.pxd
Cython/Includes/libcpp/memory.pxd
+16
-17
No files found.
Cython/Includes/libcpp/__init__.pxd
View file @
cc56f17c
cdef
extern
from
*
:
ctypedef
bint
bool
ctypedef
void
*
nullptr_t
nullptr_t
nullptr
Cython/Includes/libcpp/memory.pxd
View file @
cc56f17c
from
libcpp
cimport
bool
from
libcpp
cimport
bool
,
nullptr_t
,
nullptr
cdef
extern
from
"<memory>"
namespace
"std"
nogil
:
ctypedef
void
*
nullptr_t
;
# Should be decltype(nullptr)
cdef
cppclass
unique_ptr
[
T
]:
unique_ptr
()
unique_ptr
(
nullptr_t
)
unique_ptr
(
T
*
)
unique_ptr
(
unique_ptr
[
T
]
&
)
# Modifiers
T
*
release
()
void
reset
()
void
reset
(
nullptr_t
)
void
reset
(
T
*
)
void
swap
(
unique_ptr
&
)
# Observers
T
*
get
()
T
&
operator
*
()
#T* operator->() # Not Supported
#bool operator bool() # Not Supported
bool
operator
==
(
const
unique_ptr
&
)
bool
operator
!=
(
const
unique_ptr
&
)
bool
operator
<
(
const
unique_ptr
&
)
bool
operator
>
(
const
unique_ptr
&
)
bool
operator
<=
(
const
unique_ptr
&
)
bool
operator
>=
(
const
unique_ptr
&
)
bool
operator
==
(
nullptr_t
)
bool
operator
!=
(
nullptr_t
)
# Forward Declaration not working ("Compiler crash in AnalyseDeclarationsTransform")
#cdef cppclass weak_ptr[T]
cdef
cppclass
shared_ptr
[
T
]:
shared_ptr
()
shared_ptr
(
nullptr_t
)
...
...
@@ -43,12 +42,12 @@ cdef extern from "<memory>" namespace "std" nogil:
shared_ptr
(
shared_ptr
[
T
]
&
,
T
*
)
shared_ptr
(
unique_ptr
[
T
]
&
)
#shared_ptr(weak_ptr[T]&) # Not Supported
# Modifiers
void
reset
()
void
reset
(
T
*
)
void
swap
(
shared_ptr
&
)
# Observers
T
*
get
()
T
&
operator
*
()
...
...
@@ -58,26 +57,26 @@ cdef extern from "<memory>" namespace "std" nogil:
#bool operator bool() # Not Supported
#bool owner_before[Y](const weak_ptr[Y]&) # Not Supported
bool
owner_before
[
Y
](
const
shared_ptr
[
Y
]
&
)
bool
operator
==
(
const
shared_ptr
&
)
bool
operator
!=
(
const
shared_ptr
&
)
bool
operator
<
(
const
shared_ptr
&
)
bool
operator
>
(
const
shared_ptr
&
)
bool
operator
<=
(
const
shared_ptr
&
)
bool
operator
>=
(
const
shared_ptr
&
)
bool
operator
==
(
nullptr_t
)
bool
operator
!=
(
nullptr_t
)
cdef
cppclass
weak_ptr
[
T
]:
weak_ptr
()
weak_ptr
(
weak_ptr
[
T
]
&
)
weak_ptr
(
shared_ptr
[
T
]
&
)
# Modifiers
void
reset
()
void
swap
(
weak_ptr
&
)
# Observers
long
use_count
()
bool
expired
()
...
...
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