package rope

  1. Overview
  2. Docs
Ropes (heavyweight strings)

Install

Dune Dependency

Authors

Maintainers

Sources

rope-0.6.2.tbz
sha256=514001a5f6a972205cc102924f1c863ad268ff74a31dd0e43b5deea081729b95
md5=b1bd36276f4556af2b208b70b92011d5

doc/src/rope.top/rope_top.ml.html

Source file rope_top.ml

1
2
3
4
5
6
7
8
9
10
11
12
13

let eval_string ?(print_outcome = false)
      ?(err_formatter = Format.err_formatter) str =
  let lexbuf = Lexing.from_string str in
  let phrase = !Toploop.parse_toplevel_phrase lexbuf in
  Toploop.execute_phrase print_outcome err_formatter phrase

let install_printer p =
  eval_string (Printf.sprintf "#install_printer %s;;" p)

let () =
  if not (install_printer "Rope.Rope_toploop.printer") then
    Format.eprintf "Problem installing Rope-printer@."
OCaml

Innovation. Community. Security.