From 041ecc5b43613a08cb6f44184fab861f3e51a8f4 Mon Sep 17 00:00:00 2001 From: Jules Villard Date: Mon, 11 May 2020 04:37:28 -0700 Subject: [PATCH] rename most libraries to be more consistent Summary: - Capitalise names - Remove Infer prefixes ``` git ls-files | grep /dune | xargs sed -i -e 's/absint/Absint/g' -e 's/InferIR/IR/g' -e 's/InferStdlib/IStdlib/g' -e 's/InferGenerated/ATDGenerated/g' -e 's/InferBase/IBase/g' -e 's/biabduction/Biabduction/g' -e 's/nullsafe/Nullsafe/g' -e 's/\bbo\b/BO/g' -e 's/\bBo\b/BO/g' -e 's/checkers/Checkers/g' -e 's/costlib/Costlib/g' -e 's/quandary/Quandary/g' -e 's/concurrency/Concurrency/g' -e 's/pulse/Pulse/g' -e 's/labs/Labs/g' -e 's/\bjava\b/JavaFrontend/g' -e 's/\bJava\b/JavaFrontend/' -e 's/JavaStubs/JavaFrontendStubs/' -e 's/integration/Integration/g' -e 's/InferCStubs/CStubs/g' ``` Reviewed By: ngorogiannis Differential Revision: D21440820 fbshipit-source-id: 1c5d10dd4 --- infer/src/IR/dune | 10 ++++---- infer/src/absint/dune | 10 ++++---- infer/src/al/dune.in | 6 ++--- infer/src/atd/dune | 4 ++-- infer/src/backend/dune | 12 +++++----- infer/src/base/dune | 10 ++++---- infer/src/biabduction/dune | 10 ++++---- infer/src/bufferoverrun/dune | 10 ++++---- infer/src/c_stubs/dune | 4 ++-- infer/src/checkers/dune | 10 ++++---- infer/src/clang/dune.in | 6 ++--- infer/src/concurrency/dune | 10 ++++---- infer/src/cost/dune | 10 ++++---- infer/src/deadcode/dune.in | 2 +- infer/src/dune.in | 40 ++++++++++++++++---------------- infer/src/integration/dune.in | 12 +++++----- infer/src/istd/dune | 4 ++-- infer/src/java/dune.in | 6 ++--- infer/src/labs/dune | 10 ++++---- infer/src/nullsafe/dune | 10 ++++---- infer/src/pulse/dune | 10 ++++---- infer/src/quandary/dune | 10 ++++---- infer/src/test_determinator/dune | 6 ++--- infer/src/topl/dune | 6 ++--- scripts/toplevel_init | 28 ++++++++++++++++++---- 25 files changed, 137 insertions(+), 119 deletions(-) diff --git a/infer/src/IR/dune b/infer/src/IR/dune index eee350067..46b08519c 100644 --- a/infer/src/IR/dune +++ b/infer/src/IR/dune @@ -4,11 +4,11 @@ ; LICENSE file in the root directory of this source tree. (library - (name InferIR) - (public_name infer.InferIR) + (name IR) + (public_name infer.IR) (flags - (:standard -open Core -open InferStdlib -open IStd -open InferGenerated - -open InferBase)) - (libraries core zarith InferStdlib InferGenerated InferBase) + (:standard -open Core -open IStdlib -open IStd -open ATDGenerated + -open IBase)) + (libraries core zarith IStdlib ATDGenerated IBase) (preprocess (pps ppx_compare))) diff --git a/infer/src/absint/dune b/infer/src/absint/dune index cb81fae1e..a2a3be6ca 100644 --- a/infer/src/absint/dune +++ b/infer/src/absint/dune @@ -4,11 +4,11 @@ ; LICENSE file in the root directory of this source tree. (library - (name absint) - (public_name infer.absint) + (name Absint) + (public_name infer.Absint) (flags - (:standard -open Core -open InferIR -open InferStdlib -open IStd -open InferGenerated - -open InferBase)) - (libraries core InferStdlib InferGenerated InferBase InferIR) + (:standard -open Core -open IR -open IStdlib -open IStd -open ATDGenerated + -open IBase)) + (libraries core IStdlib ATDGenerated IBase IR) (preprocess (pps ppx_compare)) ) diff --git a/infer/src/al/dune.in b/infer/src/al/dune.in index 1b4d275da..296a11340 100644 --- a/infer/src/al/dune.in +++ b/infer/src/al/dune.in @@ -19,9 +19,9 @@ let al = (modules %s) (flags (:standard - -open Core -open InferStdlib -open IStd -open OpenSource -open InferGenerated - -open InferBase -open InferIR -open Absint -open ClangFrontend)) - (libraries core InferStdlib InferGenerated InferBase InferIR absint ClangFrontend) + -open Core -open IStdlib -open IStd -open OpenSource -open ATDGenerated + -open IBase -open IR -open Absint -open ClangFrontend)) + (libraries core IStdlib ATDGenerated IBase IR Absint ClangFrontend) (preprocess (pps ppx_compare)) )|} (if clang then ":standard" else "") diff --git a/infer/src/atd/dune b/infer/src/atd/dune index 85b4344f4..4118976d0 100644 --- a/infer/src/atd/dune +++ b/infer/src/atd/dune @@ -4,8 +4,8 @@ ; LICENSE file in the root directory of this source tree. (library - (name InferGenerated) - (public_name infer.InferGenerated) + (name ATDGenerated) + (public_name infer.ATDGenerated) (flags (:standard -w -27-32-34-35-39)) (libraries atdgen core) diff --git a/infer/src/backend/dune b/infer/src/backend/dune index c98d1191c..c228ee9fd 100644 --- a/infer/src/backend/dune +++ b/infer/src/backend/dune @@ -4,15 +4,15 @@ ; LICENSE file in the root directory of this source tree. (library - (name backend) - (public_name infer.backend) + (name Backend) + (public_name infer.Backend) (flags (:standard - -open Core -open InferStdlib -open IStd -open OpenSource -open InferGenerated - -open InferBase -open InferIR -open Absint -open Biabduction -open Bo -open Nullsafe + -open Core -open IStdlib -open IStd -open OpenSource -open ATDGenerated + -open IBase -open IR -open Absint -open Biabduction -open BO -open Nullsafe -open Pulselib -open Checkers -open Costlib -open Quandary -open TOPLlib -open Concurrency -open Labs)) - (libraries core InferStdlib InferGenerated InferBase InferIR absint biabduction nullsafe bo - checkers costlib quandary TOPLlib concurrency labs) + (libraries core IStdlib ATDGenerated IBase IR Absint Biabduction Nullsafe BO + Checkers Costlib Quandary TOPLlib Concurrency Labs) (preprocess (pps ppx_compare ppx_fields_conv)) ) diff --git a/infer/src/base/dune b/infer/src/base/dune index 4906b1231..e7c11783e 100644 --- a/infer/src/base/dune +++ b/infer/src/base/dune @@ -4,10 +4,10 @@ ; LICENSE file in the root directory of this source tree. (library - (name InferBase) - (public_name infer.InferBase) - (flags (:standard -open Core -open InferStdlib -open IStd -open InferGenerated -open OpenSource)) - (libraries cmdliner core mtime.clock.os parmap re sqlite3 zip InferGenerated - InferStdlib OpenSource) + (name IBase) + (public_name infer.IBase) + (flags (:standard -open Core -open IStdlib -open IStd -open ATDGenerated -open OpenSource)) + (libraries cmdliner core mtime.clock.os parmap re sqlite3 zip ATDGenerated + IStdlib OpenSource) (preprocess (pps ppx_compare ppx_enumerate))) diff --git a/infer/src/biabduction/dune b/infer/src/biabduction/dune index 39d4e7134..7c16af121 100644 --- a/infer/src/biabduction/dune +++ b/infer/src/biabduction/dune @@ -4,11 +4,11 @@ ; LICENSE file in the root directory of this source tree. (library - (name biabduction) - (public_name infer.biabduction) + (name Biabduction) + (public_name infer.Biabduction) (flags - (:standard -open Core -open InferIR -open InferStdlib -open IStd -open InferGenerated - -open InferBase -open Absint)) - (libraries core InferStdlib InferGenerated InferBase InferIR absint) + (:standard -open Core -open IR -open IStdlib -open IStd -open ATDGenerated + -open IBase -open Absint)) + (libraries core IStdlib ATDGenerated IBase IR Absint) (preprocess (pps ppx_compare)) ) diff --git a/infer/src/bufferoverrun/dune b/infer/src/bufferoverrun/dune index c383edbb7..7da596b13 100644 --- a/infer/src/bufferoverrun/dune +++ b/infer/src/bufferoverrun/dune @@ -4,11 +4,11 @@ ; LICENSE file in the root directory of this source tree. (library - (name bo) - (public_name infer.bo) + (name BO) + (public_name infer.BO) (flags - (:standard -open Core -open OpenSource -open InferIR -open InferStdlib -open IStd -open InferGenerated - -open InferBase -open Absint -open Biabduction)) - (libraries base64 core InferStdlib InferGenerated InferBase InferIR absint biabduction) + (:standard -open Core -open OpenSource -open IR -open IStdlib -open IStd -open ATDGenerated + -open IBase -open Absint -open Biabduction)) + (libraries base64 core IStdlib ATDGenerated IBase IR Absint Biabduction) (preprocess (pps ppx_compare)) ) diff --git a/infer/src/c_stubs/dune b/infer/src/c_stubs/dune index 7e14f1af7..0b3a2b709 100644 --- a/infer/src/c_stubs/dune +++ b/infer/src/c_stubs/dune @@ -4,8 +4,8 @@ ; LICENSE file in the root directory of this source tree. (library - (name InferCStubs) - (public_name infer.InferCStubs) + (name CStubs) + (public_name infer.CStubs) (foreign_stubs (language c) (names fnv64_hash))) diff --git a/infer/src/checkers/dune b/infer/src/checkers/dune index 2cc5ddf64..e45b34f1d 100644 --- a/infer/src/checkers/dune +++ b/infer/src/checkers/dune @@ -4,11 +4,11 @@ ; LICENSE file in the root directory of this source tree. (library - (name checkers) - (public_name infer.checkers) + (name Checkers) + (public_name infer.Checkers) (flags - (:standard -open Core -open OpenSource -open InferIR -open InferStdlib -open IStd -open InferGenerated - -open InferBase -open Absint -open Biabduction -open Bo -open Pulselib)) - (libraries base64 core ocamlgraph InferStdlib InferGenerated InferBase InferIR absint biabduction bo pulselib) + (:standard -open Core -open OpenSource -open IR -open IStdlib -open IStd -open ATDGenerated + -open IBase -open Absint -open Biabduction -open BO -open Pulselib)) + (libraries base64 core ocamlgraph IStdlib ATDGenerated IBase IR Absint Biabduction BO Pulselib) (preprocess (pps ppx_compare)) ) diff --git a/infer/src/clang/dune.in b/infer/src/clang/dune.in index 630db99df..3073f54b5 100644 --- a/infer/src/clang/dune.in +++ b/infer/src/clang/dune.in @@ -15,9 +15,9 @@ let clang = (modules %s) (flags (:standard - -open Core -open InferStdlib -open IStd -open OpenSource -open InferGenerated - -open InferBase -open InferIR -open Absint -open Checkers -open TestDeterminators)) - (libraries core InferStdlib InferGenerated InferBase InferIR absint checkers TestDeterminators) + -open Core -open IStdlib -open IStd -open OpenSource -open ATDGenerated + -open IBase -open IR -open Absint -open Checkers -open TestDeterminators)) + (libraries core IStdlib ATDGenerated IBase IR Absint Checkers TestDeterminators) (preprocess (pps ppx_compare)) )|} (if clang then ":standard \\ ClangFrontendStubs" else "ClangFrontendStubs") diff --git a/infer/src/concurrency/dune b/infer/src/concurrency/dune index bc98d2f40..0c04b0186 100644 --- a/infer/src/concurrency/dune +++ b/infer/src/concurrency/dune @@ -4,11 +4,11 @@ ; LICENSE file in the root directory of this source tree. (library - (name concurrency) - (public_name infer.concurrency) + (name Concurrency) + (public_name infer.Concurrency) (flags - (:standard -open Core -open OpenSource -open InferIR -open InferStdlib -open IStd - -open InferGenerated -open InferBase -open Absint)) - (libraries base64 core InferStdlib InferGenerated InferBase InferIR absint) + (:standard -open Core -open OpenSource -open IR -open IStdlib -open IStd + -open ATDGenerated -open IBase -open Absint)) + (libraries base64 core IStdlib ATDGenerated IBase IR Absint) (preprocess (pps ppx_compare)) ) diff --git a/infer/src/cost/dune b/infer/src/cost/dune index 07652e907..52bfdd928 100644 --- a/infer/src/cost/dune +++ b/infer/src/cost/dune @@ -4,11 +4,11 @@ ; LICENSE file in the root directory of this source tree. (library - (name costlib) - (public_name infer.costlib) + (name Costlib) + (public_name infer.Costlib) (flags - (:standard -open Core -open OpenSource -open InferIR -open InferStdlib -open IStd - -open InferGenerated -open InferBase -open Absint -open Bo -open Checkers)) - (libraries core sledge InferStdlib InferGenerated InferBase InferIR absint bo checkers) + (:standard -open Core -open OpenSource -open IR -open IStdlib -open IStd + -open ATDGenerated -open IBase -open Absint -open BO -open Checkers)) + (libraries core sledge IStdlib ATDGenerated IBase IR Absint BO Checkers) (preprocess (pps ppx_compare)) ) diff --git a/infer/src/deadcode/dune.in b/infer/src/deadcode/dune.in index 8f9a1161d..61067007c 100644 --- a/infer/src/deadcode/dune.in +++ b/infer/src/deadcode/dune.in @@ -19,5 +19,5 @@ Format.sprintf (preprocess (pps ppx_compare ppx_enumerate ppx_fields_conv ppx_hash ppx_sexp_conv ppx_variants_conv -no-check)) ) |} - (String.concat " " ("absint" :: "InferIR" :: "InferCStubs" :: common_libraries)) + (String.concat " " ("Absint" :: "IR" :: "CStubs" :: common_libraries)) |> Jbuild_plugin.V1.send diff --git a/infer/src/dune.in b/infer/src/dune.in index 9e6ec8085..30393226e 100644 --- a/infer/src/dune.in +++ b/infer/src/dune.in @@ -37,7 +37,7 @@ let infer_cflags = ; "-open" ; "Biabduction" ; "-open" - ; "Bo" + ; "BO" ; "-open" ; "Nullsafe" ; "-open" @@ -59,17 +59,17 @@ let infer_cflags = ; "-open" ; "OpenSource" ; "-open" - ; "InferStdlib" + ; "IStdlib" ; "-open" ; "IStd" ; "-open" - ; "InferGenerated" + ; "ATDGenerated" ; "-open" - ; "InferIR" + ; "IR" ; "-open" - ; "InferBase" + ; "IBase" ; "-open" - ; "InferCStubs" + ; "CStubs" ; "-open" ; "Backend" ; "-open" @@ -103,24 +103,24 @@ let main_lib_stanza = (String.concat " " (* we need JavaFrontend first to avoid clashes around base64 vs extlib *) ( ("JavaFrontend" :: common_libraries) - @ [ "InferIR" - ; "InferCStubs" - ; "absint" - ; "biabduction" - ; "nullsafe" - ; "bo" - ; "pulselib" - ; "checkers" - ; "costlib" - ; "quandary" + @ [ "IR" + ; "CStubs" + ; "Absint" + ; "Biabduction" + ; "Nullsafe" + ; "BO" + ; "Pulselib" + ; "Checkers" + ; "Costlib" + ; "Quandary" ; "TOPLlib" - ; "concurrency" - ; "labs" - ; "backend" + ; "Concurrency" + ; "Labs" + ; "Backend" ; "ClangFrontend" ; "ASTLanguage" ; "TestDeterminators" - ; "integration" ] )) + ; "Integration" ] )) (String.concat " " infer_binaries) diff --git a/infer/src/integration/dune.in b/infer/src/integration/dune.in index 1731bc488..d718a4972 100644 --- a/infer/src/integration/dune.in +++ b/infer/src/integration/dune.in @@ -11,15 +11,15 @@ let library = Format.sprintf {| (library - (name integration) - (public_name infer.integration) + (name Integration) + (public_name infer.Integration) (flags (:standard - -open Core -open InferStdlib -open IStd -open OpenSource -open InferGenerated - -open InferBase -open InferIR -open Bo -open Costlib -open Concurrency -open Backend + -open Core -open IStdlib -open IStd -open OpenSource -open ATDGenerated + -open IBase -open IR -open BO -open Costlib -open Concurrency -open Backend -open TestDeterminators -open ClangFrontend -open ASTLanguage -open JavaFrontend %s %s)) - (libraries xmlm core InferStdlib InferGenerated InferBase InferIR bo costlib concurrency backend - TestDeterminators ClangFrontend ASTLanguage JavaFrontend) + (libraries xmlm core IStdlib ATDGenerated IBase IR BO Costlib Concurrency Backend + TestDeterminators ClangFrontend ASTLanguage JavaFrontend) (preprocess (pps ppx_compare)) ) |} diff --git a/infer/src/istd/dune b/infer/src/istd/dune index 54403f67d..11372da5a 100644 --- a/infer/src/istd/dune +++ b/infer/src/istd/dune @@ -4,8 +4,8 @@ ; LICENSE file in the root directory of this source tree. (library - (name InferStdlib) - (public_name infer.InferStdlib) + (name IStdlib) + (public_name infer.IStdlib) (flags (:standard -open Core)) (libraries ANSITerminal core str yojson) diff --git a/infer/src/java/dune.in b/infer/src/java/dune.in index 83514b46f..43ebd08b6 100644 --- a/infer/src/java/dune.in +++ b/infer/src/java/dune.in @@ -17,9 +17,9 @@ let java = (modules %s) (flags (:standard - -open Core -open InferStdlib -open IStd -open OpenSource -open InferGenerated - -open InferBase -open InferIR -open Absint)) - (libraries %s core InferStdlib InferGenerated InferBase InferIR absint) + -open Core -open IStdlib -open IStd -open OpenSource -open ATDGenerated + -open IBase -open IR -open Absint)) + (libraries %s core IStdlib ATDGenerated IBase IR Absint) (preprocess (pps ppx_compare)) )|} (if java then ":standard \\ JavaFrontendStubs" else "JavaFrontendStubs") diff --git a/infer/src/labs/dune b/infer/src/labs/dune index c398fa9fb..6f81f41fe 100644 --- a/infer/src/labs/dune +++ b/infer/src/labs/dune @@ -4,11 +4,11 @@ ; LICENSE file in the root directory of this source tree. (library - (name labs) - (public_name infer.labs) + (name Labs) + (public_name infer.Labs) (flags - (:standard -open Core -open InferIR -open InferStdlib -open IStd -open InferGenerated - -open InferBase -open Absint)) - (libraries core InferStdlib InferGenerated InferBase InferIR absint) + (:standard -open Core -open IR -open IStdlib -open IStd -open ATDGenerated + -open IBase -open Absint)) + (libraries core IStdlib ATDGenerated IBase IR Absint) (preprocess (pps ppx_compare)) ) diff --git a/infer/src/nullsafe/dune b/infer/src/nullsafe/dune index 374a52c9d..6d30991e0 100644 --- a/infer/src/nullsafe/dune +++ b/infer/src/nullsafe/dune @@ -4,11 +4,11 @@ ; LICENSE file in the root directory of this source tree. (library - (name nullsafe) - (public_name infer.nullsafe) + (name Nullsafe) + (public_name infer.Nullsafe) (flags - (:standard -open Core -open InferIR -open InferStdlib -open IStd -open InferGenerated - -open InferBase -open Absint -open Biabduction)) - (libraries core InferStdlib InferGenerated InferBase InferIR absint biabduction) + (:standard -open Core -open IR -open IStdlib -open IStd -open ATDGenerated + -open IBase -open Absint -open Biabduction)) + (libraries core IStdlib ATDGenerated IBase IR Absint Biabduction) (preprocess (pps ppx_compare ppx_sexp_conv)) ) diff --git a/infer/src/pulse/dune b/infer/src/pulse/dune index 63830d9a9..876a4c628 100644 --- a/infer/src/pulse/dune +++ b/infer/src/pulse/dune @@ -4,11 +4,11 @@ ; LICENSE file in the root directory of this source tree. (library - (name pulselib) - (public_name infer.pulselib) + (name Pulselib) + (public_name infer.Pulselib) (flags - (:standard -open Core -open InferIR -open InferStdlib -open IStd -open InferGenerated - -open InferBase -open Absint -open Bo)) - (libraries core sledge InferStdlib InferGenerated InferBase InferIR absint bo) + (:standard -open Core -open IR -open IStdlib -open IStd -open ATDGenerated + -open IBase -open Absint -open BO)) + (libraries core sledge IStdlib ATDGenerated IBase IR Absint BO) (preprocess (pps ppx_compare ppx_variants_conv)) ) diff --git a/infer/src/quandary/dune b/infer/src/quandary/dune index dfedd3303..98da76566 100644 --- a/infer/src/quandary/dune +++ b/infer/src/quandary/dune @@ -4,11 +4,11 @@ ; LICENSE file in the root directory of this source tree. (library - (name quandary) - (public_name infer.quandary) + (name Quandary) + (public_name infer.Quandary) (flags - (:standard -open Core -open InferIR -open InferStdlib -open IStd -open InferGenerated - -open InferBase -open Absint)) - (libraries core InferStdlib InferGenerated InferBase InferIR absint) + (:standard -open Core -open IR -open IStdlib -open IStd -open ATDGenerated + -open IBase -open Absint)) + (libraries core IStdlib ATDGenerated IBase IR Absint) (preprocess (pps ppx_compare)) ) diff --git a/infer/src/test_determinator/dune b/infer/src/test_determinator/dune index e8b9fa17a..91367181f 100644 --- a/infer/src/test_determinator/dune +++ b/infer/src/test_determinator/dune @@ -8,8 +8,8 @@ (public_name infer.TestDeterminators) (flags (:standard - -open Core -open InferStdlib -open IStd -open OpenSource -open InferGenerated - -open InferBase -open InferIR -open InferCStubs)) - (libraries core InferStdlib InferGenerated InferBase InferIR InferCStubs) + -open Core -open IStdlib -open IStd -open OpenSource -open ATDGenerated + -open IBase -open IR -open CStubs)) + (libraries core IStdlib ATDGenerated IBase IR CStubs) (preprocess (pps ppx_compare)) ) diff --git a/infer/src/topl/dune b/infer/src/topl/dune index 7abe7e85a..6f74df839 100644 --- a/infer/src/topl/dune +++ b/infer/src/topl/dune @@ -11,8 +11,8 @@ (name TOPLlib) (public_name infer.TOPLlib) (flags - (:standard -open Core -open InferIR -open InferStdlib -open IStd -open InferGenerated - -open InferBase -open Absint -open Biabduction)) - (libraries core InferStdlib InferGenerated InferBase InferIR absint biabduction) + (:standard -open Core -open IR -open IStdlib -open IStd -open ATDGenerated + -open IBase -open Absint -open Biabduction)) + (libraries core IStdlib ATDGenerated IBase IR Absint Biabduction) (preprocess (pps ppx_compare ppx_hash ppx_sexp_conv)) ) diff --git a/scripts/toplevel_init b/scripts/toplevel_init index 7d918e607..0350bbde2 100644 --- a/scripts/toplevel_init +++ b/scripts/toplevel_init @@ -16,11 +16,29 @@ #require "sqlite3";; #require "xmlm";; -open InferStdlib;; -open InferGenerated;; -open InferBase;; -open InferIR;; -open InferModules;; +open IStdlib;; +open ATDGenerated;; +open CStubs;; +open IBase;; +open IR;; +open Absint;; +open Biabduction;; +open BO;; +open Nullsafe;; +open Pulselib;; +open Checkers;; +open Costlib;; +open Quandary;; +open TOPLlib;; +open Concurrency;; +open Labs;; +open OpenSource;; +open Backend;; +open JavaFrontend;; +open ClangFrontend;; +open ASTLanguage;; +open TestDeterminators;; +open Integration;; (* Most of infer uses this, useful for copy/pasting. Can be (partially) countered by typing `open Caml.Pervasives`. *)