From 9e9cf45e75e9554d6ad9a6c70d729d53ffa8313e Mon Sep 17 00:00:00 2001 From: Anton Bachin Date: Fri, 22 Dec 2017 16:49:58 -0600 Subject: [PATCH] Delete lwt.simple-top Resolves #371. The changes to discover.ml done in #313 are left in place, because I am not sure if we still want to pass the -custom flag. --- META.lwt | 20 ------------- doc/CONTRIBUTING.md | 3 -- doc/Makefile | 2 -- doc/manual.wiki | 12 +------- src/simple_top/jbuild | 9 ------ src/simple_top/lwt_simple_top.ml | 49 -------------------------------- src/util/install_filter.ml | 1 - 7 files changed, 1 insertion(+), 95 deletions(-) delete mode 100644 src/simple_top/jbuild delete mode 100644 src/simple_top/lwt_simple_top.ml diff --git a/META.lwt b/META.lwt index ffd13ae44f..97e1c7bb1e 100644 --- a/META.lwt +++ b/META.lwt @@ -56,26 +56,6 @@ package "preemptive" ( requires = "lwt.unix" ) -package "simple-top" ( - #directory = "simple-top" - version = "dev" - description = "Lwt-OCaml top level integration (deprecated; use utop)" - requires = "bigarray - bytes - compiler-libs - compiler-libs.common - lwt - lwt.log - lwt.unix - result - unix" - archive(byte) = "lwt_simple_top.cma" - archive(native) = "lwt_simple_top.cmxa" - plugin(byte) = "lwt_simple_top.cma" - plugin(native) = "lwt_simple_top.cmxs" - exists_if = "lwt_simple_top.cma" -) - package "syntax" ( #directory = "syntax" version = "dev" diff --git a/doc/CONTRIBUTING.md b/doc/CONTRIBUTING.md index 7c7467a54c..44bb08153e 100644 --- a/doc/CONTRIBUTING.md +++ b/doc/CONTRIBUTING.md @@ -298,7 +298,4 @@ This list surveys them, roughly in order of importance. - *deprecated* `src/camlp4/` contains the Camlp4 syntax extension, which is deprecated in favor of the PPX (in `src/ppx`). -- *deprecated* `src/simple_top/` contains the Lwt top-level, which is deprecated - in favor of [utop][utop]. - [utop]: https://github.com/diml/utop diff --git a/doc/Makefile b/doc/Makefile index 00e04202d2..2e0308386f 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -15,7 +15,6 @@ INCS=\ -I ${BLD}/ppx \ -I ${BLD}/preemptive \ -I ${BLD}/react \ - -I ${BLD}/simple_top \ -I ${BLD}/ssl \ -I ${BLD}/unix @@ -27,7 +26,6 @@ MLIS=\ $(wildcard ${SRC}/ppx/*.mli) \ $(wildcard ${SRC}/preemptive/*.mli) \ $(wildcard ${SRC}/react/*.mli) \ - $(wildcard ${SRC}/simple_top/*.mli) \ $(wildcard ${SRC}/ssl/*.mli) \ $(filter-out ${BLD}/unix/lwt_unix.cppo.mli,$(wildcard ${BLD}/unix/*.mli)) diff --git a/doc/manual.wiki b/doc/manual.wiki index 921d2329a9..13d6664111 100644 --- a/doc/manual.wiki +++ b/doc/manual.wiki @@ -48,17 +48,7 @@ == The Lwt core library == In this section we describe the basics of {{{Lwt}}}. It is advised to - start an ocaml toplevel and try the given code examples. To start, - launch {{{ocaml}}} in a terminal or in emacs with the tuareg - mode, and type: - -{{{ -# #use "topfind";; -# #require "lwt.simple-top";; -}}} - - {{{lwt.simple-top}}} makes sure {{{Lwt}}} threads can run while - using the toplevel. You do not need it if you are using {{{utop}}}. + start {{{utop}}} and try the given code examples. === Lwt concepts === diff --git a/src/simple_top/jbuild b/src/simple_top/jbuild deleted file mode 100644 index f54fa846d2..0000000000 --- a/src/simple_top/jbuild +++ /dev/null @@ -1,9 +0,0 @@ -(jbuild_version 1) - -(library - ((name lwt_simple_top) - (public_name lwt.simple-top) - (synopsis "Lwt-OCaml top level integration (deprecated; use utop)") - (optional) - (wrapped false) - (libraries (lwt lwt.unix compiler-libs.common)))) diff --git a/src/simple_top/lwt_simple_top.ml b/src/simple_top/lwt_simple_top.ml deleted file mode 100644 index 5f4f56663f..0000000000 --- a/src/simple_top/lwt_simple_top.ml +++ /dev/null @@ -1,49 +0,0 @@ -(* OCaml promise library - * http://www.ocsigen.org/lwt - * Copyright (C) 2009 Jérémie Dimino - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation, with linking exceptions; - * either version 2.1 of the License, or (at your option) any later - * version. See COPYING file for details. - * - * This program is distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA - * 02111-1307, USA. - *) - -(* Integration with the toplevel for people who do not use the - enhanced toplevel (the utop project). This module is deprecated. *) - -[@@@ocaml.deprecated -" Use utop. See - https://github.com/diml/utop"] - -open Lwt.Infix - -let read_input_non_interactive prompt buffer len = - let rec loop i = - if i = len then - Lwt.return (i, false) - else - Lwt_io.read_char_opt Lwt_io.stdin >>= function - | Some c -> - Bytes.set buffer i c; - if c = '\n' then - Lwt.return (i + 1, false) - else - loop (i + 1) - | None -> - Lwt.return (i, true) - in - Lwt_main.run (Lwt_io.write Lwt_io.stdout prompt >>= fun () -> loop 0) - -let () = - Toploop.read_interactive_input := read_input_non_interactive diff --git a/src/util/install_filter.ml b/src/util/install_filter.ml index 9acf8d0227..0aa69251ef 100644 --- a/src/util/install_filter.ml +++ b/src/util/install_filter.ml @@ -34,7 +34,6 @@ let sub_paths = [ "log"; "options"; "syntax"; - "simple-top"; "ppx"; ]