let display di f = call_if di.di_log_channel (fun (_, oc) -> f oc); match di.di_display_line with | Classic -> f di.di_channel | Sophisticated ds -> sophisticated_display ds f