You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
generate-accessors: add char double-pointer accessor support
The next data structure to be moved out of the public API contains string
arrays. Extend the generator to create getter/setters for this type.
Signed-off-by: Daniel Wagner <[email protected]>
3. **`const` members** — only a getter is generated, no setter (applies regardless of any annotation).
301
-
4. **`//!accessors:readonly`** — same effect as `const`: getter only.
302
-
5. **`//!accessors:writeonly`** — setter only; getter is suppressed.
303
-
6. **`//!accessors:readwrite`** — both getter and setter; overrides a restrictive struct-level default.
304
-
7. **`//!accessors:none`** — member is completely ignored by the generator.
305
-
8. **Struct-level mode** — the qualifier on `generate-accessors` sets the default for every member in the struct; per-member annotations override the struct default.
306
-
9. **`--prefix`** — prepended to every function name (e.g. `--prefix nvme_` turns `ctrl_set_name` into `nvme_ctrl_set_name`).
307
-
10. **Line length** — generated code is automatically wrapped to stay within the 80-column limit required by `checkpatch.pl`.
299
+
2. **String arrays** (`char **`) — setters deep-copy NULL-terminated arrays (each element and the container).
4. **`const` members** — only a getter is generated, no setter (applies regardless of any annotation).
302
+
5. **`//!accessors:readonly`** — same effect as `const`: getter only.
303
+
6. **`//!accessors:writeonly`** — setter only; getter is suppressed.
304
+
7. **`//!accessors:readwrite`** — both getter and setter; overrides a restrictive struct-level default.
305
+
8. **`//!accessors:none`** — member is completely ignored by the generator.
306
+
9. **Struct-level mode** — the qualifier on `generate-accessors` sets the default for every member in the struct; per-member annotations override the struct default.
307
+
10. **`--prefix`** — prepended to every function name (e.g. `--prefix nvme_` turns `ctrl_set_name` into `nvme_ctrl_set_name`).
308
+
11. **Line length** — generated code is automatically wrapped to stay within the 80-column limit required by `checkpatch.pl`.
0 commit comments