Make it possible to forward declare struct json_t

This allows e.g. to use json_t in a header file that doesn't include
jansson.h:

    struct json_t;
    typedef struct json_t json_t;

    json_t *foo(json_t *bar);
This commit is contained in:
Petri Lehtinen 2013-01-03 10:45:38 +02:00
parent 8ad98c9ad3
commit 02beb90db3

View File

@ -47,7 +47,7 @@ typedef enum {
JSON_NULL
} json_type;
typedef struct {
typedef struct json_t {
json_type type;
size_t refcount;
} json_t;