X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=lib%2Flibrte_cmdline%2Fcmdline_parse_string.h;h=a903bf150feb85b155636d10e1d51cd2c248f178;hb=8206ad50557ae5fb61f5417f8ce4c6782395ce7d;hp=12c9b404808de9339e60bb1e1212f9d0335800dd;hpb=dada9ef6edc59015b6674b5a95258787c71401b0;p=dpdk.git diff --git a/lib/librte_cmdline/cmdline_parse_string.h b/lib/librte_cmdline/cmdline_parse_string.h index 12c9b40480..a903bf150f 100644 --- a/lib/librte_cmdline/cmdline_parse_string.h +++ b/lib/librte_cmdline/cmdline_parse_string.h @@ -91,18 +91,17 @@ int cmdline_complete_get_elt_string(cmdline_parse_token_hdr_t *tk, int idx, int cmdline_get_help_string(cmdline_parse_token_hdr_t *tk, char *dstbuf, unsigned int size); -/* - * Warning! Not compatible with C++! - */ #define TOKEN_STRING_INITIALIZER(structure, field, string) \ -{ \ - .hdr = { \ - .ops = &cmdline_token_string_ops, \ - .offset = offsetof(structure, field), \ - }, \ - .string_data = { \ - .str = string, \ - }, \ +{ \ + /* hdr */ \ + { \ + &cmdline_token_string_ops, /* ops */ \ + offsetof(structure, field), /* offset */ \ + }, \ + /* string_data */ \ + { \ + string, /* str */ \ + }, \ } #ifdef __cplusplus