File: tags.h

package info (click to toggle)
cbor2 5.7.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 648 kB
  • sloc: ansic: 5,522; python: 3,884; makefile: 19; sh: 8
file content (16 lines) | stat: -rw-r--r-- 334 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#define PY_SSIZE_T_CLEAN
#include <Python.h>
#include <stdint.h>

typedef struct {
    PyObject_HEAD
    uint64_t tag;
    PyObject *value;
} CBORTagObject;

extern PyTypeObject CBORTagType;

PyObject * CBORTag_New(uint64_t);
int CBORTag_SetValue(PyObject *, PyObject *);

#define CBORTag_CheckExact(op) (Py_TYPE(op) == &CBORTagType)