ObjFW  Diff

Differences From Artifact [f79cba2d8d]:

To Artifact [7fb013ccb5]:

  • File src/of_asprintf.h — part of check-in [b7097a67b6] at 2015-06-14 10:45:10 on branch trunk — Add OF_NONNULL / OF_NULLABLE and use that instead

    Using __nonnull directly doesn't work on systems using glibc, as glibc
    defines __nonnull as a parameterized define. While this does not fix the
    problem of Clang introducing __nonnull even though it conflicts with
    glibc, this at least means it's possible again to compile things with
    versions of Clang that don't support __nonnull on systems with glibc. (user: js, size: 1045) [annotate] [blame] [check-ins using]


26
27
28
29
30
31
32
33

34
35
36
37
38
39
40
#import "macros.h"

OF_ASSUME_NONNULL_BEGIN

#ifdef __cplusplus
extern "C" {
#endif
extern int of_asprintf(__nullable char **__nonnull, const __nonnull char*, ...);

extern int of_vasprintf(__nullable char **__nonnull, const __nonnull char*,
    va_list);
#ifdef __cplusplus
}
#endif

OF_ASSUME_NONNULL_END







|
>
|
|





26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#import "macros.h"

OF_ASSUME_NONNULL_BEGIN

#ifdef __cplusplus
extern "C" {
#endif
extern int of_asprintf(
    char *OF_NULLABLE *OF_NONNULL, const char *OF_NONNULL, ...);
extern int of_vasprintf(
    char *OF_NULLABLE *OF_NONNULL, const char *OF_NONNULL, va_list);
#ifdef __cplusplus
}
#endif

OF_ASSUME_NONNULL_END