aboutsummaryrefslogtreecommitdiffstats
path: root/common.h
blob: 02af2a1861a560f2ab4e994dce38782566b51bcf (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
/* See LICENSE file for copyright and license details. */
#include "libenv.h"
#include <stdlib.h>


#define HAVE_HEAD 1
#define NO_HEAD 0

#define NAMES 1
#define VARIABLES 0

#define FILTER 1, 1
#define SELECT 0, 0


size_t libenv_vprocess_list__(void *, enum libenv_class, va_list, int have_head, int names, int filter, int all, int dealloc);

static inline size_t
libenv_vprocess_list_without_dealloc__(const char **variables, enum libenv_class classes_head, va_list classes_tail,
                                       int have_head, int names, int filter, int all)
{
	return libenv_vprocess_list__(variables, classes_head, classes_tail, have_head, names, filter, all, 0);
}

static inline size_t
libenv_vprocess_list_with_dealloc__(char **variables, enum libenv_class classes_head, va_list classes_tail,
                                    int have_head, int names, int filter, int all)
{
	return libenv_vprocess_list__(variables, classes_head, classes_tail, have_head, names, filter, all, 1);
}