PythonMonkey   v1.1.1 (dev)
Loading...
Searching...
No Matches
PromiseType.hh File Reference

Struct for representing Promises. More...

#include <jsapi.h>
#include <js/Promise.h>
#include <Python.h>
Include dependency graph for PromiseType.hh:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  PromiseType
 This struct represents the JS Promise type in Python using our custom pythonmonkey.promise type. More...
 

Functions

bool PythonAwaitable_Check (PyObject *obj)
 Check if the object can be used in Python await expression. PyAwaitable_Check hasn't been and has no plan to be added to the Python C API as of CPython 3.9.
 

Detailed Description

Struct for representing Promises.

Author
Tom Tang (xmade.nosp@m.r@di.nosp@m.strib.nosp@m.utiv.nosp@m.e.net.nosp@m.work) and Philippe Laporte (phili.nosp@m.ppe@.nosp@m.distr.nosp@m.ibut.nosp@m.ive.n.nosp@m.etwo.nosp@m.rk)
Date
2023-03-29

Function Documentation

◆ PythonAwaitable_Check()

bool PythonAwaitable_Check ( PyObject *  obj)

Check if the object can be used in Python await expression. PyAwaitable_Check hasn't been and has no plan to be added to the Python C API as of CPython 3.9.