Regarding `#install_printer`, can you explain more? The type "Key_value_types.key" is equal to string (in this particular case). However, this type is produced via module application, and so I cannot construct a printer that can print values of type "Key_value_types.key" before program execution (which seems to be required for #install_printer). Somehow I seem to want to tell ocamldebug that Key_value_types.key is in fact equal to string. Or alternatively coerce kra (using Obj.magic) to string type so that it can easily be printed by ocamldebug? On 23 February 2017 at 16:31, Ivan Gotovchits wrote: > Probably it is an abstract type, that is represented as string. In any > case you can use the `#install_printer` directive to enable printing any > type. The argument > is a function of type `t -> Format.formatter -> unit`, where `t` is a name > of your type. > > On Thu, Feb 23, 2017 at 11:24 AM, Tom Ridge com> wrote: > >> Dear All, >> >> I am debugging some code. For various reasons I have started to use >> ocamldebug rather than printf. >> >> I should say that ocamldebug is excellent. Really excellent. Especially >> the "backwards" stepping. >> >> However, sometimes I want to see the value of a particular variable. I >> can use the "p" (print) command as: >> >> (ocd) p kra >> kra: Key_value_types.key = >> >> The problem is that I know that kra is a string. But ocamldebug only >> shows . >> >> Admittedly the code is functorized. But I have a feeling I should be able >> to tweak something to get ocamldebug to print the value of kra. >> >> Any ideas? >> >> T >> > >