I'm using ocamldoc to generate the documentation of my program. My code is not particularly big yet, I just have one function, but when I open the HTML the function documentation doesn't appear in any of the files generated by ocamldoc.
I use ocamldoc -all-params arbol\ binario.ml
to generate the HTML
I read the documentation for ocamldoc and I used the flag -all-params
but it didn't work either. Also I created a simple non-recursive function but it's the same output.
(** @author Roldan Rivera Luis Ricardo
@author Foo*)
(**Este modulo contiene la implementacion de una arbol binario
de busqueda BST (acrónimo del inglés Binary Search Tree)
con sus funciones basicas.
{b funciones}
- {! Crear}
- {! Insertar}
- {! Buscar}
- {! Recorrer}*)
(** Tipo de dato llamado Tree, la notacion 'a (alfa) indica que es un
tipo de dato polimorfico, es decir que puede soportar
cualquier tipo de dato. *)
type 'a tree =
| Branch of 'a * 'a tree * 'a tree (** Un elemento * sub-arbol izquierdo * sub-arbol derecho *)
| Leaf (** El fin de una rama, significa que ya no hay mas sub-arboles, equivalente al Nil *)
(** Busca el dato deseado en el arbol
@param tree Arbol donde se va a realizar la busqueda
@param x El valor a buscar
@return None Si no se encuentra el dato en el arbol*)
let rec buscar tree x =
match tree with
| Leaf -> None
| Branch(k,left,right) ->
if k = x then Some x
else if x < k then buscar left x
else buscar right x