-
Notifications
You must be signed in to change notification settings - Fork 38
Embedded struct not generated. #10
Copy link
Copy link
Closed
Description
An embedded struct within another struct does not get generated.
On the mongoose.h header, mg_request_info containing a mg_header struct:
// This structure contains information about the HTTP request.
struct mg_request_info {
const char *request_method; // "GET", "POST", etc
const char *uri; // URL-decoded URI
const char *http_version; // E.g. "1.0", "1.1"
const char *query_string; // URL part after '?', not including '?', or NULL
const char *remote_user; // Authenticated user, or NULL if no auth used
long remote_ip; // Client's IP address
int remote_port; // Client's port
int is_ssl; // 1 if SSL-ed, 0 if not
void *user_data; // User data pointer passed to mg_start()
int num_headers; // Number of HTTP headers
struct mg_header {
const char *name; // HTTP header name
const char *value; // HTTP header value
} http_headers[64]; // Maximum 64 headers
};What gets generated is:
struct mg_request_info
{
const(char)* request_method;
const(char)* uri;
const(char)* http_version;
const(char)* query_string;
const(char)* remote_user;
c_long remote_ip;
int remote_port;
int is_ssl;
void* user_data;
int num_headers;
mg_header[64] http_headers;
}mg_header is left undefined.
I would have expected a definition, at least outside of mg_request_info like:
struct mg_header {
const(char) *name;
const(char) *value;
}Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels