The entry-point function of automatic derivation of `Gen`'s.
Consider, you have a `data X (a : A) (b : B n) (c : C) where ...` and
you want a derived `Gen` for `X`.
Say, you want to have `a` and `c` parameters of `X` to be set by the caller and the `b` parameter to be generated.
For this your generator function should have a signature like `(a : A) -> (c : C) -> (n ** b : B n ** X a b c)`.
So, you need to define a function with this signature, say, named as `genX` and
to write `genX = deriveGen` as an implementation to make the body to be derived.
Say, you want `n` to be set by the caller and, as the same time, to be an implicit argument.
In this case, the signature of the main function to be derived,
becomes `{n : _} -> (a : A) -> (c : C) -> (b : B n ** X a b c)`.
But still, you can use this function `deriveGen` to derive a function with such signature.
Say, you want your generator to be parameterized with some external `Gen`'s.
Consider types `data Y where ...`, `data Z1 where ...` and `data Z2 (b : B n) where ...`.
For this, `auto`-parameters can be listed with `=>`-syntax in the signature.
For example, if you want to use `Gen Y` and `Gen`'s for `Z1` and `Z2` as external generators,
you can define your function in the following way:
```idris
genX : Gen Y => Gen Z1 => ({n : _} -> {b : B n} -> Gen (Z2 b)) => {n : _} -> (a : A) -> (c : C) -> Gen (b : B n ** X a b c)
genX = deriveGen
```
Consider also, that you may be asked for having the `Fuel` argument as the first argument in the signature
due to (maybe, temporary) unability of `Gen`'s to manage infinite processes of values generation.
So, the example from above will look like this:
```idris
genX : Fuel -> (Fuel -> Gen Y) => (Fuel -> Gen Z1) => (Fuel -> {n : _} -> {b : B n} -> Gen (Z2 b)) =>
{n : _} -> (a : A) -> (c : C) -> Gen (b : B n ** X a b c)
genX = deriveGen
```
Totality: total
Visibility: export