32
32
#include <limits.h> /* for ULONG_MAX */
34
34
#include <apr.h> /* for apr_size_t, apr_int64_t, ... */
35
#include <apr_version.h>
35
36
#include <apr_errno.h> /* for apr_status_t */
36
37
#include <apr_pools.h> /* for apr_pool_t */
37
38
#include <apr_hash.h> /* for apr_hash_t */
68
/** Macro used to mark experimental functions.
72
#ifndef SVN_EXPERIMENTAL
73
# if !defined(SWIGPERL) && !defined(SWIGPYTHON) && !defined(SWIGRUBY)
74
# if defined(__has_attribute)
75
# if __has_attribute(__warning__)
76
# define SVN_EXPERIMENTAL __attribute__((warning("experimental function used")))
78
# define SVN_EXPERIMENTAL
80
# elif !defined(__llvm__) && defined(__GNUC__) \
81
&& (__GNUC__ >= 4 || (__GNUC__==3 && __GNUC_MINOR__>=1))
82
# define SVN_EXPERIMENTAL __attribute__((warning("experimental function used")))
83
# elif defined(_MSC_VER) && _MSC_VER >= 1300
84
# define SVN_EXPERIMENTAL __declspec(deprecated("experimental function used"))
86
# define SVN_EXPERIMENTAL
89
# define SVN_EXPERIMENTAL
93
/** Macro used to mark functions that require a final null sentinel argument.
97
#ifndef SVN_NEEDS_SENTINEL_NULL
98
# if defined(__has_attribute)
99
# if __has_attribute(__sentinel__)
100
# define SVN_NEEDS_SENTINEL_NULL __attribute__((sentinel))
102
# define SVN_NEEDS_SENTINEL_NULL
104
# elif defined(__GNUC__) && (__GNUC__ >= 4)
105
# define SVN_NEEDS_SENTINEL_NULL __attribute__((sentinel))
107
# define SVN_NEEDS_SENTINEL_NULL
67
112
/** Indicate whether the current platform supports unaligned data access.
69
114
* On the majority of machines running SVN (x86 / x64), unaligned access
153
/* Declaration of a unique type, never defined, for the SVN_VA_NULL macro.
155
* NOTE: Private. Not for direct use by third-party code.
157
struct svn__null_pointer_constant_stdarg_sentinel_t;
159
/** Null pointer constant used as a sentinel in variable argument lists.
161
* Use of this macro ensures that the argument is of the correct size when a
162
* pointer is expected. (The macro @c NULL is not defined as a pointer on
163
* all systems, and the arguments to variadic functions are not converted
164
* automatically to the expected type.)
168
#define SVN_VA_NULL ((struct svn__null_pointer_constant_stdarg_sentinel_t*)0)
169
/* See? (char*)NULL -- They have the same length, but the cast looks ugly. */
108
173
/** Subversion error object.
110
175
* Defined here, rather than in svn_error.h, to avoid a recursive @#include
186
251
* These functions enable the caller to dereference an APR hash table index
187
252
* without type casts or temporary variables.
189
* ### These are private, and may go away when APR implements them natively.
254
* These functions are provided by APR itself from version 1.5.
255
* Definitions are provided here for when using older versions of APR.
259
#if !APR_VERSION_AT_LEAST(1, 5, 0)
193
261
/** Return the key of the hash table entry indexed by @a hi. */
195
svn__apr_hash_index_key(const apr_hash_index_t *hi);
263
apr_hash_this_key(apr_hash_index_t *hi);
197
265
/** Return the key length of the hash table entry indexed by @a hi. */
199
svn__apr_hash_index_klen(const apr_hash_index_t *hi);
267
apr_hash_this_key_len(apr_hash_index_t *hi);
201
269
/** Return the value of the hash table entry indexed by @a hi. */
203
svn__apr_hash_index_val(const apr_hash_index_t *hi);
271
apr_hash_this_val(apr_hash_index_t *hi);