From a251c1622fde9fc4f073d7c5bd46b43335f28fd1 Mon Sep 17 00:00:00 2001 From: Hyeseong Kim Date: Sun, 18 May 2025 07:02:51 +0900 Subject: [PATCH] remove unused program --- compiler/cmij/cmjdump_main.ml | 75 ---------------------------------- compiler/cmij/cmjdump_main.mli | 23 ----------- compiler/cmij/dune | 12 ------ compiler/dune | 1 - 4 files changed, 111 deletions(-) delete mode 100644 compiler/cmij/cmjdump_main.ml delete mode 100644 compiler/cmij/cmjdump_main.mli delete mode 100644 compiler/cmij/dune diff --git a/compiler/cmij/cmjdump_main.ml b/compiler/cmij/cmjdump_main.ml deleted file mode 100644 index 9e7995e760..0000000000 --- a/compiler/cmij/cmjdump_main.ml +++ /dev/null @@ -1,75 +0,0 @@ -(* Copyright (C) 2017 Hongbo Zhang, Authors of ReScript - * - * 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, either version 3 of the License, or - * (at your option) any later version. - * - * In addition to the permissions granted to you by the LGPL, you may combine - * or link a "work that uses the Library" with a publicly distributed version - * of this file to produce a combined library or application, then distribute - * that combined work under the terms of your choosing, with no requirement - * to comply with the obligations normally placed on you by section 4 of the - * LGPL version 3 (or the corresponding section of a later version of the LGPL - * should you choose to use a later version). - * - * 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. *) - -(* start dumping *) - -let f fmt = Printf.fprintf stdout fmt - -let pp_cmj_case (case : Ext_js_file_kind.case) : unit = - f "%s\n" - ("case : " - ^ - match case with - | Little -> "little" - | Upper -> "upper") - -let pp_cmj - ({values; pure; package_spec = npm_package_path; case} : Js_cmj_format.t) = - f "package info: %s\n" - (Format.asprintf "%a" Js_packages_info.dump_packages_info npm_package_path); - pp_cmj_case case; - - f "effect: %s\n" (if pure then "pure" else "not pure"); - Ext_array.iter values (fun {name; arity; persistent_closed_lambda} -> - (match arity with - | Single arity -> ( - f "%s: %s\n" name (Format.asprintf "%a" Lam_arity.print arity); - match persistent_closed_lambda with - | None -> f "%s: not saved\n" name - | Some lam -> - f "%s: ======[start]\n" name; - f "%s\n" (Lam_print.lambda_to_string lam); - f "%s: ======[finish]\n" name) - | Submodule xs -> - (match persistent_closed_lambda with - | None -> f "%s: not saved\n" name - | Some lam -> - f "%s: ======[start]\n" name; - f "%s" (Lam_print.lambda_to_string lam); - f "%s: ======[finish]\n" name); - Array.iteri - (fun i arity -> - f "%s[%i] : %s \n" name i - (Format.asprintf "%a" Lam_arity.print arity)) - xs); - f "\n") - -let () = - match Sys.argv with - | [|_; file|] -> - let cmj, digest = Js_cmj_format.from_file_with_digest file in - Format.fprintf Format.std_formatter "@[Digest: %s@]@." - (Digest.to_hex digest); - pp_cmj cmj - | _ -> failwith "expect one argument" diff --git a/compiler/cmij/cmjdump_main.mli b/compiler/cmij/cmjdump_main.mli deleted file mode 100644 index 3999ce7f69..0000000000 --- a/compiler/cmij/cmjdump_main.mli +++ /dev/null @@ -1,23 +0,0 @@ -(* Copyright (C) 2015-2016 Bloomberg Finance L.P. - * - * 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, either version 3 of the License, or - * (at your option) any later version. - * - * In addition to the permissions granted to you by the LGPL, you may combine - * or link a "work that uses the Library" with a publicly distributed version - * of this file to produce a combined library or application, then distribute - * that combined work under the terms of your choosing, with no requirement - * to comply with the obligations normally placed on you by section 4 of the - * LGPL version 3 (or the corresponding section of a later version of the LGPL - * should you choose to use a later version). - * - * 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. *) diff --git a/compiler/cmij/dune b/compiler/cmij/dune deleted file mode 100644 index baac16f9e3..0000000000 --- a/compiler/cmij/dune +++ /dev/null @@ -1,12 +0,0 @@ -(env - (static - (flags - (:standard -ccopt -static)))) - -(executables - (names cmjdump_main) - (public_names cmjdump) - (package rescript) - (flags - (:standard -w +a-4-9-40-42-69)) - (libraries core)) diff --git a/compiler/dune b/compiler/dune index 6eb9778dac..2edab16a9e 100644 --- a/compiler/dune +++ b/compiler/dune @@ -4,7 +4,6 @@ bsb_helper bsb_helper_exe bsc - cmij common core depends