Usable to have public functions, i.e. like VPublic, but do not showing
them in guestfish.
---
generator/actions.ml | 6 +++---
generator/c.ml | 2 +-
generator/types.ml | 2 ++
3 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/generator/actions.ml b/generator/actions.ml
index c0beaae..25f4bb5 100644
--- a/generator/actions.ml
+++ b/generator/actions.ml
@@ -12744,19 +12744,19 @@ let non_daemon_functions, daemon_functions =
let all_functions = non_daemon_functions @ daemon_functions
let is_external { visibility = v } = match v with
- | VPublic | VStateTest | VBindTest | VDebug -> true
+ | VPublic | VPublicNoFish | VStateTest | VBindTest | VDebug -> true
| VInternal -> false
let is_internal f = not (is_external f)
let is_documented { visibility = v } = match v with
- | VPublic | VStateTest -> true
+ | VPublic | VPublicNoFish | VStateTest -> true
| VBindTest | VDebug | VInternal -> false
let is_fish { visibility = v; style = (_, args, _) } =
(* Internal functions are not exported to guestfish. *)
match v with
- | VStateTest | VBindTest | VInternal -> false
+ | VPublicNoFish | VStateTest | VBindTest | VInternal -> false
| VPublic | VDebug ->
(* Functions that take Pointer parameters cannot be used in
* guestfish, since there is no way the user could safely
diff --git a/generator/c.ml b/generator/c.ml
index 1c28853..24c1605 100644
--- a/generator/c.ml
+++ b/generator/c.ml
@@ -45,7 +45,7 @@ let hash_matches h { name = name } =
type optarg_proto = Dots | VA | Argv
let is_public { visibility = v } = match v with
- | VPublic | VStateTest | VDebug -> true
+ | VPublic | VPublicNoFish | VStateTest | VDebug -> true
| VBindTest | VInternal -> false
let is_private f = not (is_public f)
diff --git a/generator/types.ml b/generator/types.ml
index 2be6bae..ad9fa63 100644
--- a/generator/types.ml
+++ b/generator/types.ml
@@ -322,6 +322,8 @@ and cmd = string list
type visibility =
| VPublic (* Part of the public API *)
+ | VPublicNoFish (* Like VPublic, but not exported in
+ guestfish *)
| VStateTest (* A function which tests the state
of the appliance *)
| VBindTest (* Only used for testing language bindings *)
--
1.9.3