From f5433ff0937ce62391ab5c48aa129728b5dfa8e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Georges=20Dup=C3=A9ron?= Date: Tue, 5 Apr 2016 13:04:23 +0200 Subject: [PATCH] =?UTF-8?q?Migrate=20lib/=20to=20jsmaniac/phc-toolkit=20pr?= =?UTF-8?q?oject:=20Use=20phc-toolkit=20instead=20of=20lib/=E2=80=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- graph-lib/Makefile | 10 ++++- graph-lib/README.md | 40 ------------------- graph-lib/graph/__DEBUG_constructor.rkt | 2 +- graph-lib/graph/__DEBUG_graph5.rkt | 2 +- graph-lib/graph/__DEBUG_graph6.rkt | 6 +-- graph-lib/graph/__DEBUG_variant.rkt | 2 +- graph-lib/graph/adt-test.rkt | 8 ++-- graph-lib/graph/constructor-test.rkt | 2 +- graph-lib/graph/constructor.lp2.rkt | 4 +- graph-lib/graph/define-adt-test.rkt | 2 +- graph-lib/graph/define-adt.lp2.rkt | 4 +- graph-lib/graph/dotlang-test.rkt | 2 +- graph-lib/graph/dotlang.rkt | 4 +- graph-lib/graph/fold-queues.lp2.rkt | 4 +- graph-lib/graph/get-test.rkt | 2 +- graph-lib/graph/get.lp2.rkt | 4 +- graph-lib/graph/graph-5-multi-ctors.lp2.rkt | 4 +- graph-lib/graph/graph-6-rich-returns.lp2.rkt | 4 +- graph-lib/graph/graph-test.rkt | 2 +- graph-lib/graph/graph.lp2.rkt | 4 +- graph-lib/graph/graph_old.lp2.rkt | 10 ++--- graph-lib/graph/map-test.rkt | 2 +- graph-lib/graph/map.rkt | 4 +- graph-lib/graph/map1.rkt | 2 +- graph-lib/graph/map3.rkt | 4 +- graph-lib/graph/map_old.rkt | 8 ++-- graph-lib/graph/queue.lp2.rkt | 4 +- graph-lib/graph/remember-lib.rkt | 4 +- graph-lib/graph/rewrite-type.lp2.rkt | 6 +-- graph-lib/graph/structure-test.rkt | 2 +- graph-lib/graph/structure.lp2.rkt | 4 +- graph-lib/graph/tagged-test.rkt | 2 +- graph-lib/graph/tagged.lp2.rkt | 4 +- graph-lib/graph/uniform-get.lp2.rkt | 4 +- graph-lib/graph/variant-test.rkt | 2 +- graph-lib/graph/variant.lp2.rkt.old | 6 +-- graph-lib/graph/variant2.lp2.rkt | 4 +- graph-lib/lib.rkt | 2 +- graph-lib/lib/doc/template.lp2.rkt | 4 +- graph-lib/lib/low/multiassoc-syntax.rkt | 2 +- graph-lib/make/dependency-graph.rkt | 21 +++++++--- .../2016-02-02--all-nodes-point-to-root.rkt | 2 +- graph-lib/type-expander/multi-id.lp2.rkt | 2 +- .../type-expander/type-expander-test.rkt | 4 +- graph-lib/type-expander/type-expander.lp2.rkt | 8 ++-- 45 files changed, 103 insertions(+), 126 deletions(-) diff --git a/graph-lib/Makefile b/graph-lib/Makefile index bcd80c3f..e835d560 100644 --- a/graph-lib/Makefile +++ b/graph-lib/Makefile @@ -13,4 +13,12 @@ clean: .PHONY: build-dep build-dep: # datatype is only used as an example in the docs. - raco pkg install --deps search-auto --update-deps --skip-installed alexis-util cover cover-coveralls debug datatype mischief https://github.com/jsmaniac/scribble-enhanced.git#823fdda5a65552ce4fe8d6f8fbe07391ccca73bd + raco pkg install --deps search-auto --update-deps --skip-installed \ + alexis-util \ + cover \ + cover-coveralls \ + debug \ + datatype \ + mischief \ + https://github.com/jsmaniac/scribble-enhanced.git#d4c8f889b4d68c0acef8f73b15641af095051b8e \ + https://github.com/jsmaniac/phc-toolkit.git#31dff12f8c0ca13f2bc97d3ad098dbe5b274ec50 diff --git a/graph-lib/README.md b/graph-lib/README.md index e780e19a..a20c13c4 100644 --- a/graph-lib/README.md +++ b/graph-lib/README.md @@ -193,46 +193,6 @@ Type-expander Library functions and utilities ------------------------------- -* `lib/eval-get-values.rkt` - - Wrapper for the racket `eval` function that allows evaluation of code with - multiple return values in typed/racket. - -* `lib/lib.rkt` - - Utilities that complement racket and typed/racket's standard libraries. - -* `lib/low.rkt` and `lib/low/*.rkt` - - Lower-level utilities that complement racket and typed/racket's standard - libraries. - -* `lib/untyped/for-star-list-star.rkt` - - A utility macro similar to `for*/list` to iterate over collections and return - a list of results, but which can return nested lists instead of just a flat - one. - -* `lib/untyped.rkt` - - Aggregates `(submod "lib/low.rkt" untyped)`, and - `lib/untyped/for-star-list-star.rkt`. - -* `lib/test-framework.rkt` - - Some wrappers and utilities that allow easier use of the rackunit test - framework from typed/racket files. - -* `lib/syntax/quasitemplate.rkt` - - Extension of the `syntax/parse/experimental/template` library, that allows - using `unsyntax` and `unsyntax-splicing` inside a `quasitemplate`, just like - in the normal `quasisyntax`. - -* `lib/path.rkt` - - Filesystem path manipulation utilities. - * `lib/doc.rkt` Enhancements and utilities for documentation and literate programming files diff --git a/graph-lib/graph/__DEBUG_constructor.rkt b/graph-lib/graph/__DEBUG_constructor.rkt index 4fab3b0d..5cc7365b 100644 --- a/graph-lib/graph/__DEBUG_constructor.rkt +++ b/graph-lib/graph/__DEBUG_constructor.rkt @@ -2,4 +2,4 @@ (require syntax/parse syntax/parse/experimental/template) (require (for-template "../type-expander/type-expander.lp2.rkt")) -(require (submod "../lib/low.rkt" untyped)) \ No newline at end of file +(require (submod phc-toolkit untyped)) \ No newline at end of file diff --git a/graph-lib/graph/__DEBUG_graph5.rkt b/graph-lib/graph/__DEBUG_graph5.rkt index 34d77bcd..f5c7128c 100644 --- a/graph-lib/graph/__DEBUG_graph5.rkt +++ b/graph-lib/graph/__DEBUG_graph5.rkt @@ -41,7 +41,7 @@ |# (require "graph-5-multi-ctors.lp2.rkt" - "../lib/low.rkt" + phc-toolkit "graph.lp2.rkt" "get.lp2.rkt" "../type-expander/type-expander.lp2.rkt" diff --git a/graph-lib/graph/__DEBUG_graph6.rkt b/graph-lib/graph/__DEBUG_graph6.rkt index 1ac9dec0..ebb7a5f4 100644 --- a/graph-lib/graph/__DEBUG_graph6.rkt +++ b/graph-lib/graph/__DEBUG_graph6.rkt @@ -2,7 +2,7 @@ (module test-~>-bound typed/racket (require "graph-6-rich-returns.lp2.rkt" - "../lib/low.rkt" + phc-toolkit "get.lp2.rkt" "../type-expander/type-expander.lp2.rkt") @@ -45,9 +45,7 @@ (module test-~>-unbound typed/racket (require "graph-6-rich-returns.lp2.rkt" - (only-in "../lib/low.rkt" - check-equal?: - …) + (only-in phc-toolkit check-equal?: …) "get.lp2.rkt" "../type-expander/type-expander.lp2.rkt") diff --git a/graph-lib/graph/__DEBUG_variant.rkt b/graph-lib/graph/__DEBUG_variant.rkt index 5defdb4d..f3b8b6a9 100644 --- a/graph-lib/graph/__DEBUG_variant.rkt +++ b/graph-lib/graph/__DEBUG_variant.rkt @@ -40,7 +40,7 @@ (module* test typed/racket (require (submod "..") - "../lib/low.rkt" + phc-toolkit "../type-expander/type-expander.lp2.rkt" typed/rackunit "adt.lp2.rkt") diff --git a/graph-lib/graph/adt-test.rkt b/graph-lib/graph/adt-test.rkt index 55ff5143..c18e272b 100644 --- a/graph-lib/graph/adt-test.rkt +++ b/graph-lib/graph/adt-test.rkt @@ -1,10 +1,10 @@ #lang typed/racket (module test typed/racket - (require (submod "graph-test.rkt" test)) - (require "adt.lp2.rkt") - (require "../lib/low.rkt") - (require "../type-expander/type-expander.lp2.rkt") + (require (submod "graph-test.rkt" test) + "adt.lp2.rkt" + phc-toolkit + "../type-expander/type-expander.lp2.rkt") (define-tagged st2 [b String] [a Number]) diff --git a/graph-lib/graph/constructor-test.rkt b/graph-lib/graph/constructor-test.rkt index d1c30dee..e50b940c 100644 --- a/graph-lib/graph/constructor-test.rkt +++ b/graph-lib/graph/constructor-test.rkt @@ -2,7 +2,7 @@ (module test typed/racket (require "constructor.lp2.rkt" - "../lib/low.rkt" + phc-toolkit "../type-expander/type-expander.lp2.rkt") (check-equal?: (constructor-values diff --git a/graph-lib/graph/constructor.lp2.rkt b/graph-lib/graph/constructor.lp2.rkt index f1bd79e4..28c199a0 100644 --- a/graph-lib/graph/constructor.lp2.rkt +++ b/graph-lib/graph/constructor.lp2.rkt @@ -217,9 +217,9 @@ instance: syntax/parse syntax/parse/experimental/template racket/syntax - (submod "../lib/low.rkt" untyped)) + (submod phc-toolkit untyped)) (for-meta 2 racket/base) - "../lib/low.rkt" + phc-toolkit "../type-expander/multi-id.lp2.rkt" "../type-expander/type-expander.lp2.rkt") diff --git a/graph-lib/graph/define-adt-test.rkt b/graph-lib/graph/define-adt-test.rkt index 290fdb8d..aeb65a45 100644 --- a/graph-lib/graph/define-adt-test.rkt +++ b/graph-lib/graph/define-adt-test.rkt @@ -4,7 +4,7 @@ (require "define-adt.lp2.rkt" "constructor.lp2.rkt" "tagged.lp2.rkt" - "../lib/low.rkt" + phc-toolkit "../type-expander/type-expander.lp2.rkt") ;; define-tagged diff --git a/graph-lib/graph/define-adt.lp2.rkt b/graph-lib/graph/define-adt.lp2.rkt index 6afb2e42..8493b5f2 100644 --- a/graph-lib/graph/define-adt.lp2.rkt +++ b/graph-lib/graph/define-adt.lp2.rkt @@ -126,12 +126,12 @@ used. The macro's expansion will use this to declare syntax/parse syntax/parse/experimental/template racket/syntax - (submod "../lib/low.rkt" untyped)) + (submod phc-toolkit untyped)) (for-meta 2 racket/base) "constructor.lp2.rkt" (submod "constructor.lp2.rkt" main private) "tagged.lp2.rkt" - "../lib/low.rkt" + phc-toolkit "../type-expander/multi-id.lp2.rkt" "../type-expander/type-expander.lp2.rkt") diff --git a/graph-lib/graph/dotlang-test.rkt b/graph-lib/graph/dotlang-test.rkt index cf1447e1..8d1fecfc 100644 --- a/graph-lib/graph/dotlang-test.rkt +++ b/graph-lib/graph/dotlang-test.rkt @@ -2,7 +2,7 @@ (module test "dotlang.rkt" (require typed/rackunit - "../lib/low.rkt" + phc-toolkit "get.lp2.rkt" (submod "graph-test.rkt" test) "map.rkt") diff --git a/graph-lib/graph/dotlang.rkt b/graph-lib/graph/dotlang.rkt index 9114025f..0c1892fa 100644 --- a/graph-lib/graph/dotlang.rkt +++ b/graph-lib/graph/dotlang.rkt @@ -13,7 +13,7 @@ (require "get.lp2.rkt" - (submod "../lib/low.rkt" untyped) + (submod phc-toolkit untyped) (for-syntax racket/string syntax/parse racket/syntax @@ -21,7 +21,7 @@ racket/struct racket/function syntax/srcloc - (submod "../lib/low.rkt" untyped))) + (submod phc-toolkit untyped))) #| (define-syntax/parse (dot x:id) diff --git a/graph-lib/graph/fold-queues.lp2.rkt b/graph-lib/graph/fold-queues.lp2.rkt index 19501589..65519aba 100644 --- a/graph-lib/graph/fold-queues.lp2.rkt +++ b/graph-lib/graph/fold-queues.lp2.rkt @@ -247,8 +247,8 @@ position in the vector equal to the index associated to it in the hash table: (require (for-syntax syntax/parse syntax/parse/experimental/template racket/syntax - (submod "../lib/low.rkt" untyped)) - "../lib/low.rkt" + (submod phc-toolkit untyped)) + phc-toolkit "../type-expander/type-expander.lp2.rkt") (provide fold-queues) diff --git a/graph-lib/graph/get-test.rkt b/graph-lib/graph/get-test.rkt index 86f8ee34..8388cd48 100644 --- a/graph-lib/graph/get-test.rkt +++ b/graph-lib/graph/get-test.rkt @@ -4,7 +4,7 @@ (require (submod "graph-test.rkt" test)) (require "get.lp2.rkt") (require "adt.lp2.rkt") - (require "../lib/low.rkt") + (require phc-toolkit) (require "../type-expander/type-expander.lp2.rkt") (check-equal?: (get '((1 2) (3)) … …) diff --git a/graph-lib/graph/get.lp2.rkt b/graph-lib/graph/get.lp2.rkt index a2b8866b..8d3103fc 100644 --- a/graph-lib/graph/get.lp2.rkt +++ b/graph-lib/graph/get.lp2.rkt @@ -202,8 +202,8 @@ The type for the function generated by @tc[λget] mirrors the cases from (module main typed/racket (require (for-syntax syntax/parse racket/syntax - (submod "../lib/low.rkt" untyped)) - "../lib/low.rkt" + (submod phc-toolkit untyped)) + phc-toolkit "adt.lp2.rkt" "graph.lp2.rkt" "../type-expander/multi-id.lp2.rkt" diff --git a/graph-lib/graph/graph-5-multi-ctors.lp2.rkt b/graph-lib/graph/graph-5-multi-ctors.lp2.rkt index c6202865..ccc37d40 100644 --- a/graph-lib/graph/graph-5-multi-ctors.lp2.rkt +++ b/graph-lib/graph/graph-5-multi-ctors.lp2.rkt @@ -147,8 +147,8 @@ name) with the right type, so that the user doesn't see all the types in the (require (for-syntax syntax/parse syntax/parse/experimental/template racket/syntax - (submod "../lib/low.rkt" untyped)) - "../lib/low.rkt" + (submod phc-toolkit untyped)) + phc-toolkit "graph.lp2.rkt" "get.lp2.rkt" "../type-expander/type-expander.lp2.rkt" diff --git a/graph-lib/graph/graph-6-rich-returns.lp2.rkt b/graph-lib/graph/graph-6-rich-returns.lp2.rkt index 6752a5c4..c5f92121 100644 --- a/graph-lib/graph/graph-6-rich-returns.lp2.rkt +++ b/graph-lib/graph/graph-6-rich-returns.lp2.rkt @@ -741,10 +741,10 @@ encapsulating the result types of mappings. (require (for-syntax syntax/parse syntax/parse/experimental/template racket/syntax - (submod "../lib/low.rkt" untyped) + (submod phc-toolkit untyped) "rewrite-type.lp2.rkt" racket/format) - "../lib/low.rkt" + phc-toolkit "graph.lp2.rkt" "get.lp2.rkt" "../type-expander/type-expander.lp2.rkt" diff --git a/graph-lib/graph/graph-test.rkt b/graph-lib/graph/graph-test.rkt index 87257f9d..a3b53aca 100644 --- a/graph-lib/graph/graph-test.rkt +++ b/graph-lib/graph/graph-test.rkt @@ -9,7 +9,7 @@ (replace-context stx tests)) (require "graph.lp2.rkt" - (only-in "../lib/low.rkt" cars cdrs check-equal?: check-true: % in) + (only-in phc-toolkit cars cdrs check-equal?: check-true: % in) (only-in "adt.lp2.rkt" uniform-get) "../type-expander/type-expander.lp2.rkt") diff --git a/graph-lib/graph/graph.lp2.rkt b/graph-lib/graph/graph.lp2.rkt index 22b65f76..882fa34f 100644 --- a/graph-lib/graph/graph.lp2.rkt +++ b/graph-lib/graph/graph.lp2.rkt @@ -829,12 +829,12 @@ We will be able to use this type expander in function types, for example: racket/sequence racket/pretty "rewrite-type.lp2.rkt" - (submod "../lib/low.rkt" untyped) + (submod phc-toolkit untyped) "meta-struct.rkt") racket/splicing "fold-queues.lp2.rkt" "rewrite-type.lp2.rkt" - "../lib/low.rkt" + phc-toolkit "adt.lp2.rkt" "../type-expander/type-expander.lp2.rkt" "../type-expander/multi-id.lp2.rkt" diff --git a/graph-lib/graph/graph_old.lp2.rkt b/graph-lib/graph/graph_old.lp2.rkt index 6f980664..38b67c57 100644 --- a/graph-lib/graph/graph_old.lp2.rkt +++ b/graph-lib/graph/graph_old.lp2.rkt @@ -841,11 +841,11 @@ checker, unless it is absorbed by a larger type, like in racket/syntax racket/function racket/pretty - (submod "../lib/low.rkt" untyped) - "../lib/untyped.rkt") + (submod phc-toolkit untyped) + phc-toolkit/untyped/for-star-list-star) (prefix-in DEBUG-tr: typed/racket) syntax/parse - "../lib/low.rkt" + phc-toolkit "adt.lp2.rkt" "../type-expander/multi-id.lp2.rkt" "../type-expander/type-expander.lp2.rkt") @@ -866,12 +866,12 @@ checker, unless it is absorbed by a larger type, like in (module* test typed/racket (require (submod "..") "../type-expander/type-expander.lp2.rkt" - "../lib/test-framework.rkt") + phc-toolkit/test-framework) ;; Debug (require syntax/parse - "../lib/low.rkt" + phc-toolkit "adt.lp2.rkt" "../type-expander/multi-id.lp2.rkt" "../type-expander/type-expander.lp2.rkt") diff --git a/graph-lib/graph/map-test.rkt b/graph-lib/graph/map-test.rkt index fc3d7bba..e3ec1616 100644 --- a/graph-lib/graph/map-test.rkt +++ b/graph-lib/graph/map-test.rkt @@ -6,7 +6,7 @@ (require (submod "graph-test.rkt" test) "get.lp2.rkt" "map.rkt" - "../lib/low.rkt" + phc-toolkit "../type-expander/type-expander.lp2.rkt") (begin diff --git a/graph-lib/graph/map.rkt b/graph-lib/graph/map.rkt index 4f4aec68..630b9ff6 100644 --- a/graph-lib/graph/map.rkt +++ b/graph-lib/graph/map.rkt @@ -3,8 +3,8 @@ (require (for-syntax racket/syntax racket/function syntax/parse - (submod "../lib/low.rkt" untyped)) - "../lib/low.rkt" + (submod phc-toolkit untyped)) + phc-toolkit "get.lp2.rkt" "../type-expander/type-expander.lp2.rkt") diff --git a/graph-lib/graph/map1.rkt b/graph-lib/graph/map1.rkt index ab6f20e0..163cf180 100644 --- a/graph-lib/graph/map1.rkt +++ b/graph-lib/graph/map1.rkt @@ -1,7 +1,7 @@ #lang typed/racket (require (for-syntax syntax/parse - (submod "../lib/low.rkt" untyped)) + (submod phc-toolkit untyped)) "../type-expander/type-expander.lp2.rkt") (provide curry-map) diff --git a/graph-lib/graph/map3.rkt b/graph-lib/graph/map3.rkt index 68f8d5ce..5689db7e 100644 --- a/graph-lib/graph/map3.rkt +++ b/graph-lib/graph/map3.rkt @@ -3,8 +3,8 @@ (require (for-syntax racket/syntax syntax/parse syntax/parse/experimental/template - (submod "../lib/low.rkt" untyped)) - "../lib/low.rkt" + (submod phc-toolkit untyped)) + phc-toolkit "get.lp2.rkt" "../type-expander/type-expander.lp2.rkt") diff --git a/graph-lib/graph/map_old.rkt b/graph-lib/graph/map_old.rkt index cc4167ed..100446e1 100644 --- a/graph-lib/graph/map_old.rkt +++ b/graph-lib/graph/map_old.rkt @@ -3,15 +3,15 @@ (require (for-syntax racket/syntax syntax/parse syntax/parse/experimental/template - (submod "../lib/low.rkt" untyped)) + (submod phc-toolkit untyped)) (for-meta 2 racket/base racket/syntax) - "../lib/low.rkt" + phc-toolkit "get.lp2.rkt" "../type-expander/type-expander.lp2.rkt") -(provide map: apply-compose) ;; TODO: move apply-compose to lib/low.rkt +(provide map: apply-compose) ;; TODO: move apply-compose to phc-toolkit (begin-for-syntax (define-syntax-class lam @@ -198,7 +198,7 @@ (module* test typed/racket (require (submod "..") - "../lib/low.rkt") + phc-toolkit) (check-equal?: (map: add1 '(1 2 3)) : (Listof Number) diff --git a/graph-lib/graph/queue.lp2.rkt b/graph-lib/graph/queue.lp2.rkt index 9a027fe9..22ae90da 100644 --- a/graph-lib/graph/queue.lp2.rkt +++ b/graph-lib/graph/queue.lp2.rkt @@ -375,8 +375,8 @@ was a tag requested. (module main typed/racket (require (for-syntax syntax/parse racket/syntax - (submod "../lib/low.rkt" untyped)) - "../lib/low.rkt" + (submod phc-toolkit untyped)) + phc-toolkit racket/set racket/format) diff --git a/graph-lib/graph/remember-lib.rkt b/graph-lib/graph/remember-lib.rkt index 1a18bf18..695f27bf 100644 --- a/graph-lib/graph/remember-lib.rkt +++ b/graph-lib/graph/remember-lib.rkt @@ -115,9 +115,9 @@ declared using @tc[define-syntax]. @chunk[ (require mzlib/etc - (submod "../lib/low.rkt" untyped) + (submod phc-toolkit untyped) (for-syntax mzlib/etc - (submod "../lib/low.rkt" untyped) + (submod phc-toolkit untyped) racket/string racket/format mischief/transform)) diff --git a/graph-lib/graph/rewrite-type.lp2.rkt b/graph-lib/graph/rewrite-type.lp2.rkt index 12be09b3..e8887312 100644 --- a/graph-lib/graph/rewrite-type.lp2.rkt +++ b/graph-lib/graph/rewrite-type.lp2.rkt @@ -549,11 +549,11 @@ These metafunctions just extract the arguments for @tc[replace-in-type] and racket/format syntax/parse/experimental/template racket/sequence - (submod "../lib/low.rkt" untyped) + (submod phc-toolkit untyped) (only-in "../type-expander/type-expander.lp2.rkt" expand-type) "meta-struct.rkt" - "../lib/low/backtrace.rkt" + phc-toolkit/backtrace racket/require debug ;; DEBUG (for-template (subtract-in @@ -561,7 +561,7 @@ These metafunctions just extract the arguments for @tc[replace-in-type] and "../type-expander/type-expander.lp2.rkt") "../type-expander/multi-id.lp2.rkt" "../type-expander/type-expander.lp2.rkt" - "../lib/low.rkt")) + phc-toolkit)) (provide replace-in-type ;replace-in-instance fold-instance diff --git a/graph-lib/graph/structure-test.rkt b/graph-lib/graph/structure-test.rkt index c2617406..0955f1c2 100644 --- a/graph-lib/graph/structure-test.rkt +++ b/graph-lib/graph/structure-test.rkt @@ -8,7 +8,7 @@ (replace-context stx tests)) (require "structure.lp2.rkt" - "../lib/low.rkt" + phc-toolkit "../type-expander/type-expander.lp2.rkt" typed/rackunit) diff --git a/graph-lib/graph/structure.lp2.rkt b/graph-lib/graph/structure.lp2.rkt index 64428769..6086746f 100644 --- a/graph-lib/graph/structure.lp2.rkt +++ b/graph-lib/graph/structure.lp2.rkt @@ -420,11 +420,11 @@ its arguments across compilations, and adds them to the file racket/sequence ;; in-syntax on older versions: ;;;unstable/sequence - (submod "../lib/low.rkt" untyped) + (submod phc-toolkit untyped) "meta-struct.rkt" "remember-lib.rkt" mischief/transform) - "../lib/low.rkt" + phc-toolkit "../type-expander/type-expander.lp2.rkt" "../type-expander/multi-id.lp2.rkt") (provide define-structure diff --git a/graph-lib/graph/tagged-test.rkt b/graph-lib/graph/tagged-test.rkt index 3b942572..cd34dd2b 100644 --- a/graph-lib/graph/tagged-test.rkt +++ b/graph-lib/graph/tagged-test.rkt @@ -2,7 +2,7 @@ (module test typed/racket (require "tagged.lp2.rkt" - "../lib/low.rkt" + phc-toolkit "../type-expander/type-expander.lp2.rkt") (check-equal?: (match (ann (tagged t1 [x 1] [y "b"]) diff --git a/graph-lib/graph/tagged.lp2.rkt b/graph-lib/graph/tagged.lp2.rkt index d327ae2c..335fd459 100644 --- a/graph-lib/graph/tagged.lp2.rkt +++ b/graph-lib/graph/tagged.lp2.rkt @@ -123,8 +123,8 @@ for a structure. syntax/parse syntax/parse/experimental/template racket/syntax - (submod "../lib/low.rkt" untyped)) - "../lib/low.rkt" + (submod phc-toolkit untyped)) + phc-toolkit "../type-expander/multi-id.lp2.rkt" "../type-expander/type-expander.lp2.rkt" "constructor.lp2.rkt" diff --git a/graph-lib/graph/uniform-get.lp2.rkt b/graph-lib/graph/uniform-get.lp2.rkt index 464372a3..3eb22d69 100644 --- a/graph-lib/graph/uniform-get.lp2.rkt +++ b/graph-lib/graph/uniform-get.lp2.rkt @@ -52,8 +52,8 @@ retrieves the desired field from the structure. syntax/parse syntax/parse/experimental/template racket/syntax - (submod "../lib/low.rkt" untyped)) - "../lib/low.rkt" + (submod phc-toolkit untyped)) + phc-toolkit "../type-expander/multi-id.lp2.rkt" "../type-expander/type-expander.lp2.rkt" "constructor.lp2.rkt" diff --git a/graph-lib/graph/variant-test.rkt b/graph-lib/graph/variant-test.rkt index 793e6200..7ddb4da2 100644 --- a/graph-lib/graph/variant-test.rkt +++ b/graph-lib/graph/variant-test.rkt @@ -3,7 +3,7 @@ (module test typed/racket (require "variant2.lp2.rkt" "constructor.lp2.rkt" - "../lib/low.rkt" + phc-toolkit "../type-expander/type-expander.lp2.rkt") (define-variant v1 [x Number String] [y String Number] [z Number String]) diff --git a/graph-lib/graph/variant.lp2.rkt.old b/graph-lib/graph/variant.lp2.rkt.old index 7f66e9bf..47a3872a 100644 --- a/graph-lib/graph/variant.lp2.rkt.old +++ b/graph-lib/graph/variant.lp2.rkt.old @@ -13,8 +13,8 @@ syntax/parse syntax/parse/experimental/template racket/syntax - (submod "../lib/low.rkt" untyped)) - "../lib/low.rkt" + (submod phc-toolkit untyped)) + phc-toolkit "../type-expander/multi-id.lp2.rkt" "../type-expander/type-expander.lp2.rkt" "structure.lp2.rkt") @@ -50,7 +50,7 @@ (require (submod "..") (submod ".." main test-helpers) typed/rackunit - "../lib/low.rkt" + phc-toolkit "../type-expander/type-expander.lp2.rkt") diff --git a/graph-lib/graph/variant2.lp2.rkt b/graph-lib/graph/variant2.lp2.rkt index 4b56f790..dd523b10 100644 --- a/graph-lib/graph/variant2.lp2.rkt +++ b/graph-lib/graph/variant2.lp2.rkt @@ -110,8 +110,8 @@ function. syntax/parse syntax/parse/experimental/template racket/syntax - (submod "../lib/low.rkt" untyped)) - "../lib/low.rkt" + (submod phc-toolkit untyped)) + phc-toolkit "../type-expander/multi-id.lp2.rkt" "../type-expander/type-expander.lp2.rkt" "constructor.lp2.rkt" diff --git a/graph-lib/lib.rkt b/graph-lib/lib.rkt index f4fcafc5..e9576742 100644 --- a/graph-lib/lib.rkt +++ b/graph-lib/lib.rkt @@ -7,7 +7,7 @@ (require . mods) (provide (all-from-out . mods)))) -(r/p "lib/low.rkt" +(r/p phc-toolkit "type-expander/multi-id.lp2.rkt" "type-expander/type-expander.lp2.rkt" "graph/adt.lp2.rkt" diff --git a/graph-lib/lib/doc/template.lp2.rkt b/graph-lib/lib/doc/template.lp2.rkt index 365db714..85ee217c 100644 --- a/graph-lib/lib/doc/template.lp2.rkt +++ b/graph-lib/lib/doc/template.lp2.rkt @@ -50,8 +50,8 @@ scribble, see (module main typed/racket (require (for-syntax syntax/parse racket/syntax - (submod "../../lib/low.rkt" untyped)) - (submod "../../lib/low.rkt" untyped)) + (submod phc-toolkit untyped)) + (submod phc-toolkit untyped)) (provide foo) diff --git a/graph-lib/lib/low/multiassoc-syntax.rkt b/graph-lib/lib/low/multiassoc-syntax.rkt index 551a5715..e27a5260 100644 --- a/graph-lib/lib/low/multiassoc-syntax.rkt +++ b/graph-lib/lib/low/multiassoc-syntax.rkt @@ -9,7 +9,7 @@ (require-typed/untyped "aliases.rkt" "stx.rkt") - ;; TODO: cdr-stx-assoc is already defined in lib/low.rkt + ;; TODO: cdr-stx-assoc is already defined in phc-toolkit (define-type (Stx-AList A) (Syntaxof (Listof (Syntaxof (Pairof Identifier A))))) diff --git a/graph-lib/make/dependency-graph.rkt b/graph-lib/make/dependency-graph.rkt index cda8da38..599b5c74 100644 --- a/graph-lib/make/dependency-graph.rkt +++ b/graph-lib/make/dependency-graph.rkt @@ -7,11 +7,16 @@ (define (categorize x) (match x + [(? symbol? + (? (λ (x) (regexp-match #px"^phc-toolkit(/|$)" (symbol->string x))))) + 'phc-toolkit] + #;[(? (λ (x) (regexp-match #px"phc-toolkit" (format "~a" x)))) + 'phc-toolkit] [(? symbol?) 'lib] [(list 'quote (? symbol? (? (λ (x) (regexp-match #rx"^#%" (symbol->string x)))))) 'lib] - [(list 'submod (? symbol?) _ ...) 'lib] + [(list 'submod sub _ ...) (categorize sub)] [(list (? symbol? s) _ ...) s] [_ #f])) @@ -119,10 +124,16 @@ [_ #f])) (define (tag-pair dep) - (append (if (equal? (cdr dep) "lib/low.rkt") '(lib/low) '()) + (append (if (eq? (categorize (cdr dep)) 'phc-toolkit) + '(phc-toolkit) + '()) (if (equal? (categorize-main-module (car dep)) - (categorize-main-module (cdr dep))) '(submodule) '()) - (if (lib? (cdr dep)) '(lib) '()))) + (categorize-main-module (cdr dep))) + '(submodule) + '()) + (if (lib? (cdr dep)) + '(lib) + '()))) (define tagged-dep-pairs (map (λ (dep) @@ -190,7 +201,7 @@ (define (dep-tag->style t) (case t - [(lib/low) "color=grey,style=dotted"] + [(phc-toolkit) "color=grey,style=dotted"] [(submodule) "color=grey"] [(lib) "style=dashed"] [else #f])) diff --git a/graph-lib/test/regression/2016-02-02--all-nodes-point-to-root.rkt b/graph-lib/test/regression/2016-02-02--all-nodes-point-to-root.rkt index 1073a0c5..de5520d1 100644 --- a/graph-lib/test/regression/2016-02-02--all-nodes-point-to-root.rkt +++ b/graph-lib/test/regression/2016-02-02--all-nodes-point-to-root.rkt @@ -1,6 +1,6 @@ #lang typed/racket -(require "../../lib/low.rkt" +(require phc-toolkit "../../graph/graph.lp2.rkt" "../../graph/get.lp2.rkt" "../../type-expander/type-expander.lp2.rkt") diff --git a/graph-lib/type-expander/multi-id.lp2.rkt b/graph-lib/type-expander/multi-id.lp2.rkt index 27cc71ff..dd3fb698 100644 --- a/graph-lib/type-expander/multi-id.lp2.rkt +++ b/graph-lib/type-expander/multi-id.lp2.rkt @@ -192,7 +192,7 @@ Test with @tc[#:else]: (begin (module main typed/racket (require "type-expander.lp2.rkt" - "../lib/low.rkt") + phc-toolkit) (require (for-syntax racket/syntax syntax/parse diff --git a/graph-lib/type-expander/type-expander-test.rkt b/graph-lib/type-expander/type-expander-test.rkt index fd8bdb3a..9d1e5d64 100644 --- a/graph-lib/type-expander/type-expander-test.rkt +++ b/graph-lib/type-expander/type-expander-test.rkt @@ -4,10 +4,10 @@ (require "type-expander.lp2.rkt" ;(submod "type-expander.lp2.rkt" test) typed/rackunit - "../lib/low.rkt" + phc-toolkit (for-syntax (submod "type-expander.lp2.rkt" expander) racket/list - (submod "../lib/low.rkt" untyped))) + (submod phc-toolkit untyped))) ; Tests for expand-type (begin diff --git a/graph-lib/type-expander/type-expander.lp2.rkt b/graph-lib/type-expander/type-expander.lp2.rkt index 91c5fd87..287d7c24 100644 --- a/graph-lib/type-expander/type-expander.lp2.rkt +++ b/graph-lib/type-expander/type-expander.lp2.rkt @@ -677,7 +677,7 @@ To get around that problem, we define @tc[:] in a separate module, and (module colon typed/racket (require (for-syntax racket syntax/parse) - "../lib/low.rkt") + phc-toolkit) (require (for-syntax (submod ".." expander))) (provide new-:) @@ -698,7 +698,7 @@ in a separate module (that will be used only by macros, so it will be written in syntax/parse racket/format syntax/id-table - (submod "../lib/low.rkt" untyped)) + (submod phc-toolkit untyped)) (require (for-template typed/racket)) @@ -727,8 +727,8 @@ We can finally define the overloaded forms, as well as the extra racket/syntax syntax/parse syntax/parse/experimental/template - (submod "../lib/low.rkt" untyped)) - "../lib/low.rkt") + (submod phc-toolkit untyped)) + phc-toolkit) (require (submod ".." expander)) (require (for-syntax (submod ".." expander)))