generator: Add 'added' (version when added) field.

This commit is contained in:
Richard W.M. Jones
2015-05-26 09:10:16 +01:00
parent 41cf78f36b
commit d0d492def2
2 changed files with 6 additions and 1 deletions

View File

@@ -24,7 +24,9 @@ open Utils
(* Default settings for all action fields. So we copy and override
* this struct by writing '{ defaults with name = &c }'
*)
let defaults = { name = ""; style = RErr, [], []; proc_nr = None;
let defaults = { name = "";
added = (-1,-1,-1);
style = RErr, [], []; proc_nr = None;
tests = []; test_excuse = "";
shortdesc = ""; longdesc = "";
protocol_limit_warning = false; fish_alias = [];

View File

@@ -330,9 +330,12 @@ type visibility =
| VDebug (* Exported everywhere, but not documented *)
| VInternal (* Not exported *)
type version = int * int * int
(* Type of an action as declared in Actions module. *)
type action = {
name : string; (* name, not including "guestfs_" *)
added : version; (* which version was the API first added *)
style : style; (* args and return value *)
proc_nr : int option; (* proc number, None for non-daemon *)
tests : c_api_tests; (* C API tests *)