Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(259)

Unified Diff: mojo/public/python/c_core.pxd

Issue 1783623005: Add mojo/c/system/{time.h,wait.h}. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: mojo/public/python/c_core.pxd
diff --git a/mojo/public/python/c_core.pxd b/mojo/public/python/c_core.pxd
index e8430abd11df27154f61623eda4548eb10addeb2..619d75045c8944a147ca2b9c4e858cf914d8e71f 100644
--- a/mojo/public/python/c_core.pxd
+++ b/mojo/public/python/c_core.pxd
@@ -13,20 +13,6 @@ from cpython.buffer cimport PyObject_GetBuffer
from cpython.mem cimport PyMem_Malloc, PyMem_Free
from libc.stdint cimport int32_t, int64_t, uint32_t, uint64_t, uintptr_t
-cdef extern from "mojo/public/c/system/handle.h" nogil:
- ctypedef uint32_t MojoHandle
- const MojoHandle MOJO_HANDLE_INVALID
-
- ctypedef uint32_t MojoHandleSignals
- const MojoHandleSignals MOJO_HANDLE_SIGNAL_NONE
- const MojoHandleSignals MOJO_HANDLE_SIGNAL_READABLE
- const MojoHandleSignals MOJO_HANDLE_SIGNAL_WRITABLE
- const MojoHandleSignals MOJO_HANDLE_SIGNAL_PEER_CLOSED
-
- cdef struct MojoHandleSignalsState:
- MojoHandleSignals satisfied_signals
- MojoHandleSignals satisfiable_signals
-
cdef extern from "mojo/public/c/system/result.h" nogil:
ctypedef int32_t MojoResult
const MojoResult MOJO_RESULT_OK
@@ -48,15 +34,31 @@ cdef extern from "mojo/public/c/system/result.h" nogil:
const MojoResult MOJO_RESULT_BUSY
const MojoResult MOJO_RESULT_SHOULD_WAIT
-cdef extern from "mojo/public/c/system/types.h" nogil:
+cdef extern from "mojo/public/c/system/handle.h" nogil:
+ ctypedef uint32_t MojoHandle
+ const MojoHandle MOJO_HANDLE_INVALID
+
+ ctypedef uint32_t MojoHandleSignals
+ const MojoHandleSignals MOJO_HANDLE_SIGNAL_NONE
+ const MojoHandleSignals MOJO_HANDLE_SIGNAL_READABLE
+ const MojoHandleSignals MOJO_HANDLE_SIGNAL_WRITABLE
+ const MojoHandleSignals MOJO_HANDLE_SIGNAL_PEER_CLOSED
+
+ cdef struct MojoHandleSignalsState:
+ MojoHandleSignals satisfied_signals
+ MojoHandleSignals satisfiable_signals
+
+ MojoResult MojoClose(MojoHandle handle)
+
+cdef extern from "mojo/public/c/system/time.h" nogil:
ctypedef int64_t MojoTimeTicks
ctypedef uint64_t MojoDeadline
const MojoDeadline MOJO_DEADLINE_INDEFINITE
-cdef extern from "mojo/public/c/system/functions.h" nogil:
MojoTimeTicks MojoGetTimeTicksNow()
- MojoResult MojoClose(MojoHandle handle)
+
+cdef extern from "mojo/public/c/system/wait.h" nogil:
MojoResult MojoWait "MojoWait"(MojoHandle handle,
MojoHandleSignals signals,
MojoDeadline deadline,

Powered by Google App Engine
This is Rietveld 408576698