Derive-C
Loading...
Searching...
No Matches
std.h File Reference
#include <derive-c/core/helpers.h>
#include <stdbool.h>
#include <stdint.h>
#include <stdlib.h>
Include dependency graph for std.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define DERIVE_STD_SIMPLE(t)

Macro Definition Documentation

◆ DERIVE_STD_SIMPLE

#define DERIVE_STD_SIMPLE ( t)
Value:
bool NS(t, eq)(t const* self_1, t const* self_2) { return *self_1 == *self_2; } \
t NS(t, clone)(t const* self) { return *self; } \
bool NS(t, gt)(t const* self_1, t const* self_2) { return *self_1 > *self_2; } \
bool NS(t, lt)(t const* self_1, t const* self_2) { return *self_1 < *self_2; }
#define NS(pre, post)
Definition helpers.h:6
static SELF clone(SELF const *self)
Definition template.h:195

Definition at line 7 of file std.h.

7#define DERIVE_STD_SIMPLE(t) \
8 bool NS(t, eq)(t const* self_1, t const* self_2) { return *self_1 == *self_2; } \
9 t NS(t, clone)(t const* self) { return *self; } \
10 bool NS(t, gt)(t const* self_1, t const* self_2) { return *self_1 > *self_2; } \
11 bool NS(t, lt)(t const* self_1, t const* self_2) { return *self_1 < *self_2; }