diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 8681301a7..903873eb5 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -63,12 +63,14 @@ test: - /^.*-run-dev$/ script: - nix-build nix -A ligo-coverage + - cat result/share/coverage-all - cp -Lr --no-preserve=mode,ownership,timestamps result/share/coverage . artifacts: paths: - coverage -webide-e2e: +# Strange race conditions, disable for now +.webide-e2e: extends: .nix only: - merge_requests diff --git a/gitlab-pages/docs/language-basics/maps-records.md b/gitlab-pages/docs/language-basics/maps-records.md index 5c27f1395..81a26f1be 100644 --- a/gitlab-pages/docs/language-basics/maps-records.md +++ b/gitlab-pages/docs/language-basics/maps-records.md @@ -5,12 +5,12 @@ title: Records and Maps import Syntax from '@theme/Syntax'; -So far we have seen pretty basic data types. LIGO also offers more +So far, we have seen pretty basic data types. LIGO also offers more complex built-in constructs, such as *records* and *maps*. ## Records -Records are one way data of different types can be packed into a +Records are one-way data of different types can be packed into a single type. A record is made of a set of *fields*, which are made of a *field name* and a *field type*. Given a value of a record type, the value bound to a field can be accessed by giving its field name to a @@ -18,8 +18,6 @@ special operator (`.`). Let us first consider and example of record type declaration. - - ```pascaligo group=records1 @@ -55,10 +53,8 @@ type user = { - And here is how a record value is defined: - ```pascaligo group=records1 @@ -142,7 +138,7 @@ points on a plane. In PascaLIGO, the shape of that expression is ` with `. -The record variable is the record to update and the +The record variable is the record to update, and the record value is the update itself. ```pascaligo group=records2 @@ -160,13 +156,13 @@ following command of the shell: ```shell ligo run-function gitlab-pages/docs/language-basics/src/maps-records/record_update.ligo -translate "(record [x=2;y=3;z=1], record [dx=3;dy=4])" +xy_translate "(record [x=2;y=3;z=1], record [dx=3;dy=4])" # Outputs: {z = 1 , y = 7 , x = 5} ``` You have to understand that `p` has not been changed by the functional -update: a namless new version of it has been created and returned by -the blockless function. +update: a nameless new version of it has been created and returned by +the block-less function. @@ -186,6 +182,7 @@ let xy_translate (p, vec : point * vector) : point = You can call the function `xy_translate` defined above by running the following command of the shell: + ```shell ligo run-function gitlab-pages/docs/language-basics/src/maps-records/record_update.mligo @@ -218,6 +215,7 @@ let xy_translate = ((p, vec) : (point, vector)) : point => You can call the function `xy_translate` defined above by running the following command of the shell: + ```shell ligo run-function gitlab-pages/docs/language-basics/src/maps-records/record_update.religo @@ -326,12 +324,21 @@ let change_color_preference = (account : account, color : color): account => Note that all the records in the path will get updated. In this example that's `account` and `preferences`. +You can call the function `change_color_preference` defined above by running the +following command: + +```shell +ligo run-function gitlab-pages/docs/language-basics/src/maps-records/record_nested_update.ligo +change_color_preference "(record [id=1001; preferences=record [color=Blue; other=1]], Green)" +# Outputs: record[id -> 1001 , preferences -> record[color -> Green(unit) , other -> 1]] +``` + ### Record Patches Another way to understand what it means to update a record value is to -make sure that any further reference to the value afterwards will +make sure that any further reference to the value afterward will exhibit the modification. This is called a `patch` and this is only possible in PascaLIGO, because a patch is an *instruction*, therefore we can only use it in a block. Similarly to a *functional update*, a @@ -355,6 +362,7 @@ function xy_translate (var p : point; const vec : vector) : point is You can call the function `xy_translate` defined above by running the following command of the shell: + ```shell ligo run-function gitlab-pages/docs/language-basics/src/maps-records/record_patch.ligo @@ -378,6 +386,7 @@ function xy_translate (var p : point; const vec : vector) : point is You can call the new function `xy_translate` defined above by running the following command of the shell: + ```shell ligo run-function gitlab-pages/docs/language-basics/src/maps-records/record_patch2.ligo @@ -401,6 +410,7 @@ function xy_translate (var p : point; const vec : vector) : point is You can call the new function `xy_translate` defined above by running the following command of the shell: + ```shell ligo run-function gitlab-pages/docs/language-basics/src/maps-records/record_simu.ligo @@ -425,8 +435,6 @@ sense. Here is how a custom map from addresses to a pair of integers is defined. - - ```pascaligo group=maps @@ -680,8 +688,8 @@ let assign = (m : register) : register => (("tz1gjaF81ZRRvdzjobyfVNsAeSC6PScjfQwN" : address), Some ((4,9)), m); ``` -Notice the optional value `Some (4,9)` instead of `(4,9)`. If we had -use `None` instead, that would have meant that the binding is removed. +Notice the optional value `Some (4,9)` instead of `(4,9)`. If we used +`None` instead that would have meant that the binding is removed. As a particular case, we can only add a key and its associated value. @@ -693,7 +701,6 @@ let add = (m : register) : register => - To remove a binding from a map, we need its key. @@ -748,8 +755,8 @@ There are three kinds of functional iterations over LIGO maps: the The first, the *iterated operation*, is an iteration over the map with no return value: its only use is to produce side-effects. This can be -useful if for example you would like to check that each value inside -of a map is within a certain range, and fail with an error otherwise. +useful if, for example you would like to check that each value inside +of a map is within a certain range and fail with an error otherwise. The predefined functional iterator implementing the iterated operation over maps is called `Map.iter`. In the following example, the register @@ -985,7 +992,7 @@ let moves : register = (("tz1gjaF81ZRRvdzjobyfVNsAeSC6PScjfQwN" : address), (0,3))] ``` -The predefind function `Big_map.literal` constructs a big map from a +The predefined function `Big_map.literal` constructs a big map from a list of key-value pairs `(, )`. Note also the semicolon separating individual map entries. The annotated value `(" value>" : address)` means that we cast a string into an address. @@ -1000,7 +1007,7 @@ let moves : register = ("tz1gjaF81ZRRvdzjobyfVNsAeSC6PScjfQwN" : address, (0,3))]); ``` -The predefind function `Big_map.literal` constructs a big map from a +The predefined function `Big_map.literal` constructs a big map from a list of key-value pairs `(, )`. Note also the semicolon separating individual map entries. The annotated value `(" value>" : address)` means that we cast a string into an address. diff --git a/nix/ocaml-overlay.nix b/nix/ocaml-overlay.nix index b44cfdcef..8dd971e79 100644 --- a/nix/ocaml-overlay.nix +++ b/nix/ocaml-overlay.nix @@ -133,19 +133,16 @@ in { echo "Coverage:" BISECT_ENABLE=yes dune runtest --force bisect-ppx-report html -o $out/share/coverage/all --title="LIGO overall test coverage" - bisect-ppx-report summary --per-file + bisect-ppx-report summary --per-file > $out/share/coverage-all echo "Test coverage:" BISECT_ENABLE=yes dune runtest src/test --force bisect-ppx-report html -o $out/share/coverage/ligo --title="LIGO test coverage" - bisect-ppx-report summary --per-file echo "Doc coverage:" BISECT_ENABLE=yes dune build @doc-test --force bisect-ppx-report html -o $out/share/coverage/docs --title="LIGO doc coverage" - bisect-ppx-report summary --per-file echo "CLI test coverage:" BISECT_ENABLE=yes dune runtest src/bin/expect_tests bisect-ppx-report html -o $out/share/coverage/cli --title="CLI test coverage" - bisect-ppx-report summary --per-file ''; installPhase = "true"; }); diff --git a/src/bin/cli.ml b/src/bin/cli.ml index c8da92924..8c3720042 100644 --- a/src/bin/cli.ml +++ b/src/bin/cli.ml @@ -275,7 +275,7 @@ let compile_parameter = let%bind typed_prg,state = Compile.Utils.type_file source_file syntax (Contract entry_point) in let%bind mini_c_prg = Compile.Of_typed.compile typed_prg in let%bind michelson_prg = Compile.Of_mini_c.aggregate_and_compile_contract mini_c_prg entry_point in - let env = Ast_typed.program_environment typed_prg in + let env = Ast_typed.program_environment Environment.default typed_prg in let%bind (_contract: Tezos_utils.Michelson.michelson) = (* fails if the given entry point is not a valid contract *) Compile.Of_michelson.build_contract michelson_prg in @@ -302,7 +302,7 @@ let interpret = | Some init_file -> let%bind typed_prg,state = Compile.Utils.type_file init_file syntax Env in let%bind mini_c_prg = Compile.Of_typed.compile typed_prg in - let env = Ast_typed.program_environment typed_prg in + let env = Ast_typed.program_environment Environment.default typed_prg in ok (mini_c_prg,state,env) | None -> ok ([],Typer.Solver.initial_state,Environment.default) in @@ -344,7 +344,7 @@ let compile_storage = let%bind typed_prg,state = Compile.Utils.type_file source_file syntax (Contract entry_point) in let%bind mini_c_prg = Compile.Of_typed.compile typed_prg in let%bind michelson_prg = Compile.Of_mini_c.aggregate_and_compile_contract mini_c_prg entry_point in - let env = Ast_typed.program_environment typed_prg in + let env = Ast_typed.program_environment Environment.default typed_prg in let%bind (_contract: Tezos_utils.Michelson.michelson) = (* fails if the given entry point is not a valid contract *) Compile.Of_michelson.build_contract michelson_prg in @@ -368,7 +368,7 @@ let dry_run = let f source_file entry_point storage input amount balance sender source predecessor_timestamp syntax display_format = toplevel ~display_format @@ let%bind typed_prg,state = Compile.Utils.type_file source_file syntax (Contract entry_point) in - let env = Ast_typed.program_environment typed_prg in + let env = Ast_typed.program_environment Environment.default typed_prg in let%bind mini_c_prg = Compile.Of_typed.compile typed_prg in let%bind michelson_prg = Compile.Of_mini_c.aggregate_and_compile_contract mini_c_prg entry_point in let%bind (_contract: Tezos_utils.Michelson.michelson) = @@ -398,7 +398,7 @@ let run_function = let f source_file entry_point parameter amount balance sender source predecessor_timestamp syntax display_format = toplevel ~display_format @@ let%bind typed_prg,state = Compile.Utils.type_file source_file syntax Env in - let env = Ast_typed.program_environment typed_prg in + let env = Ast_typed.program_environment Environment.default typed_prg in let%bind mini_c_prg = Compile.Of_typed.compile typed_prg in diff --git a/src/bin/expect_tests/contract_tests.ml b/src/bin/expect_tests/contract_tests.ml index 6de7be144..c52e7c366 100644 --- a/src/bin/expect_tests/contract_tests.ml +++ b/src/bin/expect_tests/contract_tests.ml @@ -7,7 +7,7 @@ let bad_contract basename = let%expect_test _ = run_ligo_good [ "measure-contract" ; contract "coase.ligo" ; "main" ] ; - [%expect {| 1700 bytes |}] ; + [%expect {| 1668 bytes |}] ; run_ligo_good [ "measure-contract" ; contract "multisig.ligo" ; "main" ] ; [%expect {| 995 bytes |}] ; @@ -276,7 +276,7 @@ let%expect_test _ = DIG 7 ; DUP ; DUG 8 ; - NONE (pair (address %card_owner) (nat %card_pattern)) ; + NONE (pair address nat) ; SWAP ; UPDATE ; DIG 2 ; diff --git a/src/bin/expect_tests/michelson_converter.ml b/src/bin/expect_tests/michelson_converter.ml index f1437f44f..b8a6cd90e 100644 --- a/src/bin/expect_tests/michelson_converter.ml +++ b/src/bin/expect_tests/michelson_converter.ml @@ -202,4 +202,121 @@ let%expect_test _ = IF_LEFT { DUP ; CDR ; NIL operation ; PAIR ; DIP { DROP } } { DUP ; CDR ; NIL operation ; PAIR ; DIP { DROP } } ; + DIP { DROP 2 } } } |}] + +let%expect_test _ = + run_ligo_good [ "compile-contract" ; (contract "double_fold_converter.religo") ; "main" ] ; + [%expect {| + { parameter + (list (pair (address %from_) + (list %txs (pair (address %to_) (pair (nat %token_id) (nat %amount)))))) ; + storage (big_map nat address) ; + code { DUP ; + CDR ; + DIG 1 ; + DUP ; + DUG 2 ; + CAR ; + ITER { SWAP ; + PAIR ; + DUP ; + CDR ; + DUP ; + CAR ; + SENDER ; + DIG 1 ; + DUP ; + DUG 2 ; + COMPARE ; + NEQ ; + IF { PUSH string "NOT_OWNER" ; FAILWITH } { PUSH unit Unit } ; + DIG 1 ; + DUP ; + DUG 2 ; + DIG 4 ; + DUP ; + DUG 5 ; + CAR ; + PAIR ; + DIG 3 ; + DUP ; + DUG 4 ; + CDR ; + ITER { SWAP ; + PAIR ; + DUP ; + CAR ; + DIG 1 ; + DUP ; + DUG 2 ; + CDR ; + DIG 1 ; + DUP ; + DUG 2 ; + CAR ; + DIG 2 ; + DUP ; + DUG 3 ; + CDR ; + DIG 2 ; + DUP ; + DUG 3 ; + CDR ; + CAR ; + DIG 3 ; + DUP ; + DUG 4 ; + CAR ; + DIG 4 ; + DUP ; + DUG 5 ; + CDR ; + CDR ; + PAIR ; + PAIR ; + DIG 2 ; + DUP ; + DUG 3 ; + DIG 1 ; + DUP ; + DUG 2 ; + CDR ; + GET ; + IF_NONE + { PUSH string "TOKEN_UNDEFINED" ; FAILWITH } + { DIG 2 ; + DUP ; + DUG 3 ; + DIG 1 ; + DUP ; + DUG 2 ; + COMPARE ; + EQ ; + IF { DUP } { PUSH string "INSUFFICIENT_BALANCE" ; FAILWITH } ; + DIP { DROP } } ; + DIG 2 ; + DUP ; + DUG 3 ; + DIG 4 ; + DUP ; + DUG 5 ; + DIG 3 ; + DUP ; + DUG 4 ; + CAR ; + CDR ; + SOME ; + DIG 4 ; + DUP ; + DUG 5 ; + CDR ; + UPDATE ; + PAIR ; + DIP { DROP 7 } } ; + DUP ; + CAR ; + DIP { DROP 5 } } ; + DUP ; + NIL operation ; + PAIR ; DIP { DROP 2 } } } |}] \ No newline at end of file diff --git a/src/environment/bool.ml b/src/environment/bool.ml index 611c84dfd..d3fea07eb 100644 --- a/src/environment/bool.ml +++ b/src/environment/bool.ml @@ -1,4 +1,8 @@ open Ast_typed open Stage_common.Constant -let environment = env_sum_type ~type_name:t_bool @@ [(Constructor "true",{ctor_type=t_unit ();michelson_annotation=None;ctor_decl_pos=0});(Constructor "false",{ctor_type=t_unit ();michelson_annotation=None;ctor_decl_pos=1})] +let environment = Ast_typed.Environment.add_ez_sum_type ~type_name:t_bool @@ + [ + (Constructor "true" ,{ctor_type=t_unit ();michelson_annotation=None;ctor_decl_pos=0}); + (Constructor "false",{ctor_type=t_unit ();michelson_annotation=None;ctor_decl_pos=1}); + ] diff --git a/src/main/compile/helpers.ml b/src/main/compile/helpers.ml index 9e2019df5..0cb37196d 100644 --- a/src/main/compile/helpers.ml +++ b/src/main/compile/helpers.ml @@ -192,7 +192,7 @@ let pretty_print_pascaligo source = let pretty_print_cameligo source = let%bind ast = Parser.Cameligo.parse_file source in - let doc = Parser_cameligo.Pretty.make ast in + let doc = Parser_cameligo.Pretty.print ast in let buffer = Buffer.create 131 in let width = match Terminal_size.get_columns () with @@ -203,7 +203,7 @@ let pretty_print_cameligo source = let pretty_print_reasonligo source = let%bind ast = Parser.Reasonligo.parse_file source in - let doc = Parser_reasonligo.Pretty.make ast in + let doc = Parser_reasonligo.Pretty.print ast in let buffer = Buffer.create 131 in let width = match Terminal_size.get_columns () with diff --git a/src/passes/1-parser/cameligo.ml b/src/passes/1-parser/cameligo.ml index 9c054400e..7ef89b360 100644 --- a/src/passes/1-parser/cameligo.ml +++ b/src/passes/1-parser/cameligo.ml @@ -157,7 +157,7 @@ let pretty_print source = match parse_file source with Stdlib.Error _ as e -> e | Ok ast -> - let doc = Pretty.make (fst ast) in + let doc = Pretty.print (fst ast) in let buffer = Buffer.create 131 in let width = match Terminal_size.get_columns () with diff --git a/src/passes/1-parser/cameligo/ParserMain.ml b/src/passes/1-parser/cameligo/ParserMain.ml index 60b89c7c3..47462302d 100644 --- a/src/passes/1-parser/cameligo/ParserMain.ml +++ b/src/passes/1-parser/cameligo/ParserMain.ml @@ -78,7 +78,7 @@ let wrap = function Stdlib.Ok ast -> if IO.options#pretty then begin - let doc = Pretty.make ast in + let doc = Pretty.print ast in let width = match Terminal_size.get_columns () with None -> 60 diff --git a/src/passes/1-parser/cameligo/Pretty.ml b/src/passes/1-parser/cameligo/Pretty.ml index 6da2c7bf9..4351b7bad 100644 --- a/src/passes/1-parser/cameligo/Pretty.ml +++ b/src/passes/1-parser/cameligo/Pretty.ml @@ -5,11 +5,13 @@ module Region = Simple_utils.Region open! Region open! PPrint -(*let paragraph (s : string) = flow (break 1) (words s)*) +let pp_par printer {value; _} = + string "(" ^^ nest 1 (printer value.inside ^^ string ")") -let rec make ast = +let rec print ast = let app decl = group (pp_declaration decl) in - separate_map (hardline ^^ hardline) app (Utils.nseq_to_list ast.decl) + let decl = Utils.nseq_to_list ast.decl in + separate_map (hardline ^^ hardline) app decl and pp_declaration = function Let decl -> pp_let_decl decl @@ -90,8 +92,7 @@ and pp_nat {value; _} = and pp_bytes {value; _} = string ("0x" ^ Hex.show (snd value)) -and pp_ppar {value; _} = - string "(" ^^ nest 1 (pp_pattern value.inside ^^ string ")") +and pp_ppar p = pp_par pp_pattern p and pp_plist = function PListComp cmp -> pp_list_comp cmp @@ -345,8 +346,7 @@ and pp_tuple_expr {value; _} = then pp_expr head else pp_expr head ^^ string "," ^^ app (List.map snd tail) -and pp_par_expr {value; _} = - string "(" ^^ nest 1 (pp_expr value.inside ^^ string ")") +and pp_par_expr e = pp_par pp_expr e and pp_let_in {value; _} = let {binding; kwd_rec; body; attributes; _} = value in @@ -425,8 +425,7 @@ and pp_field_decl {value; _} = let t_expr = pp_type_expr field_type in prefix 2 1 (name ^^ string " :") t_expr -and pp_type_app {value; _} = - let ctor, tuple = value in +and pp_type_app {value = ctor, tuple; _} = prefix 2 1 (pp_type_tuple tuple) (pp_type_constr ctor) and pp_type_tuple {value; _} = @@ -449,5 +448,4 @@ and pp_fun_type {value; _} = let lhs, _, rhs = value in group (pp_type_expr lhs ^^ string " ->" ^/^ pp_type_expr rhs) -and pp_type_par {value; _} = - string "(" ^^ nest 1 (pp_type_expr value.inside ^^ string ")") +and pp_type_par t = pp_par pp_type_expr t diff --git a/src/passes/1-parser/cameligo/Scoping.ml b/src/passes/1-parser/cameligo/Scoping.ml index 651306022..e1332b96d 100644 --- a/src/passes/1-parser/cameligo/Scoping.ml +++ b/src/passes/1-parser/cameligo/Scoping.ml @@ -22,7 +22,7 @@ module Ord = struct type t = AST.variable let compare v1 v2 = - compare v1.value v2.value + String.compare v1.value v2.value end module VarSet = Set.Make (Ord) diff --git a/src/passes/1-parser/pascaligo/AST.ml b/src/passes/1-parser/pascaligo/AST.ml index 685d5c5dd..cf6906b69 100644 --- a/src/passes/1-parser/pascaligo/AST.ml +++ b/src/passes/1-parser/pascaligo/AST.ml @@ -106,14 +106,15 @@ type eof = Region.t (* Literals *) -type variable = string reg -type fun_name = string reg -type type_name = string reg -type field_name = string reg -type map_name = string reg -type set_name = string reg -type constr = string reg -type attribute = string reg +type variable = string reg +type fun_name = string reg +type type_name = string reg +type type_constr = string reg +type field_name = string reg +type map_name = string reg +type set_name = string reg +type constr = string reg +type attribute = string reg (* Parentheses *) @@ -181,7 +182,7 @@ and type_expr = TProd of cartesian | TSum of (variant reg, vbar) nsepseq reg | TRecord of field_decl reg ne_injection reg -| TApp of (type_name * type_tuple) reg +| TApp of (type_constr * type_tuple) reg | TFun of (type_expr * arrow * type_expr) reg | TPar of type_expr par reg | TVar of variable @@ -215,17 +216,17 @@ and fun_expr = { } and fun_decl = { - kwd_recursive: kwd_recursive option; - kwd_function : kwd_function; - fun_name : variable; - param : parameters; - colon : colon; - ret_type : type_expr; - kwd_is : kwd_is; - block_with : (block reg * kwd_with) option; - return : expr; - terminator : semi option; - attributes : attr_decl option + kwd_recursive : kwd_recursive option; + kwd_function : kwd_function; + fun_name : variable; + param : parameters; + colon : colon; + ret_type : type_expr; + kwd_is : kwd_is; + block_with : (block reg * kwd_with) option; + return : expr; + terminator : semi option; + attributes : attr_decl option } and parameters = (param_decl, semi) nsepseq par reg @@ -249,19 +250,14 @@ and param_var = { } and block = { - opening : block_opening; + enclosing : block_enclosing; statements : statements; - terminator : semi option; - closing : block_closing + terminator : semi option } -and block_opening = - Block of kwd_block * lbrace -| Begin of kwd_begin - -and block_closing = - Block of rbrace -| End of kwd_end +and block_enclosing = + Block of kwd_block * lbrace * rbrace +| BeginEnd of kwd_begin * kwd_end and statements = (statement, semi) nsepseq @@ -378,10 +374,10 @@ and set_membership = { and 'a case = { kwd_case : kwd_case; expr : expr; - opening : opening; + kwd_of : kwd_of; + enclosing : enclosing; lead_vbar : vbar option; - cases : ('a case_clause reg, vbar) nsepseq reg; - closing : closing + cases : ('a case_clause reg, vbar) nsepseq reg } and 'a case_clause = { @@ -471,34 +467,12 @@ and expr = | EPar of expr par reg | EFun of fun_expr reg -and annot_expr = (expr * type_expr) +and annot_expr = expr * type_expr and set_expr = SetInj of expr injection reg | SetMem of set_membership reg -and 'a injection = { - opening : opening; - elements : ('a, semi) sepseq; - terminator : semi option; - closing : closing -} - -and 'a ne_injection = { - opening : opening; - ne_elements : ('a, semi) nsepseq; - terminator : semi option; - closing : closing -} - -and opening = - Kwd of keyword -| KwdBracket of keyword * lbracket - -and closing = - End of kwd_end -| RBracket of rbracket - and map_expr = MapLookUp of map_lookup reg | MapInj of binding reg injection reg @@ -520,7 +494,7 @@ and logic_expr = and bool_expr = Or of kwd_or bin_op reg | And of kwd_and bin_op reg -| Not of kwd_not un_op reg +| Not of kwd_not un_op reg | False of c_False | True of c_True @@ -544,15 +518,15 @@ and comp_expr = | Neq of neq bin_op reg and arith_expr = - Add of plus bin_op reg -| Sub of minus bin_op reg -| Mult of times bin_op reg -| Div of slash bin_op reg -| Mod of kwd_mod bin_op reg -| Neg of minus un_op reg -| Int of (Lexer.lexeme * Z.t) reg -| Nat of (Lexer.lexeme * Z.t) reg -| Mutez of (Lexer.lexeme * Z.t) reg + Add of plus bin_op reg +| Sub of minus bin_op reg +| Mult of times bin_op reg +| Div of slash bin_op reg +| Mod of kwd_mod bin_op reg +| Neg of minus un_op reg +| Int of (Lexer.lexeme * Z.t) reg +| Nat of (Lexer.lexeme * Z.t) reg +| Mutez of (Lexer.lexeme * Z.t) reg and string_expr = Cat of cat bin_op reg @@ -584,14 +558,14 @@ and projection = { } and update = { - record : path; + record : path; kwd_with : kwd_with; - updates : field_path_assign reg ne_injection reg + updates : field_path_assign reg ne_injection reg } and field_path_assign = { - field_path : (field_name, dot) nsepseq; - equal : equal; + field_path : (field_name, dot) nsepseq; + equal : equal; field_expr : expr } @@ -605,6 +579,38 @@ and fun_call = (expr * arguments) reg and arguments = tuple_expr +(* Injections *) + +and 'a injection = { + kind : injection_kwd; + enclosing : enclosing; + elements : ('a, semi) sepseq; + terminator : semi option +} + +and injection_kwd = + InjSet of keyword +| InjMap of keyword +| InjBigMap of keyword +| InjList of keyword + +and enclosing = + Brackets of lbracket * rbracket +| End of kwd_end + +and 'a ne_injection = { + kind : ne_injection_kwd; + enclosing : enclosing; + ne_elements : ('a, semi) nsepseq; + terminator : semi option +} + +and ne_injection_kwd = + NEInjAttr of keyword +| NEInjSet of keyword +| NEInjMap of keyword +| NEInjRecord of keyword + (* Patterns *) and pattern = @@ -635,7 +641,7 @@ and list_pattern = | PCons of (pattern, cons) nsepseq reg -(* Projecting regions *) +(* PROJECTING REGIONS *) let rec last to_region = function [] -> Region.ghost diff --git a/src/passes/1-parser/pascaligo/Parser.mly b/src/passes/1-parser/pascaligo/Parser.mly index 669ee7dbd..753354cfd 100644 --- a/src/passes/1-parser/pascaligo/Parser.mly +++ b/src/passes/1-parser/pascaligo/Parser.mly @@ -122,7 +122,8 @@ attr_decl: open_attr_decl ";"? { $1 } open_attr_decl: - ne_injection("attributes","") { $1 } + ne_injection("attributes","") { + $1 (fun region -> NEInjAttr region) } (* Type declarations *) @@ -214,19 +215,19 @@ record_type: let () = Utils.nsepseq_to_list ne_elements |> Scoping.check_fields in let region = cover $1 $3 - and value = {opening = Kwd $1; + and value = {kind = NEInjRecord $1; + enclosing = End $3; ne_elements; - terminator; - closing = End $3} + terminator} in TRecord {region; value} } | "record" "[" sep_or_term_list(field_decl,";") "]" { let ne_elements, terminator = $3 in let region = cover $1 $4 - and value = {opening = KwdBracket ($1,$2); + and value = {kind = NEInjRecord $1; + enclosing = Brackets ($2,$4); ne_elements; - terminator; - closing = RBracket $4} + terminator} in TRecord {region; value} } field_decl: @@ -238,7 +239,7 @@ field_decl: fun_expr: - | ioption ("recursive") "function" parameters ":" type_expr "is" expr { + ioption ("recursive") "function" parameters ":" type_expr "is" expr { let stop = expr_to_region $7 in let region = cover $2 stop and value = {kwd_recursive= $1; @@ -271,7 +272,8 @@ open_fun_decl: attributes = None} in {region; value} } -| ioption ("recursive") "function" fun_name parameters ":" type_expr "is" expr { +| ioption ("recursive") "function" fun_name parameters ":" type_expr "is" + expr { Scoping.check_reserved_name $3; let stop = expr_to_region $8 in let region = cover $2 stop @@ -326,19 +328,17 @@ block: "begin" sep_or_term_list(statement,";") "end" { let statements, terminator = $2 in let region = cover $1 $3 - and value = {opening = Begin $1; + and value = {enclosing = BeginEnd ($1,$3); statements; - terminator; - closing = End $3} + terminator} in {region; value} } | "block" "{" sep_or_term_list(statement,";") "}" { let statements, terminator = $3 in let region = cover $1 $4 - and value = {opening = Block ($1,$2); + and value = {enclosing = Block ($1,$2,$4); statements; - terminator; - closing = Block $4} + terminator} in {region; value} } statement: @@ -404,124 +404,122 @@ instruction: set_remove: "remove" expr "from" "set" path { let region = cover $1 (path_to_region $5) in - let value = { - kwd_remove = $1; - element = $2; - kwd_from = $3; - kwd_set = $4; - set = $5} + let value = {kwd_remove = $1; + element = $2; + kwd_from = $3; + kwd_set = $4; + set = $5} in {region; value} } map_remove: "remove" expr "from" "map" path { let region = cover $1 (path_to_region $5) in - let value = { - kwd_remove = $1; - key = $2; - kwd_from = $3; - kwd_map = $4; - map = $5} + let value = {kwd_remove = $1; + key = $2; + kwd_from = $3; + kwd_map = $4; + map = $5} in {region; value} } set_patch: "patch" path "with" ne_injection("set",expr) { - let region = cover $1 $4.region in - let value = { - kwd_patch = $1; - path = $2; - kwd_with = $3; - set_inj = $4} + let set_inj = $4 (fun region -> NEInjSet region) in + let region = cover $1 set_inj.region in + let value = {kwd_patch = $1; + path = $2; + kwd_with = $3; + set_inj} in {region; value} } map_patch: "patch" path "with" ne_injection("map",binding) { - let region = cover $1 $4.region in - let value = { - kwd_patch = $1; - path = $2; - kwd_with = $3; - map_inj = $4} + let map_inj = $4 (fun region -> NEInjMap region) in + let region = cover $1 map_inj.region in + let value = {kwd_patch = $1; + path = $2; + kwd_with = $3; + map_inj} in {region; value} } injection(Kind,element): Kind sep_or_term_list(element,";") "end" { - let elements, terminator = $2 in - let region = cover $1 $3 - and value = { - opening = Kwd $1; - elements = Some elements; - terminator; - closing = End $3} - in {region; value} + fun mk_kwd -> + let elements, terminator = $2 in + let region = cover $1 $3 + and value = { + kind = mk_kwd $1; + enclosing = End $3; + elements = Some elements; + terminator} + in {region; value} } | Kind "end" { - let region = cover $1 $2 - and value = { - opening = Kwd $1; - elements = None; - terminator = None; - closing = End $2} - in {region; value} + fun mk_kwd -> + let region = cover $1 $2 + and value = {kind = mk_kwd $1; + enclosing = End $2; + elements = None; + terminator = None} + in {region; value} } | Kind "[" sep_or_term_list(element,";") "]" { - let elements, terminator = $3 in - let region = cover $1 $4 - and value = { - opening = KwdBracket ($1,$2); - elements = Some elements; - terminator; - closing = RBracket $4} - in {region; value} + fun mk_kwd -> + let elements, terminator = $3 in + let region = cover $1 $4 + and value = {kind = mk_kwd $1; + enclosing = Brackets ($2,$4); + elements = Some elements; + terminator} + in {region; value} } | Kind "[" "]" { - let region = cover $1 $3 - and value = { - opening = KwdBracket ($1,$2); - elements = None; - terminator = None; - closing = RBracket $3} - in {region; value} } + fun mk_kwd -> + let region = cover $1 $3 + and value = {kind = mk_kwd $1; + enclosing = Brackets ($2,$3); + elements = None; + terminator = None} + in {region; value} } ne_injection(Kind,element): Kind sep_or_term_list(element,";") "end" { - let ne_elements, terminator = $2 in - let region = cover $1 $3 - and value = { - opening = Kwd $1; - ne_elements; - terminator; - closing = End $3} - in {region; value} + fun mk_kwd -> + let ne_elements, terminator = $2 in + let region = cover $1 $3 + and value = {kind = mk_kwd $1; + enclosing = End $3; + ne_elements; + terminator} + in {region; value} } | Kind "[" sep_or_term_list(element,";") "]" { - let ne_elements, terminator = $3 in - let region = cover $1 $4 - and value = { - opening = KwdBracket ($1,$2); - ne_elements; - terminator; - closing = RBracket $4} - in {region; value} } + fun mk_kwd -> + let ne_elements, terminator = $3 in + let region = cover $1 $4 + and value = {kind = mk_kwd $1; + enclosing = Brackets ($2,$4); + ne_elements; + terminator} + in {region; value} } binding: expr "->" expr { let start = expr_to_region $1 and stop = expr_to_region $3 in let region = cover start stop - and value = { - source = $1; - arrow = $2; - image = $3} + and value = {source = $1; + arrow = $2; + image = $3} in {region; value} } record_patch: "patch" path "with" ne_injection("record",field_assignment) { - let region = cover $1 $4.region in - let value = { - kwd_patch = $1; - path = $2; - kwd_with = $3; - record_inj = $4} + let record_inj = $4 (fun region -> NEInjRecord region) in + let region = cover $1 record_inj.region in + let value = {kwd_patch = $1; + path = $2; + kwd_with = $3; + record_inj} in {region; value} } proc_call: @@ -547,12 +545,9 @@ if_clause: clause_block: block { LongBlock $1 } | "{" sep_or_term_list(statement,";") "}" { - let statements, terminator = $2 in let region = cover $1 $3 in - let value = {lbrace = $1; - inside = statements, terminator; - rbrace = $3} in - ShortBlock {value; region} } + let value = {lbrace=$1; inside=$2; rbrace=$3} + in ShortBlock {value; region} } case_instr: case(if_clause) { $1 if_clause_to_region } @@ -563,10 +558,10 @@ case(rhs): let region = cover $1 $6 in let value = {kwd_case = $1; expr = $2; - opening = Kwd $3; + kwd_of = $3; + enclosing = End $6; lead_vbar = $4; - cases = $5 rhs_to_region; - closing = End $6} + cases = $5 rhs_to_region} in {region; value} } | "case" expr "of" "[" "|"? cases(rhs) "]" { @@ -574,10 +569,10 @@ case(rhs): let region = cover $1 $7 in let value = {kwd_case = $1; expr = $2; - opening = KwdBracket ($3,$4); + kwd_of = $3; + enclosing = Brackets ($4,$7); lead_vbar = $5; - cases = $6 rhs_to_region; - closing = RBracket $7} + cases = $6 rhs_to_region} in {region; value} } cases(rhs): @@ -904,12 +899,17 @@ annot_expr: in {region; value} } set_expr: - injection("set",expr) { SetInj $1 } + injection("set",expr) { SetInj ($1 (fun region -> InjSet region)) } map_expr: - map_lookup { MapLookUp $1 } -| injection("map",binding) { MapInj $1 } -| injection("big_map",binding) { BigMapInj $1 } + map_lookup { + MapLookUp $1 + } +| injection("map",binding) { + MapInj ($1 (fun region -> InjMap region)) + } +| injection("big_map",binding) { + BigMapInj ($1 (fun region -> InjBigMap region)) } map_lookup: path brackets(expr) { @@ -958,26 +958,27 @@ record_expr: let ne_elements, terminator = $2 in let region = cover $1 $3 and value : field_assign AST.reg ne_injection = { - opening = Kwd $1; + kind = NEInjRecord $1; + enclosing = End $3; ne_elements; - terminator; - closing = End $3} + terminator} in {region; value} } | "record" "[" sep_or_term_list(field_assignment,";") "]" { - let ne_elements, terminator = $3 in - let region = cover $1 $4 - and value : field_assign AST.reg ne_injection = { - opening = KwdBracket ($1,$2); - ne_elements; - terminator; - closing = RBracket $4} - in {region; value} } + let ne_elements, terminator = $3 in + let region = cover $1 $4 + and value : field_assign AST.reg ne_injection = { + kind = NEInjRecord $1; + enclosing = Brackets ($2,$4); + ne_elements; + terminator} + in {region; value} } update_record: - path "with" ne_injection("record",field_path_assignment){ - let region = cover (path_to_region $1) $3.region in - let value = {record=$1; kwd_with=$2; updates=$3} + path "with" ne_injection("record",field_path_assignment) { + let updates = $3 (fun region -> NEInjRecord region) in + let region = cover (path_to_region $1) updates.region in + let value = {record=$1; kwd_with=$2; updates} in {region; value} } field_assignment: @@ -1010,8 +1011,8 @@ arguments: par(nsepseq(expr,",")) { $1 } list_expr: - injection("list",expr) { EListComp $1 } -| "nil" { ENil $1 } + injection("list",expr) { EListComp ($1 (fun region -> InjList region)) } +| "nil" { ENil $1 } (* Patterns *) @@ -1034,9 +1035,10 @@ core_pattern: | constr_pattern { PConstr $1 } list_pattern: - injection("list",core_pattern) { PListComp $1 } -| "nil" { PNil $1 } + "nil" { PNil $1 } | par(cons_pattern) { PParCons $1 } +| injection("list",core_pattern) { + PListComp ($1 (fun region -> InjList region)) } cons_pattern: core_pattern "#" pattern { $1,$2,$3 } diff --git a/src/passes/1-parser/pascaligo/ParserLog.ml b/src/passes/1-parser/pascaligo/ParserLog.ml index eb694f48b..6ae1ca0ac 100644 --- a/src/passes/1-parser/pascaligo/ParserLog.ml +++ b/src/passes/1-parser/pascaligo/ParserLog.ml @@ -27,11 +27,11 @@ let mk_state ~offsets ~mode ~buffer = val pad_node = "" method pad_node = pad_node - (** The method [pad] updates the current padding, which is - comprised of two components: the padding to reach the new node - (space before reaching a subtree, then a vertical bar for it) - and the padding for the new node itself (Is it the last child - of its parent?). + (* The method [pad] updates the current padding, which is + comprised of two components: the padding to reach the new node + (space before reaching a subtree, then a vertical bar for it) + and the padding for the new node itself (Is it the last child + of its parent?). *) method pad arity rank = {< pad_path = @@ -44,7 +44,7 @@ let mk_state ~offsets ~mode ~buffer = let compact state (region: Region.t) = region#compact ~offsets:state#offsets state#mode -(** {1 Printing the tokens with their source regions} *) +(* Printing the tokens with their source regions *) let print_nsepseq : state -> string -> (state -> 'a -> unit) -> @@ -117,7 +117,7 @@ let rec print_tokens state ast = print_token state eof "EOF" and print_attr_decl state = - print_ne_injection state "attributes" print_string + print_ne_injection state print_string and print_decl state = function TypeDecl decl -> print_type_decl state decl @@ -170,8 +170,8 @@ and print_variant state ({value; _}: variant reg) = and print_sum_type state {value; _} = print_nsepseq state "|" print_variant value -and print_record_type state record_type = - print_ne_injection state "record" print_field_decl record_type +and print_record_type state = + print_ne_injection state print_field_decl and print_type_app state {value; _} = let type_name, type_tuple = value in @@ -256,22 +256,19 @@ and print_param_var state {value; _} = print_type_expr state param_type and print_block state block = - let {opening; statements; terminator; closing} = block.value in - print_block_opening state opening; - print_statements state statements; - print_terminator state terminator; - print_block_closing state closing - -and print_block_opening state = function - Block (kwd_block, lbrace) -> - print_token state kwd_block "block"; - print_token state lbrace "{" -| Begin kwd_begin -> - print_token state kwd_begin "begin" - -and print_block_closing state = function - Block rbrace -> print_token state rbrace "}" -| End kwd_end -> print_token state kwd_end "end" + let {enclosing; statements; terminator} = block.value in + match enclosing with + Block (kwd_block, lbrace, rbrace) -> + print_token state kwd_block "block"; + print_token state lbrace "{"; + print_statements state statements; + print_terminator state terminator; + print_token state rbrace "}" + | BeginEnd (kwd_begin, kwd_end) -> + print_token state kwd_begin "begin"; + print_statements state statements; + print_terminator state terminator; + print_token state kwd_end "end" and print_data_decl state = function LocalConst decl -> print_const_decl state decl @@ -344,14 +341,20 @@ and print_clause_block state = function print_token state rbrace "}" and print_case_instr state (node : if_clause case) = - let {kwd_case; expr; opening; - lead_vbar; cases; closing} = node in + let {kwd_case; expr; kwd_of; enclosing; lead_vbar; cases} = node in print_token state kwd_case "case"; print_expr state expr; - print_opening state "of" opening; - print_token_opt state lead_vbar "|"; - print_cases_instr state cases; - print_closing state closing + print_token state kwd_of "of"; + match enclosing with + Brackets (lbracket, rbracket) -> + print_token state lbracket "["; + print_token_opt state lead_vbar "|"; + print_cases_instr state cases; + print_token state rbracket "]" + | End kwd_end -> + print_token_opt state lead_vbar "|"; + print_cases_instr state cases; + print_token state kwd_end "end" and print_token_opt state = function None -> fun _ -> () @@ -466,14 +469,20 @@ and print_annot_expr state (expr , type_expr) = print_type_expr state type_expr and print_case_expr state (node : expr case) = - let {kwd_case; expr; opening; - lead_vbar; cases; closing} = node in + let {kwd_case; expr; kwd_of; enclosing; lead_vbar; cases} = node in print_token state kwd_case "case"; print_expr state expr; - print_opening state "of" opening; - print_token_opt state lead_vbar "|"; - print_cases_expr state cases; - print_closing state closing + print_token state kwd_of "of"; + match enclosing with + Brackets (lbracket, rbracket) -> + print_token state lbracket "["; + print_token_opt state lead_vbar "|"; + print_cases_expr state cases; + print_token state rbracket "]" + | End kwd_end -> + print_token_opt state lead_vbar "|"; + print_cases_expr state cases; + print_token state kwd_end "end" and print_cases_expr state {value; _} = print_nsepseq state "|" print_case_clause_expr value @@ -486,11 +495,11 @@ and print_case_clause_expr state {value; _} = and print_map_expr state = function MapLookUp {value; _} -> print_map_lookup state value -| MapInj inj -> print_injection state "map" print_binding inj -| BigMapInj inj -> print_injection state "big_map" print_binding inj +| MapInj inj -> print_injection state print_binding inj +| BigMapInj inj -> print_injection state print_binding inj and print_set_expr state = function - SetInj inj -> print_injection state "set" print_expr inj + SetInj inj -> print_injection state print_expr inj | SetMem mem -> print_set_membership state mem and print_set_membership state {value; _} = @@ -600,7 +609,7 @@ and print_list_expr state = function print_expr state arg1; print_token state op "#"; print_expr state arg2 -| EListComp e -> print_injection state "list" print_expr e +| EListComp e -> print_injection state print_expr e | ENil e -> print_nil state e and print_constr_expr state = function @@ -608,8 +617,8 @@ and print_constr_expr state = function | NoneExpr e -> print_none_expr state e | ConstrApp e -> print_constr_app state e -and print_record_expr state e = - print_ne_injection state "record" print_field_assign e +and print_record_expr state = + print_ne_injection state print_field_assign and print_field_assign state {value; _} = let {field_name; equal; field_expr} = value in @@ -627,8 +636,7 @@ and print_update_expr state {value; _} = let {record; kwd_with; updates} = value in print_path state record; print_token state kwd_with "with"; - print_ne_injection state "updates field" print_field_path_assign updates - + print_ne_injection state print_field_path_assign updates and print_projection state {value; _} = let {struct_name; selector; field_path} = value in @@ -648,21 +656,21 @@ and print_record_patch state node = print_token state kwd_patch "patch"; print_path state path; print_token state kwd_with "with"; - print_ne_injection state "record" print_field_assign record_inj + print_ne_injection state print_field_assign record_inj and print_set_patch state node = let {kwd_patch; path; kwd_with; set_inj} = node in print_token state kwd_patch "patch"; print_path state path; print_token state kwd_with "with"; - print_ne_injection state "set" print_expr set_inj + print_ne_injection state print_expr set_inj and print_map_patch state node = let {kwd_patch; path; kwd_with; map_inj} = node in print_token state kwd_patch "patch"; print_path state path; print_token state kwd_with "with"; - print_ne_injection state "map" print_binding map_inj + print_ne_injection state print_binding map_inj and print_map_remove state node = let {kwd_remove; key; kwd_from; kwd_map; map} = node in @@ -681,35 +689,48 @@ and print_set_remove state node = print_path state set and print_injection : - 'a.state -> string -> (state -> 'a -> unit) -> - 'a injection reg -> unit = - fun state kwd print {value; _} -> - let {opening; elements; terminator; closing} = value in - print_opening state kwd opening; - print_sepseq state ";" print elements; - print_terminator state terminator; - print_closing state closing + 'a.state -> (state -> 'a -> unit) -> 'a injection reg -> unit = + fun state print {value; _} -> + let {kind; enclosing; elements; terminator} = value in + print_injection_kwd state kind; + match enclosing with + Brackets (lbracket, rbracket) -> + print_token state lbracket "["; + print_sepseq state ";" print elements; + print_terminator state terminator; + print_token state rbracket "]" + | End kwd_end -> + print_sepseq state ";" print elements; + print_terminator state terminator; + print_token state kwd_end "end" + +and print_injection_kwd state = function + InjSet kwd_set -> print_token state kwd_set "set" +| InjMap kwd_map -> print_token state kwd_map "map" +| InjBigMap kwd_big_map -> print_token state kwd_big_map "big_map" +| InjList kwd_list -> print_token state kwd_list "list" and print_ne_injection : - 'a.state -> string -> (state -> 'a -> unit) -> - 'a ne_injection reg -> unit = - fun state kwd print {value; _} -> - let {opening; ne_elements; terminator; closing} = value in - print_opening state kwd opening; - print_nsepseq state ";" print ne_elements; - print_terminator state terminator; - print_closing state closing + 'a.state -> (state -> 'a -> unit) -> 'a ne_injection reg -> unit = + fun state print {value; _} -> + let {kind; enclosing; ne_elements; terminator} = value in + print_ne_injection_kwd state kind; + match enclosing with + Brackets (lbracket, rbracket) -> + print_token state lbracket "["; + print_nsepseq state ";" print ne_elements; + print_terminator state terminator; + print_token state rbracket "]" + | End kwd_end -> + print_nsepseq state ";" print ne_elements; + print_terminator state terminator; + print_token state kwd_end "end" -and print_opening state lexeme = function - Kwd kwd -> - print_token state kwd lexeme -| KwdBracket (kwd, lbracket) -> - print_token state kwd lexeme; - print_token state lbracket "[" - -and print_closing state = function - RBracket rbracket -> print_token state rbracket "]" -| End kwd_end -> print_token state kwd_end "end" +and print_ne_injection_kwd state = function + NEInjAttr kwd_attributes -> print_token state kwd_attributes "attributes" +| NEInjSet kwd_set -> print_token state kwd_set "set" +| NEInjMap kwd_map -> print_token state kwd_map "map" +| NEInjRecord kwd_record -> print_token state kwd_record "record" and print_binding state {value; _} = let {source; arrow; image} = value in @@ -787,7 +808,7 @@ and print_patterns state {value; _} = and print_list_pattern state = function PListComp comp -> - print_injection state "list" print_pattern comp + print_injection state print_pattern comp | PNil kwd_nil -> print_token state kwd_nil "nil" | PParCons cons -> @@ -831,7 +852,7 @@ let pattern_to_string ~offsets ~mode = let instruction_to_string ~offsets ~mode = to_string ~offsets ~mode print_instruction -(** {1 Pretty-printing the AST} *) +(* Pretty-printing the AST *) let pp_ident state {value=name; region} = let reg = compact state region in @@ -952,8 +973,8 @@ and pp_type_expr state = function let fields = Utils.nsepseq_to_list value.ne_elements in List.iteri (List.length fields |> apply) fields | TString s -> - pp_node state "TString"; - pp_string (state#pad 1 0) s + pp_node state "TString"; + pp_string (state#pad 1 0) s and pp_cartesian state {value; _} = let apply len rank = diff --git a/src/passes/1-parser/pascaligo/ParserMain.ml b/src/passes/1-parser/pascaligo/ParserMain.ml index f0485222b..65533dc14 100644 --- a/src/passes/1-parser/pascaligo/ParserMain.ml +++ b/src/passes/1-parser/pascaligo/ParserMain.ml @@ -75,9 +75,23 @@ module Unit = (* Main *) let wrap = function - Stdlib.Ok _ -> flush_all () + Stdlib.Ok ast -> + if IO.options#pretty then + begin + let doc = Pretty.print ast in + let width = + match Terminal_size.get_columns () with + None -> 60 + | Some c -> c in + PPrint.ToChannel.pretty 1.0 width stdout doc; + print_newline () + end; + flush_all () | Error msg -> - (flush_all (); Printf.eprintf "\027[31m%s\027[0m%!" msg.Region.value) + begin + flush_all (); + Printf.eprintf "\027[31m%s\027[0m%!" msg.Region.value + end let () = match IO.options#input with diff --git a/src/passes/1-parser/pascaligo/Pretty.ml b/src/passes/1-parser/pascaligo/Pretty.ml new file mode 100644 index 000000000..442532393 --- /dev/null +++ b/src/passes/1-parser/pascaligo/Pretty.ml @@ -0,0 +1,500 @@ +[@@@warning "-42"] +[@@@warning "-27"] +[@@@warning "-26"] + +open AST +module Region = Simple_utils.Region +open! Region +open! PPrint + +let pp_par (printer: 'a -> document) ({value; _} : 'a par reg) = + string "(" ^^ nest 1 (printer value.inside ^^ string ")") + +let rec print ast = + let app decl = group (pp_declaration decl) in + let decl = Utils.nseq_to_list ast.decl in + separate_map (hardline ^^ hardline) app decl + +and pp_declaration = function + TypeDecl d -> pp_type_decl d +| ConstDecl d -> pp_const_decl d +| FunDecl d -> pp_fun_decl d +| AttrDecl d -> pp_attr_decl d + +and pp_attr_decl decl = pp_ne_injection pp_string decl + +and pp_const_decl {value; _} = + let {name; const_type; init; attributes; _} = value in + let start = string ("const " ^ name.value ^ " :") in + let t_expr = pp_type_expr const_type in + let attr = match attributes with + None -> empty + | Some a -> hardline ^^ pp_attr_decl a + in prefix 2 1 start t_expr + ^/^ prefix 2 1 (string "=") (pp_expr init) + ^^ attr + +(* Type declarations *) + +and pp_type_decl decl = + let {name; type_expr; _} = decl.value in + string "type " ^^ string name.value ^^ string " is" + ^^ group (nest 2 (break 1 ^^ pp_type_expr type_expr)) + +and pp_type_expr = function + TProd t -> pp_cartesian t +| TSum t -> pp_variants t +| TRecord t -> pp_fields t +| TApp t -> pp_type_app t +| TFun t -> pp_fun_type t +| TPar t -> pp_type_par t +| TVar t -> pp_ident t +| TString s -> pp_string s + +and pp_cartesian {value; _} = + let head, tail = value in + let rec app = function + [] -> empty + | [e] -> group (break 1 ^^ pp_type_expr e) + | e::items -> + group (break 1 ^^ pp_type_expr e ^^ string " *") ^^ app items + in pp_type_expr head ^^ string " *" ^^ app (List.map snd tail) + +and pp_variants {value; _} = + let head, tail = value in + let head = pp_variant head in + let head = if tail = [] then head + else ifflat head (string " " ^^ head) in + let rest = List.map snd tail in + let app variant = break 1 ^^ string "| " ^^ pp_variant variant + in head ^^ concat_map app rest + +and pp_variant {value; _} = + let {constr; arg} = value in + match arg with + None -> pp_ident constr + | Some (_, e) -> + prefix 4 1 (pp_ident constr ^^ string " of") (pp_type_expr e) + +and pp_fields fields = pp_ne_injection pp_field_decl fields + +and pp_field_decl {value; _} = + let {field_name; field_type; _} = value in + let name = pp_ident field_name in + let t_expr = pp_type_expr field_type + in prefix 2 1 (name ^^ string " :") t_expr + +and pp_fun_type {value; _} = + let lhs, _, rhs = value in + group (pp_type_expr lhs ^^ string " ->" ^/^ pp_type_expr rhs) + +and pp_type_par t = pp_par pp_type_expr t + +and pp_type_app {value = ctor, tuple; _} = + prefix 2 1 (pp_type_constr ctor) (pp_type_tuple tuple) + +and pp_type_constr ctor = string ctor.value + +and pp_type_tuple {value; _} = + let head, tail = value.inside in + let rec app = function + [] -> empty + | [e] -> group (break 1 ^^ pp_type_expr e) + | e::items -> + group (break 1 ^^ pp_type_expr e ^^ string ",") ^^ app items in + let components = + if tail = [] + then pp_type_expr head + else pp_type_expr head ^^ string "," ^^ app (List.map snd tail) + in string "(" ^^ nest 1 (components ^^ string ")") + +(* Function and procedure declarations *) + +and pp_fun_expr {value; _} = string "TODO:pp_fun_expr" + +and pp_fun_decl {value; _} = + let {kwd_recursive; fun_name; param; + ret_type; block_with; return; attributes; _} = value in + let start = + match kwd_recursive with + None -> string "function" + | Some _ -> string "recursive" ^/^ string "function" in + let parameters = pp_par pp_parameters param in + let return_t = pp_type_expr ret_type in + let blk_opening, blk_in, blk_closing = + match block_with with + None -> empty, empty, empty + | Some (b,_) -> + hardline ^^ string "is block [", pp_block b, string "] with " in + let expr = pp_expr return in + let attr = match attributes with + None -> empty + | Some a -> hardline ^^ pp_attr_decl a + in group (start ^^ nest 2 (break 1 ^^ parameters)) + ^/^ string ": " ^^ nest 2 return_t + ^^ blk_opening + ^^ nest 2 (break 0 ^^ blk_in) + ^/^ blk_closing ^^ nest 4 (break 1 ^^ expr) + ^^ attr + +and pp_parameters p = pp_nsepseq ";" pp_param_decl p + +and pp_param_decl = function + ParamConst c -> pp_param_const c +| ParamVar v -> pp_param_var v + +and pp_param_const {value; _} = + let {var; param_type; _} : param_const = value in + let name = string ("const " ^ var.value) in + let t_expr = pp_type_expr param_type + in prefix 2 1 (name ^^ string " :") t_expr + +and pp_param_var {value; _} = + let {var; param_type; _} : param_var = value in + let name = string ("var " ^ var.value) in + let t_expr = pp_type_expr param_type + in prefix 2 1 (name ^^ string " :") t_expr + +and pp_block {value; _} = pp_statements value.statements + +and pp_statements s = pp_nsepseq ";" pp_statement s + +and pp_statement = function + Instr s -> pp_instruction s +| Data s -> pp_data_decl s +| Attr s -> pp_attr_decl s + +and pp_data_decl = function + LocalConst d -> pp_const_decl d +| LocalVar d -> pp_var_decl d +| LocalFun d -> pp_fun_decl d + +and pp_var_decl {value; _} = + let {name; var_type; init; _} = value in + let start = string ("var " ^ name.value ^ " :") in + let t_expr = pp_type_expr var_type + in prefix 2 1 start t_expr + ^/^ prefix 2 1 (string ":=") (pp_expr init) + +and pp_instruction = function + Cond i -> pp_conditional i +| CaseInstr i -> pp_case pp_if_clause i +| Assign i -> pp_assignment i +| Loop i -> pp_loop i +| ProcCall i -> pp_fun_call i +| Skip _ -> string "skip" +| RecordPatch i -> pp_record_patch i +| MapPatch i -> pp_map_patch i +| SetPatch i -> pp_set_patch i +| MapRemove i -> pp_map_remove i +| SetRemove i -> pp_set_remove i + +and pp_set_remove {value; _} = string "TODO:pp_set_remove" + +and pp_map_remove {value; _} = string "TODO:pp_map_remove" + +and pp_set_patch {value; _} = string "TODO:pp_set_patch" + +and pp_map_patch {value; _} = string "TODO:pp_map_patch" + +and pp_binding b = string "TODO:pp_binding" + +and pp_record_patch {value; _} = string "TODO:pp_record_patch" + +and pp_cond_expr {value; _} = string "TODO:pp_cond_expr" + +and pp_conditional {value; _} = + let {test; ifso; ifnot; _} : conditional = value in + let if_then = + string "if " ^^ group (nest 3 (pp_expr test)) ^/^ string "then" + ^^ group (nest 2 (break 1 ^^ pp_if_clause ifso)) in + let if_else = + string "else" ^^ group (nest 2 (break 1 ^^ pp_if_clause ifnot)) + in if_then ^/^ if_else + +and pp_if_clause = function + ClauseInstr i -> pp_instruction i +| ClauseBlock b -> pp_clause_block b + +and pp_clause_block = function + LongBlock b -> pp_block b +| ShortBlock b -> pp_short_block b + +and pp_short_block {value; _} = string "TODO:pp_short_block" + +and pp_set_membership {value; _} = string "TODO:pp_set_membership" + +and pp_case : + 'a.('a -> document) -> 'a case Region.reg -> document = + fun printer {value; _} -> + let {expr; cases; _} = value in + group (string "case " ^^ nest 5 (pp_expr expr) ^/^ string "of") + ^^ hardline ^^ nest 2 (pp_cases printer cases) + +and pp_cases : + 'a.('a -> document) -> + ('a case_clause reg, vbar) Utils.nsepseq Region.reg -> document = + fun printer {value; _} -> + let head, tail = value in + let head = pp_case_clause printer head in + let head = if tail = [] then head + else string " " ^^ head in + let rest = List.map snd tail in + let app clause = + break 1 ^^ string "| " ^^ pp_case_clause printer clause + in head ^^ concat_map app rest + +and pp_case_clause : + 'a.('a -> document) -> 'a case_clause Region.reg -> document = + fun printer clause -> string "TODO:pp_case_clause" + +and pp_assignment {value; _} = + let {lhs; rhs; _} = value in + prefix 2 1 (pp_lhs lhs ^^ string " :=") (pp_expr rhs) + +and pp_lhs : lhs -> document = function + Path p -> pp_path p +| MapPath p -> pp_map_lookup p + +and pp_loop = function + While l -> pp_while_loop l +| For f -> pp_for_loop f + +and pp_while_loop {value; _} = string "TODO:pp_while_loop" + +and pp_for_loop = function + ForInt l -> pp_for_int l +| ForCollect l -> pp_for_collect l + +and pp_for_int {value; _} = string "TODO:pp_for_int" + +and pp_var_assign {value; _} = string "TODO:pp_var_assign" + +and pp_for_collect {value; _} = string "TODO:pp_for_collect" + +and pp_collection = function + Map _ -> string "map" +| Set _ -> string "set" +| List _ -> string "list" + +(* Expressions *) + +and pp_expr = function + ECase e -> pp_case pp_expr e +| ECond e -> pp_cond_expr e +| EAnnot e -> pp_annot_expr e +| ELogic e -> pp_logic_expr e +| EArith e -> pp_arith_expr e +| EString e -> pp_string_expr e +| EList e -> pp_list_expr e +| ESet e -> pp_set_expr e +| EConstr e -> pp_constr_expr e +| ERecord e -> pp_record e +| EProj e -> pp_projection e +| EUpdate e -> pp_update e +| EMap e -> pp_map_expr e +| EVar e -> pp_ident e +| ECall e -> pp_fun_call e +| EBytes e -> pp_bytes e +| EUnit _ -> string "Unit" +| ETuple e -> pp_tuple_expr e +| EPar e -> pp_par pp_expr e +| EFun e -> pp_fun_expr e + +and pp_annot_expr {value; _} = string "TODO:pp_annot_expr" + +and pp_set_expr = function + SetInj inj -> string "TODO:pp_set_expr:SetInj" +| SetMem mem -> string "TODO:pp_set_expr:SetMem" + +and pp_map_expr = function + MapLookUp fetch -> pp_map_lookup fetch +| MapInj inj -> pp_injection pp_binding inj +| BigMapInj inj -> pp_injection pp_binding inj + +and pp_map_lookup {value; _} = string "TODO:pp_map_lookup" + +and pp_path = function + Name v -> pp_ident v +| Path p -> pp_projection p + +and pp_logic_expr = function + BoolExpr e -> pp_bool_expr e +| CompExpr e -> pp_comp_expr e + +and pp_bool_expr = function + Or e -> pp_bin_op "||" e +| And e -> pp_bin_op "&&" e +| Not e -> pp_un_op "not" e +| True _ -> string "true" +| False _ -> string "false" + +and pp_bin_op op {value; _} = + let {arg1; arg2; _} = value + and length = String.length op + 1 in + pp_expr arg1 ^/^ string (op ^ " ") ^^ nest length (pp_expr arg2) + +and pp_un_op op {value; _} = + string (op ^ " ") ^^ pp_expr value.arg + +and pp_comp_expr = function + Lt e -> pp_bin_op "<" e +| Leq e -> pp_bin_op "<=" e +| Gt e -> pp_bin_op ">" e +| Geq e -> pp_bin_op ">=" e +| Equal e -> pp_bin_op "=" e +| Neq e -> pp_bin_op "<>" e + +and pp_arith_expr = function + Add e -> pp_bin_op "+" e +| Sub e -> pp_bin_op "-" e +| Mult e -> pp_bin_op "*" e +| Div e -> pp_bin_op "/" e +| Mod e -> pp_bin_op "mod" e +| Neg e -> string "-" ^^ pp_expr e.value.arg +| Int e -> pp_int e +| Nat e -> pp_nat e +| Mutez e -> pp_mutez e + +and pp_mutez {value; _} = + Z.to_string (snd value) ^ "mutez" |> string + +and pp_string_expr = function + Cat e -> pp_bin_op "^" e +| String e -> pp_string e +| Verbatim e -> pp_verbatim e + +and pp_ident {value; _} = string value + +and pp_string s = string "\"" ^^ pp_ident s ^^ string "\"" + +and pp_verbatim s = string "{|" ^^ pp_ident s ^^ string "|}" + +and pp_list_expr = function + ECons e -> pp_bin_op "#" e +| EListComp e -> group (pp_injection pp_expr e) +| ENil _ -> string "nil" + +and pp_constr_expr = function + SomeApp a -> pp_some_app a +| NoneExpr _ -> string "None" +| ConstrApp a -> pp_constr_app a + +and pp_some_app {value; _} = string "TODO:pp_some_app" + +and pp_constr_app {value; _} = string "TODO:pp_constr_app" + +and pp_field_assign {value; _} = string "TODO:pp_field_assign" + +and pp_record ne_inj = group (pp_ne_injection pp_field_assign ne_inj) + +and pp_projection {value; _} = string "TODO:pp_projection" + +and pp_update {value; _} = string "TODO:pp_update" + +and pp_field_path_assign {value; _} = string "TODO:pp_field_path_assign" + +and pp_selection = function + FieldName _ -> string "TODO:pp_selection:FieldName" +| Component cmp -> cmp.value |> snd |> Z.to_string |> string + +and pp_tuple_expr {value; _} = + let head, tail = value.inside in + let rec app = function + [] -> empty + | [e] -> group (break 1 ^^ pp_expr e) + | e::items -> + group (break 1 ^^ pp_expr e ^^ string ",") ^^ app items in + let components = + if tail = [] + then pp_expr head + else pp_expr head ^^ string "," ^^ app (List.map snd tail) + in string "(" ^^ nest 1 (components ^^ string ")") + +and pp_fun_call {value; _} = + let lambda, arguments = value in + let arguments = pp_tuple_expr arguments in + group (pp_expr lambda ^^ nest 2 (break 1 ^^ arguments)) + +and pp_arguments v = pp_tuple_expr v + +(* Injections *) + +and pp_injection : + 'a.('a -> document) -> 'a injection reg -> document = + fun printer {value; _} -> string "TODO:pp_injection" + +and pp_ne_injection : + 'a.('a -> document) -> 'a ne_injection reg -> document = + fun printer {value; _} -> + let {kind; enclosing; ne_elements; _} = value in + let elements = pp_nsepseq ";" printer ne_elements in + let kwd = pp_ne_injection_kwd kind in + let offset = String.length kwd + 2 in + string (kwd ^ " [") + ^^ group (nest 2 (break 0 ^^ elements ^^ string "]")) + +and pp_ne_injection_kwd = function + NEInjAttr _ -> "attributes" +| NEInjSet _ -> "set" +| NEInjMap _ -> "map" +| NEInjRecord _ -> "record" + +and pp_nsepseq : + 'a.string -> + ('a -> document) -> + ('a, t) Utils.nsepseq -> + document = + fun sep printer elements -> + let elems = Utils.nsepseq_to_list elements + and sep = string sep ^^ break 1 + in separate_map sep printer elems + +(* Patterns *) + +and pp_pattern = function + PConstr p -> pp_constr_pattern p +| PVar v -> pp_ident v +| PWild _ -> string "_" +| PInt i -> pp_int i +| PNat n -> pp_nat n +| PBytes b -> pp_bytes b +| PString s -> pp_string s +| PList l -> pp_list_pattern l +| PTuple t -> pp_tuple_pattern t + +and pp_int {value; _} = + string (Z.to_string (snd value)) + +and pp_nat {value; _} = + string (Z.to_string (snd value) ^ "n") + +and pp_bytes {value; _} = + string ("0x" ^ Hex.show (snd value)) + +and pp_constr_pattern = function + PUnit _ -> string "Unit" +| PFalse _ -> string "False" +| PTrue _ -> string "True" +| PNone _ -> string "None" +| PSomeApp a -> pp_psome a +| PConstrApp a -> pp_pconstr_app a + +and pp_psome {value=_, p; _} = + prefix 4 1 (string "Some") (pp_par pp_pattern p) + +and pp_pconstr_app {value; _} = string "TODO:pp_pconstr_app" + +and pp_tuple_pattern {value; _} = string "TODO:tuple_pattern" + +and pp_list_pattern = function + PListComp cmp -> pp_list_comp cmp +| PNil _ -> string "nil" +| PParCons p -> pp_ppar_cons p +| PCons p -> pp_nsepseq "#" pp_pattern p.value + +and pp_list_comp {value; _} = string "TODO:pp_list_comp" + +and pp_ppar_cons {value; _} = string "TODO:pp_ppar_cons" + +and pp_cons {value; _} = string "TODO:pp_cons" diff --git a/src/passes/1-parser/pascaligo/Scoping.ml b/src/passes/1-parser/pascaligo/Scoping.ml index 64a8eea52..3fc439efb 100644 --- a/src/passes/1-parser/pascaligo/Scoping.ml +++ b/src/passes/1-parser/pascaligo/Scoping.ml @@ -23,7 +23,7 @@ module Ord = struct type t = AST.variable let compare v1 v2 = - compare v1.value v2.value + String.compare v1.value v2.value end module VarSet = Set.Make (Ord) diff --git a/src/passes/1-parser/pascaligo/dune b/src/passes/1-parser/pascaligo/dune index ca4865ae9..5b2f099ca 100644 --- a/src/passes/1-parser/pascaligo/dune +++ b/src/passes/1-parser/pascaligo/dune @@ -15,8 +15,10 @@ (name parser_pascaligo) (public_name ligo.parser.pascaligo) (modules - Scoping AST pascaligo Parser ParserLog LexToken ParErr) + Scoping AST pascaligo Parser ParserLog LexToken ParErr Pretty) (libraries + pprint + terminal_size menhirLib parser_shared hex diff --git a/src/passes/1-parser/reasonligo.ml b/src/passes/1-parser/reasonligo.ml index ff353412a..dea9eb5a8 100644 --- a/src/passes/1-parser/reasonligo.ml +++ b/src/passes/1-parser/reasonligo.ml @@ -189,7 +189,7 @@ let pretty_print source = match parse_file source with Stdlib.Error _ as e -> e | Ok ast -> - let doc = Pretty.make (fst ast) in + let doc = Pretty.print (fst ast) in let buffer = Buffer.create 131 in let width = match Terminal_size.get_columns () with diff --git a/src/passes/1-parser/reasonligo/Pretty.ml b/src/passes/1-parser/reasonligo/Pretty.ml index ab0a3402d..c4cec4c65 100644 --- a/src/passes/1-parser/reasonligo/Pretty.ml +++ b/src/passes/1-parser/reasonligo/Pretty.ml @@ -7,7 +7,7 @@ open! PPrint (*let paragraph (s : string) = flow (break 1) (words s)*) -let rec make ast = +let rec print ast = let app decl = group (pp_declaration decl) in separate_map (hardline ^^ hardline) app (Utils.nseq_to_list ast.decl) diff --git a/src/passes/10-interpreter/interpreter.ml b/src/passes/10-interpreter/interpreter.ml index c76b464f7..31867602b 100644 --- a/src/passes/10-interpreter/interpreter.ml +++ b/src/passes/10-interpreter/interpreter.ml @@ -368,19 +368,23 @@ and eval : Ast_typed.expression -> env -> value result let dummy : Ast_typed.program -> string result = fun prg -> - let%bind (res,_) = bind_fold_list - (fun (pp,top_env) el -> - let (Ast_typed.Declaration_constant {binder; expr ; inline=_ ; _}) = Location.unwrap el in - let%bind v = - (*TODO This TRY-CATCH is here until we properly implement effects*) - try - eval expr top_env - with Temporary_hack s -> ok @@ V_Failure s - (*TODO This TRY-CATCH is here until we properly implement effects*) - in - let pp' = pp^"\n val "^(Var.to_name binder)^" = "^(Ligo_interpreter.PP.pp_value v) in - let top_env' = Env.extend top_env (binder, v) in - ok @@ (pp',top_env') - ) + let aux (pp,top_env) el = + match Location.unwrap el with + | Ast_typed.Declaration_constant {binder; expr ; inline=_ ; _} -> + let%bind v = + (*TODO This TRY-CATCH is here until we properly implement effects*) + try + eval expr top_env + with Temporary_hack s -> + ok (V_Failure s) + (*TODO This TRY-CATCH is here until we properly implement effects*) + in + let pp' = pp^"\n val "^(Var.to_name binder)^" = "^(Ligo_interpreter.PP.pp_value v) in + let top_env' = Env.extend top_env (binder, v) in + ok @@ (pp',top_env') + | Ast_typed.Declaration_type _ -> + ok (pp , top_env) + in + let%bind (res,_) = bind_fold_list aux ("",Env.empty_env) prg in ok @@ res diff --git a/src/passes/10-transpiler/transpiler.ml b/src/passes/10-transpiler/transpiler.ml index 9c1973f0d..5ea4ea43f 100644 --- a/src/passes/10-transpiler/transpiler.ml +++ b/src/passes/10-transpiler/transpiler.ml @@ -42,14 +42,6 @@ them. please report this to the developers." in ] in error ~data title content - let unsupported_iterator location = - let title () = "unsupported iterator" in - let content () = "only lambda are supported as iterators" in - let data = [ - row_loc location ; - ] in - error ~data title content - let not_functional_main location = let title () = "not functional main" in let content () = "main should be a function" in @@ -382,9 +374,6 @@ let rec transpile_literal : AST.literal -> value = fun l -> match l with | Literal_unit -> D_unit | Literal_void -> D_none -and transpile_environment_element_type : AST.environment_element -> type_expression result = fun ele -> - transpile_type ele.type_value - and tree_of_sum : AST.type_expression -> (AST.constructor' * AST.type_expression) Append_tree.t result = fun t -> let%bind map_tv = get_t_sum t in let kt_list = List.map (fun (k,({ctor_type;_}:AST.ctor_content)) -> (k,ctor_type)) (kv_list_of_cmap map_tv) in @@ -405,11 +394,7 @@ and transpile_annotated_expression (ae:AST.expression) : expression result = return (E_let_in ((let_binder, rhs'.type_expression), inline, rhs', result')) | E_literal l -> return @@ E_literal (transpile_literal l) | E_variable name -> ( - let%bind ele = - trace_option (corner_case ~loc:__LOC__ "name not in environment") @@ - AST.Environment.get_opt name ae.environment in - let%bind tv = transpile_environment_element_type ele in - return ~tv @@ E_variable (name) + return @@ E_variable (name) ) | E_application {lamb; args} -> let%bind a = transpile_annotated_expression lamb in @@ -449,7 +434,6 @@ and transpile_annotated_expression (ae:AST.expression) : expression result = return ~tv ae ) | E_record m -> ( - (*list_of_lmap to record_to_list*) let node = Append_tree.of_list @@ Ast_typed.Helpers.list_of_record_or_tuple m in let aux a b : expression result = let%bind a = a in @@ -511,28 +495,14 @@ and transpile_annotated_expression (ae:AST.expression) : expression result = return @@ E_record_update (record, path, update) | E_constant {cons_name=name; arguments=lst} -> ( let iterator_generator iterator_name = - let lambda_to_iterator_body (f : AST.expression) (l : AST.lambda) = - let%bind body' = transpile_annotated_expression l.result in - let%bind (input , _) = AST.get_t_function f.type_expression in - let%bind input' = transpile_type input in - ok ((l.binder , input') , body') - in let expression_to_iterator_body (f : AST.expression) = - match f.expression_content with - | E_lambda l -> lambda_to_iterator_body f l - | E_variable v -> ( - let%bind elt = - trace_option (corner_case ~loc:__LOC__ "missing var") @@ - AST.Environment.get_opt v f.environment in - match elt.definition with - | ED_declaration { expr = f ; free_variables = _ } -> ( - match f.expression_content with - | E_lambda l -> lambda_to_iterator_body f l - | _ -> fail @@ unsupported_iterator f.location - ) - | _ -> fail @@ unsupported_iterator f.location - ) - | _ -> fail @@ unsupported_iterator f.location + let%bind (input , output) = AST.get_t_function f.type_expression in + let%bind f' = transpile_annotated_expression f in + let%bind input' = transpile_type input in + let%bind output' = transpile_type output in + let binder = Var.fresh ~name:"iterated" () in + let application = Mini_c.Combinators.e_application f' output' (Mini_c.Combinators.e_var binder input') in + ok ((binder , input'), application) in fun (lst : AST.expression list) -> match (lst , iterator_name) with | [f ; i] , C_ITER | [f ; i] , C_MAP -> ( @@ -781,25 +751,29 @@ and transpile_recursive {fun_name; fun_type; lambda} = let body = Expression.make (E_iterator (C_LOOP_LEFT, ((lambda.binder, loop_type),body), expr)) output_type in ok @@ Expression.make (E_closure {binder;body}) fun_type -let transpile_declaration env (d:AST.declaration) : toplevel_statement result = +let transpile_declaration env (d:AST.declaration) : toplevel_statement option result = match d with - | Declaration_constant { binder ; expr ; inline ; post_env=_ } -> + | Declaration_constant { binder ; expr ; inline } -> let%bind expression = transpile_annotated_expression expr in let tv = Combinators.Expression.get_type expression in let env' = Environment.add (binder, tv) env in - ok @@ ((binder, inline, expression), environment_wrap env env') + ok @@ Some ((binder, inline, expression), environment_wrap env env') + | _ -> ok None let transpile_program (lst : AST.program) : program result = let aux (prev:(toplevel_statement list * Environment.t) result) cur = let%bind (hds, env) = prev in - let%bind ((_, env') as cur') = transpile_declaration env cur in - ok (hds @ [ cur' ], env'.post_environment) + match%bind transpile_declaration env cur with + | Some ((_ , env') as cur') -> ok (hds @ [ cur' ] , env'.post_environment) + | None -> ok (hds , env) in let%bind (statements, _) = List.fold_left aux (ok ([], Environment.empty)) (temp_unwrap_loc_list lst) in ok statements (* check whether the storage contains a big_map, if yes, check that - it appears on the left hand side of a pair *) + it appears on the left hand side of a pair + TODO : checking should appears in check_pass. +*) let check_storage f ty loc : (anon_function * _) result = let rec aux (t:type_expression) on_big_map = match t.type_content with diff --git a/src/passes/10-transpiler/untranspiler.ml b/src/passes/10-transpiler/untranspiler.ml index a6864bff9..5f68cddd5 100644 --- a/src/passes/10-transpiler/untranspiler.ml +++ b/src/passes/10-transpiler/untranspiler.ml @@ -42,19 +42,19 @@ open Errors let rec untranspile (v : value) (t : AST.type_expression) : AST.expression result = let open! AST in - let return e = ok (make_a_e_empty e t) in + let return e = ok (make_e e t) in match t.type_content with | T_variable (name) when Var.equal name Stage_common.Constant.t_bool -> ( let%bind b = trace_strong (wrong_mini_c_value "bool" v) @@ get_bool v in - return (e_bool b Environment.empty) + return (e_bool b) ) | t when (compare t (t_bool ()).type_content) = 0-> ( let%bind b = trace_strong (wrong_mini_c_value "bool" v) @@ get_bool v in - return (e_bool b Environment.empty) + return (e_bool b) ) | T_constant type_constant -> ( match type_constant with @@ -152,10 +152,10 @@ let rec untranspile (v : value) (t : AST.type_expression) : AST.expression resul trace_strong (wrong_mini_c_value "option" v) @@ get_option v in match opt with - | None -> ok (e_a_empty_none o) + | None -> ok (e_a_none o) | Some s -> let%bind s' = untranspile s o in - ok (e_a_empty_some s') + ok (e_a_some s') ) | TC_map {k=k_ty;v=v_ty}-> ( let%bind map = diff --git a/src/passes/13-self_michelson/self_michelson.ml b/src/passes/13-self_michelson/self_michelson.ml index 8a3291204..729bd454a 100644 --- a/src/passes/13-self_michelson/self_michelson.ml +++ b/src/passes/13-self_michelson/self_michelson.ml @@ -422,6 +422,56 @@ let rec opt_combine_drops (x : michelson) : michelson = Prim (l, p, List.map opt_combine_drops args, annot) | x -> x +(* number of type arguments for (some) prims, where we will strip + annots *) +let prim_type_args : prim -> int option = function + | I_NONE -> Some 1 + | I_NIL -> Some 1 + | I_EMPTY_SET -> Some 1 + | I_EMPTY_MAP -> Some 2 + | I_EMPTY_BIG_MAP -> Some 2 + | I_LAMBDA -> Some 2 + (* _not_ I_CONTRACT! annot is important there *) + (* but could include I_SELF, maybe? *) + | _ -> None + +(* returns (List.firstn n xs, List.skipn n xs) as in Coq (OCaml stdlib + does not have those...) *) +let split_at (n : int) (xs : 'a list) : 'a list * 'a list = + let rec aux n acc = + if n <= 0 + then acc + else + let (bef, aft) = acc in + match aft with + | [] -> acc + | x :: aft -> + aux (n - 1) (x :: bef, aft) in + let (bef, aft) = aux n ([], xs) in + (List.rev bef, aft) + +(* strip annots from type arguments in some instructions *) +let rec opt_strip_annots (x : michelson) : michelson = + match x with + | Seq (l, args) -> + let args = List.map opt_strip_annots args in + Seq (l, args) + | Prim (l, p, args, annot) -> + begin + match prim_type_args p with + | Some n -> + let (type_args, args) = split_at n args in + (* strip annots from type args *) + let type_args = List.map strip_annots type_args in + (* recur into remaining args *) + let args = List.map opt_strip_annots args in + Prim (l, p, type_args @ args, annot) + | None -> + let args = List.map opt_strip_annots args in + Prim (l, p, args, annot) + end + | x -> x + let optimize : michelson -> michelson = fun x -> let x = use_lambda_instr x in @@ -436,4 +486,5 @@ let optimize : michelson -> michelson = ] in let x = iterate_optimizer (sequence_optimizers optimizers) x in let x = opt_combine_drops x in + let x = opt_strip_annots x in x diff --git a/src/passes/8-typer-new/PP.ml b/src/passes/8-typer-new/PP.ml index b76e55500..c5199f60d 100644 --- a/src/passes/8-typer-new/PP.ml +++ b/src/passes/8-typer-new/PP.ml @@ -2,7 +2,7 @@ open Ast_typed open Format module UF = UnionFind.Poly2 -let type_constraint_ : _ -> type_constraint_simpl_ -> unit = fun ppf -> +let type_constraint_ : _ -> type_constraint_simpl -> unit = fun ppf -> function |SC_Constructor { tv; c_tag; tv_list=_ } -> let ct = match c_tag with @@ -34,8 +34,8 @@ let type_constraint_ : _ -> type_constraint_simpl_ -> unit = fun ppf -> |SC_Poly _ -> fprintf ppf "Poly" |SC_Typeclass _ -> fprintf ppf "TC" -let type_constraint : _ -> type_constraint_simpl -> unit = fun ppf { reason_simpl ; c_simpl } -> - fprintf ppf "%a (reason: %s)" type_constraint_ c_simpl reason_simpl +let type_constraint : _ -> type_constraint_simpl -> unit = fun ppf c -> + fprintf ppf "%a (reason: %s)" type_constraint_ c (reason_simpl c) let all_constraints ppf ac = fprintf ppf "[%a]" (pp_print_list ~pp_sep:(fun ppf () -> fprintf ppf ";\n") type_constraint) ac diff --git a/src/passes/8-typer-new/README b/src/passes/8-typer-new/README new file mode 100644 index 000000000..a84d67214 --- /dev/null +++ b/src/passes/8-typer-new/README @@ -0,0 +1,31 @@ +Components: +* assignments (passive data structure). + Now: just a map from unification vars to types (pb: what about partial types?) + maybe just local assignments (allow only vars as children of pair(α,β)) +* constraint propagation: (buch of constraints) → (new constraints * assignments) + * sub-component: constraint selector (worklist / dynamic queries) + * sub-sub component: constraint normalizer: remove dupes and give structure + right now: union-find of unification vars + later: better database-like organisation of knowledge + * sub-sub component: lazy selector (don't re-try all selectors every time) + For now: just re-try everytime + * sub-component: propagation rule + For now: break pair(a, b) = pair(c, d) into a = c, b = d +* generalizer + For now: ? + +Workflow: + Start with empty assignments and structured database + Receive a new constraint + For each normalizer: + Use the pre-selector to see if it can be applied + Apply the normalizer, get some new items to insert in the structured database + For each propagator: + Use the selector to query the structured database and see if it can be applied + Apply the propagator, get some new constraints and assignments + Add the new assignments to the data structure. + + At some point (when?) + For each generalizer: + Use the generalizer's selector to see if it can be applied + Apply the generalizer to produce a new type, possibly with some ∀s injected diff --git a/src/passes/8-typer-new/constraint_databases.ml b/src/passes/8-typer-new/constraint_databases.ml new file mode 100644 index 000000000..8a121e11d --- /dev/null +++ b/src/passes/8-typer-new/constraint_databases.ml @@ -0,0 +1,69 @@ +module Map = RedBlackTrees.PolyMap +module UF = UnionFind.Poly2 +open Ast_typed.Types + +(* Light wrapper for API for grouped_by_variable in the structured + db, to access it modulo unification variable aliases. *) +let get_constraints_related_to : type_variable -> structured_dbs -> constraints = + fun variable dbs -> + let variable , aliases = UF.get_or_set variable dbs.aliases in + let dbs = { dbs with aliases } in + match Map.find_opt variable dbs.grouped_by_variable with + Some l -> l + | None -> { + constructor = [] ; + poly = [] ; + tc = [] ; + } +let add_constraints_related_to : type_variable -> constraints -> structured_dbs -> structured_dbs = + fun variable c dbs -> + (* let (variable_repr , _height) , aliases = UF.get_or_set variable dbs.aliases in + let dbs = { dbs with aliases } in *) + let variable_repr , aliases = UF.get_or_set variable dbs.aliases in + let dbs = { dbs with aliases } in + let grouped_by_variable = Map.update variable_repr (function + None -> Some c + | Some (x : constraints) -> Some { + constructor = c.constructor @ x.constructor ; + poly = c.poly @ x.poly ; + tc = c.tc @ x.tc ; + }) + dbs.grouped_by_variable + in + let dbs = { dbs with grouped_by_variable } in + dbs + +let merge_constraints : type_variable -> type_variable -> structured_dbs -> structured_dbs = + fun variable_a variable_b dbs -> + (* get old representant for variable_a *) + let variable_repr_a , aliases = UF.get_or_set variable_a dbs.aliases in + let dbs = { dbs with aliases } in + (* get old representant for variable_b *) + let variable_repr_b , aliases = UF.get_or_set variable_b dbs.aliases in + let dbs = { dbs with aliases } in + + (* alias variable_a and variable_b together *) + let aliases = UF.alias variable_a variable_b dbs.aliases in + let dbs = { dbs with aliases } in + + (* Replace the two entries in grouped_by_variable by a single one *) + ( + let get_constraints ab = + match Map.find_opt ab dbs.grouped_by_variable with + | Some x -> x + | None -> { constructor = [] ; poly = [] ; tc = [] } in + let constraints_a = get_constraints variable_repr_a in + let constraints_b = get_constraints variable_repr_b in + let all_constraints = { + constructor = constraints_a.constructor @ constraints_b.constructor ; + poly = constraints_a.poly @ constraints_b.poly ; + tc = constraints_a.tc @ constraints_b.tc ; + } in + let grouped_by_variable = + Map.add variable_repr_a all_constraints dbs.grouped_by_variable in + let dbs = { dbs with grouped_by_variable} in + let grouped_by_variable = + Map.remove variable_repr_b dbs.grouped_by_variable in + let dbs = { dbs with grouped_by_variable} in + dbs + ) diff --git a/src/passes/8-typer-new/heuristic_break_ctor.ml b/src/passes/8-typer-new/heuristic_break_ctor.ml new file mode 100644 index 000000000..e676f2500 --- /dev/null +++ b/src/passes/8-typer-new/heuristic_break_ctor.ml @@ -0,0 +1,52 @@ +(* selector / propagation rule for breaking down composite types + * For now: break pair(a, b) = pair(c, d) into a = c, b = d *) + +open Ast_typed.Misc +open Ast_typed.Types +open Solver_types + +let selector : (type_constraint_simpl, output_break_ctor) selector = + (* find two rules with the shape x = k(var …) and x = k'(var' …) *) + fun type_constraint_simpl dbs -> + match type_constraint_simpl with + SC_Constructor c -> + (* finding other constraints related to the same type variable and + with the same sort of constraint (constructor vs. constructor) + is symmetric *) + let other_cs = (Constraint_databases.get_constraints_related_to c.tv dbs).constructor in + let other_cs = List.filter (fun (o : c_constructor_simpl) -> Var.equal c.tv o.tv) other_cs in + (* TODO double-check the conditions in the propagator, we had a + bug here because the selector was too permissive. *) + let cs_pairs = List.map (fun x -> { a_k_var = c ; a_k'_var' = x }) other_cs in + WasSelected cs_pairs + | SC_Alias _ -> WasNotSelected (* TODO: ??? (beware: symmetry) *) + | SC_Poly _ -> WasNotSelected (* TODO: ??? (beware: symmetry) *) + | SC_Typeclass _ -> WasNotSelected + +let propagator : output_break_ctor propagator = + fun selected dbs -> + let () = ignore (dbs) in (* this propagator doesn't need to use the dbs *) + let a = selected.a_k_var in + let b = selected.a_k'_var' in + + (* The selector is expected to provice two constraints with the shape x = k(var …) and x = k'(var' …) *) + assert (Var.equal (a : c_constructor_simpl).tv (b : c_constructor_simpl).tv); + + (* produce constraints: *) + + (* a.tv = b.tv *) + let eq1 = c_equation { tsrc = "solver: propagator: break_ctor a" ; t = P_variable a.tv} { tsrc = "solver: propagator: break_ctor b" ; t = P_variable b.tv} "propagator: break_ctor" in + (* a.c_tag = b.c_tag *) + if (Solver_should_be_generated.compare_simple_c_constant a.c_tag b.c_tag) <> 0 then + failwith (Format.asprintf "type error: incompatible types, not same ctor %a vs. %a (compare returns %d)" + Solver_should_be_generated.debug_pp_c_constructor_simpl a + Solver_should_be_generated.debug_pp_c_constructor_simpl b + (Solver_should_be_generated.compare_simple_c_constant a.c_tag b.c_tag)) + else + (* a.tv_list = b.tv_list *) + if List.length a.tv_list <> List.length b.tv_list then + failwith "type error: incompatible types, not same length" + else + let eqs3 = List.map2 (fun aa bb -> c_equation { tsrc = "solver: propagator: break_ctor aa" ; t = P_variable aa} { tsrc = "solver: propagator: break_ctor bb" ; t = P_variable bb} "propagator: break_ctor") a.tv_list b.tv_list in + let eqs = eq1 :: eqs3 in + (eqs , []) (* no new assignments *) diff --git a/src/passes/8-typer-new/heuristic_specialize1.ml b/src/passes/8-typer-new/heuristic_specialize1.ml new file mode 100644 index 000000000..6e481fc12 --- /dev/null +++ b/src/passes/8-typer-new/heuristic_specialize1.ml @@ -0,0 +1,53 @@ +(* selector / propagation rule for specializing polymorphic types + * For now: (x = forall y, z) and (x = k'(var' …)) + * produces the new constraint (z[x |-> k'(var' …)]) + * where [from |-> to] denotes substitution. *) + +module Core = Typesystem.Core +open Ast_typed.Misc +open Ast_typed.Types +open Solver_types + +let selector : (type_constraint_simpl, output_specialize1) selector = + (* find two rules with the shape (x = forall b, d) and x = k'(var' …) or vice versa *) + (* TODO: do the same for two rules with the shape (a = forall b, d) and tc(a…) *) + (* TODO: do the appropriate thing for two rules with the shape (a = forall b, d) and (a = forall b', d') *) + fun type_constraint_simpl dbs -> + match type_constraint_simpl with + SC_Constructor c -> + (* vice versa *) + let other_cs = (Constraint_databases.get_constraints_related_to c.tv dbs).poly in + let other_cs = List.filter (fun (x : c_poly_simpl) -> Var.equal c.tv x.tv) other_cs in + let cs_pairs = List.map (fun x -> { poly = x ; a_k_var = c }) other_cs in + WasSelected cs_pairs + | SC_Alias _ -> WasNotSelected (* TODO: ??? *) + | SC_Poly p -> + let other_cs = (Constraint_databases.get_constraints_related_to p.tv dbs).constructor in + let other_cs = List.filter (fun (x : c_constructor_simpl) -> Var.equal x.tv p.tv) other_cs in + let cs_pairs = List.map (fun x -> { poly = p ; a_k_var = x }) other_cs in + WasSelected cs_pairs + | SC_Typeclass _ -> WasNotSelected + +let propagator : output_specialize1 propagator = + fun selected dbs -> + let () = ignore (dbs) in (* this propagator doesn't need to use the dbs *) + let a = selected.poly in + let b = selected.a_k_var in + + (* The selector is expected to provide two constraints with the shape (x = forall y, z) and x = k'(var' …) *) + assert (Var.equal (a : c_poly_simpl).tv (b : c_constructor_simpl).tv); + + (* produce constraints: *) + + (* create a fresh existential variable to instantiate the polymorphic type y *) + let fresh_existential = Core.fresh_type_variable () in + (* Produce the constraint (b.tv = a.body[a.binder |-> fresh_existential]) + The substitution is obtained by immediately applying the forall. *) + let apply = { + tsrc = "solver: propagator: specialize1 apply" ; + t = P_apply { tf = { tsrc = "solver: propagator: specialize1 tf" ; t = P_forall a.forall }; + targ = { tsrc = "solver: propagator: specialize1 targ" ; t = P_variable fresh_existential }} } in + let (reduced, new_constraints) = Typelang.check_applied @@ Typelang.type_level_eval apply in + let eq1 = c_equation { tsrc = "solver: propagator: specialize1 eq1" ; t = P_variable b.tv } reduced "propagator: specialize1" in + let eqs = eq1 :: new_constraints in + (eqs, []) (* no new assignments *) diff --git a/src/passes/8-typer-new/normalizer.ml b/src/passes/8-typer-new/normalizer.ml new file mode 100644 index 000000000..8c391c2d5 --- /dev/null +++ b/src/passes/8-typer-new/normalizer.ml @@ -0,0 +1,126 @@ +module Core = Typesystem.Core +module Map = RedBlackTrees.PolyMap +open Ast_typed.Misc +open Ast_typed.Types +open Solver_types + +(* sub-sub component: constraint normalizer: remove dupes and give structure + * right now: union-find of unification vars + * later: better database-like organisation of knowledge *) + +(* Each normalizer returns an updated database (after storing the + incoming constraint) and a list of constraints, used when the + normalizer rewrites the constraints e.g. into simpler ones. *) +(* TODO: If implemented in a language with decent sets, should be 'b set not 'b list. *) +type ('a , 'b) normalizer = structured_dbs -> 'a -> (structured_dbs * 'b list) + +(** Updates the dbs.all_constraints field when new constraints are + discovered. + + This field contains a list of all the constraints, without any form of + grouping or sorting. *) +let normalizer_all_constraints : (type_constraint_simpl , type_constraint_simpl) normalizer = + fun dbs new_constraint -> + ({ dbs with all_constraints = new_constraint :: dbs.all_constraints } , [new_constraint]) + +(** Updates the dbs.grouped_by_variable field when new constraints are + discovered. + + This field contains a map from type variables to lists of + constraints that are related to that variable (in other words, the + key appears in the equation). + *) +let normalizer_grouped_by_variable : (type_constraint_simpl , type_constraint_simpl) normalizer = + fun dbs new_constraint -> + let store_constraint tvars constraints = + let aux dbs (tvar : type_variable) = + Constraint_databases.add_constraints_related_to tvar constraints dbs + in List.fold_left aux dbs tvars + in + let dbs = match new_constraint with + SC_Constructor ({tv ; c_tag = _ ; tv_list} as c) -> store_constraint (tv :: tv_list) {constructor = [c] ; poly = [] ; tc = []} + | SC_Typeclass ({tc = _ ; args} as c) -> store_constraint args {constructor = [] ; poly = [] ; tc = [c]} + | SC_Poly ({tv; forall = _} as c) -> store_constraint [tv] {constructor = [] ; poly = [c] ; tc = []} + | SC_Alias { a; b } -> Constraint_databases.merge_constraints a b dbs + in (dbs , [new_constraint]) + +(** Stores the first assinment ('a = ctor('b, …)) that is encountered. + + Subsequent ('a = ctor('b2, …)) with the same 'a are ignored. + + TOOD: are we checking somewhere that 'b … = 'b2 … ? *) +let normalizer_assignments : (type_constraint_simpl , type_constraint_simpl) normalizer = + fun dbs new_constraint -> + match new_constraint with + | SC_Constructor ({tv ; c_tag = _ ; tv_list = _} as c) -> + let assignments = Map.update tv (function None -> Some c | e -> e) dbs.assignments in + let dbs = {dbs with assignments} in + (dbs , [new_constraint]) + | _ -> + (dbs , [new_constraint]) + +(* TODO: at some point there may be uses of named type aliases (type + foo = int; let x : foo = 42). These should be inlined. *) + +(** This function converts constraints from type_constraint to + type_constraint_simpl. The former has more possible cases, and the + latter uses a more minimalistic constraint language. + + It does not modify the dbs, and only rewrites the constraint + + TODO: update the code to show that the dbs are always copied as-is + *) +let rec normalizer_simpl : (type_constraint , type_constraint_simpl) normalizer = + fun dbs new_constraint -> + let insert_fresh a b = + let fresh = Core.fresh_type_variable () in + let (dbs , cs1) = normalizer_simpl dbs (c_equation { tsrc = "solver: normalizer: simpl 1" ; t = P_variable fresh } a "normalizer: simpl 1") in + let (dbs , cs2) = normalizer_simpl dbs (c_equation { tsrc = "solver: normalizer: simpl 2" ; t = P_variable fresh } b "normalizer: simpl 2") in + (dbs , cs1 @ cs2) in + let split_constant a c_tag args = + let fresh_vars = List.map (fun _ -> Core.fresh_type_variable ()) args in + let fresh_eqns = List.map (fun (v,t) -> c_equation { tsrc = "solver: normalizer: split_constant" ; t = P_variable v } t "normalizer: split_constant") (List.combine fresh_vars args) in + let (dbs , recur) = List.fold_map_acc normalizer_simpl dbs fresh_eqns in + (dbs , [SC_Constructor {tv=a;c_tag;tv_list=fresh_vars;reason_constr_simpl=Format.asprintf "normalizer: split constant %a = %a (%a)" Var.pp a Ast_typed.PP_generic.constant_tag c_tag (PP_helpers.list_sep Ast_typed.PP_generic.type_value (fun ppf () -> Format.fprintf ppf ", ")) args}] @ List.flatten recur) in + let gather_forall a forall = (dbs , [SC_Poly { tv=a; forall ; reason_poly_simpl="normalizer: gather_forall"}]) in + let gather_alias a b = (dbs , [SC_Alias { a ; b ; reason_alias_simpl="normalizer: gather_alias"}]) in + let reduce_type_app a b = + let (reduced, new_constraints) = Typelang.check_applied @@ Typelang.type_level_eval b in + let (dbs , recur) = List.fold_map_acc normalizer_simpl dbs new_constraints in + let (dbs , resimpl) = normalizer_simpl dbs (c_equation a reduced "normalizer: reduce_type_app") in (* Note: this calls recursively but cant't fall in the same case. *) + (dbs , resimpl @ List.flatten recur) in + let split_typeclass args tc = + let fresh_vars = List.map (fun _ -> Core.fresh_type_variable ()) args in + let fresh_eqns = List.map (fun (v,t) -> c_equation { tsrc = "solver: normalizer: split typeclass" ; t = P_variable v} t "normalizer: split_typeclass") (List.combine fresh_vars args) in + let (dbs , recur) = List.fold_map_acc normalizer_simpl dbs fresh_eqns in + (dbs, [SC_Typeclass { tc ; args = fresh_vars ; reason_typeclass_simpl="normalizer: split_typeclass"}] @ List.flatten recur) in + + match new_constraint.c with + (* break down (forall 'b, body = forall 'c, body') into ('a = forall 'b, body and 'a = forall 'c, body')) *) + | C_equation {aval=({ tsrc = _ ; t = P_forall _ } as a); bval=({ tsrc = _ ; t = P_forall _ } as b)} -> insert_fresh a b + (* break down (forall 'b, body = c(args)) into ('a = forall 'b, body and 'a = c(args)) *) + | C_equation {aval=({ tsrc = _ ; t = P_forall _ } as a); bval=({ tsrc = _ ; t = P_constant _ } as b)} -> insert_fresh a b + (* break down (c(args) = c'(args')) into ('a = c(args) and 'a = c'(args')) *) + | C_equation {aval=({ tsrc = _ ; t = P_constant _ } as a); bval=({ tsrc = _ ; t = P_constant _ } as b)} -> insert_fresh a b + (* break down (c(args) = forall 'b, body) into ('a = c(args) and 'a = forall 'b, body) *) + | C_equation {aval=({ tsrc = _ ; t = P_constant _ } as a); bval=({ tsrc = _ ; t = P_forall _ } as b)} -> insert_fresh a b + | C_equation {aval={ tsrc = _ ; t = P_forall forall }; bval={ tsrc = _ ; t = P_variable b }} -> gather_forall b forall + | C_equation {aval={ tsrc = _ ; t = P_variable a }; bval={ tsrc = _ ; t = P_forall forall }} -> gather_forall a forall + | C_equation {aval={ tsrc = _ ; t = P_variable a }; bval={ tsrc = _ ; t = P_variable b }} -> gather_alias a b + | C_equation {aval={ tsrc = _ ; t = P_variable a }; bval={ tsrc = _ ; t = P_constant { p_ctor_tag; p_ctor_args } }} -> split_constant a p_ctor_tag p_ctor_args + | C_equation {aval={ tsrc = _ ; t = P_constant {p_ctor_tag; p_ctor_args} }; bval={ tsrc = _ ; t = P_variable b }} -> split_constant b p_ctor_tag p_ctor_args + (* Reduce the type-level application, and simplify the resulting constraint + the extra constraints (typeclasses) that appeared at the forall binding site *) + | C_equation {aval=(_ as a); bval=({ tsrc = _ ; t = P_apply _ } as b)} -> reduce_type_app a b + | C_equation {aval=({ tsrc = _ ; t = P_apply _ } as a); bval=(_ as b)} -> reduce_type_app b a + (* break down (TC(args)) into (TC('a, …) and ('a = arg) …) *) + | C_typeclass { tc_args; typeclass } -> split_typeclass tc_args typeclass + | C_access_label { c_access_label_tval; accessor; c_access_label_tvar } -> let _todo = ignore (c_access_label_tval, accessor, c_access_label_tvar) in failwith "TODO" (* tv, label, result *) + +let normalizers : type_constraint -> structured_dbs -> (structured_dbs , 'modified_constraint) state_list_monad = + fun new_constraint dbs -> + (fun x -> x) + @@ lift normalizer_grouped_by_variable + @@ lift normalizer_assignments + @@ lift normalizer_all_constraints + @@ lift normalizer_simpl + @@ lift_state_list_monad ~state:dbs ~list:[new_constraint] diff --git a/src/passes/8-typer-new/solver.ml b/src/passes/8-typer-new/solver.ml index 02ee01b7e..0bcbe1260 100644 --- a/src/passes/8-typer-new/solver.ml +++ b/src/passes/8-typer-new/solver.ml @@ -1,633 +1,35 @@ open Trace - module Core = Typesystem.Core module Map = RedBlackTrees.PolyMap module Set = RedBlackTrees.PolySet module UF = UnionFind.Poly2 - -module Wrap = Wrap -open Wrap -open Ast_typed.Misc - -(* TODO: remove this, it's not used anymore *) -module TypeVariable = -struct - type t = Core.type_variable - let compare a b = Var.compare a b - let to_string = (fun s -> Format.asprintf "%a" Var.pp s) - -end - - - -(* - -Components: -* assignments (passive data structure). - Now: just a map from unification vars to types (pb: what about partial types?) - maybe just local assignments (allow only vars as children of pair(α,β)) -* constraint propagation: (buch of constraints) → (new constraints * assignments) - * sub-component: constraint selector (worklist / dynamic queries) - * sub-sub component: constraint normalizer: remove dupes and give structure - right now: union-find of unification vars - later: better database-like organisation of knowledge - * sub-sub component: lazy selector (don't re-try all selectors every time) - For now: just re-try everytime - * sub-component: propagation rule - For now: break pair(a, b) = pair(c, d) into a = c, b = d -* generalizer - For now: ? - -Workflow: - Start with empty assignments and structured database - Receive a new constraint - For each normalizer: - Use the pre-selector to see if it can be applied - Apply the normalizer, get some new items to insert in the structured database - For each propagator: - Use the selector to query the structured database and see if it can be applied - Apply the propagator, get some new constraints and assignments - Add the new assignments to the data structure. - - At some point (when?) - For each generalizer: - Use the generalizer's selector to see if it can be applied - Apply the generalizer to produce a new type, possibly with some ∀s injected - -*) - open Ast_typed.Types - -module UnionFindWrapper = struct - (* Light wrapper for API for grouped_by_variable in the structured - db, to access it modulo unification variable aliases. *) - let get_constraints_related_to : type_variable -> structured_dbs -> constraints = - fun variable dbs -> - let variable , aliases = UF.get_or_set variable dbs.aliases in - let dbs = { dbs with aliases } in - match Map.find_opt variable dbs.grouped_by_variable with - Some l -> l - | None -> { - constructor = [] ; - poly = [] ; - tc = [] ; - } - let add_constraints_related_to : type_variable -> constraints -> structured_dbs -> structured_dbs = - fun variable c dbs -> - (* let (variable_repr , _height) , aliases = UF.get_or_set variable dbs.aliases in - let dbs = { dbs with aliases } in *) - let variable_repr , aliases = UF.get_or_set variable dbs.aliases in - let dbs = { dbs with aliases } in - let grouped_by_variable = Map.update variable_repr (function - None -> Some c - | Some (x : constraints) -> Some { - constructor = c.constructor @ x.constructor ; - poly = c.poly @ x.poly ; - tc = c.tc @ x.tc ; - }) - dbs.grouped_by_variable - in - let dbs = { dbs with grouped_by_variable } in - dbs - - let merge_constraints : type_variable -> type_variable -> structured_dbs -> structured_dbs = - fun variable_a variable_b dbs -> - (* get old representant for variable_a *) - let variable_repr_a , aliases = UF.get_or_set variable_a dbs.aliases in - let dbs = { dbs with aliases } in - (* get old representant for variable_b *) - let variable_repr_b , aliases = UF.get_or_set variable_b dbs.aliases in - let dbs = { dbs with aliases } in - - (* alias variable_a and variable_b together *) - let aliases = UF.alias variable_a variable_b dbs.aliases in - let dbs = { dbs with aliases } in - - (* Replace the two entries in grouped_by_variable by a single one *) - ( - let get_constraints ab = - match Map.find_opt ab dbs.grouped_by_variable with - | Some x -> x - | None -> { constructor = [] ; poly = [] ; tc = [] } in - let constraints_a = get_constraints variable_repr_a in - let constraints_b = get_constraints variable_repr_b in - let all_constraints = { - constructor = constraints_a.constructor @ constraints_b.constructor ; - poly = constraints_a.poly @ constraints_b.poly ; - tc = constraints_a.tc @ constraints_b.tc ; - } in - let grouped_by_variable = - Map.add variable_repr_a all_constraints dbs.grouped_by_variable in - let dbs = { dbs with grouped_by_variable} in - let grouped_by_variable = - Map.remove variable_repr_b dbs.grouped_by_variable in - let dbs = { dbs with grouped_by_variable} in - dbs - ) -end - -(* sub-sub component: constraint normalizer: remove dupes and give structure - * right now: union-find of unification vars - * later: better database-like organisation of knowledge *) - -(* Each normalizer returns an updated database (after storing the - incoming constraint) and a list of constraints, used when the - normalizer rewrites the constraints e.g. into simpler ones. *) -(* TODO: If implemented in a language with decent sets, should be 'b set not 'b list. *) -type ('a , 'b) normalizer = structured_dbs -> 'a -> (structured_dbs * 'b list) - -(** Updates the dbs.all_constraints field when new constraints are - discovered. - - This field contains a list of all the constraints, without any form of - grouping or sorting. *) -let normalizer_all_constraints : (type_constraint_simpl , type_constraint_simpl) normalizer = - fun dbs new_constraint -> - ({ dbs with all_constraints = new_constraint :: dbs.all_constraints } , [new_constraint]) - -(** Updates the dbs.grouped_by_variable field when new constraints are - discovered. - - This field contains a map from type variables to lists of - constraints that are related to that variable (in other words, the - key appears in the equation). - *) -let normalizer_grouped_by_variable : (type_constraint_simpl , type_constraint_simpl) normalizer = - fun dbs new_constraint -> - let store_constraint tvars constraints = - let aux dbs (tvar : type_variable) = - UnionFindWrapper.add_constraints_related_to tvar constraints dbs - in List.fold_left aux dbs tvars - in - let dbs = match new_constraint.c_simpl with - SC_Constructor ({tv ; c_tag = _ ; tv_list} as c) -> store_constraint (tv :: tv_list) {constructor = [c] ; poly = [] ; tc = []} - | SC_Typeclass ({tc = _ ; args} as c) -> store_constraint args {constructor = [] ; poly = [] ; tc = [c]} - | SC_Poly ({tv; forall = _} as c) -> store_constraint [tv] {constructor = [] ; poly = [c] ; tc = []} - | SC_Alias { a; b } -> UnionFindWrapper.merge_constraints a b dbs - in (dbs , [new_constraint]) - -(** Stores the first assinment ('a = ctor('b, …)) that is encountered. - - Subsequent ('a = ctor('b2, …)) with the same 'a are ignored. - - TOOD: are we checking somewhere that 'b … = 'b2 … ? *) -let normalizer_assignments : (type_constraint_simpl , type_constraint_simpl) normalizer = - fun dbs new_constraint -> - match new_constraint.c_simpl with - | SC_Constructor ({tv ; c_tag = _ ; tv_list = _} as c) -> - let assignments = Map.update tv (function None -> Some c | e -> e) dbs.assignments in - let dbs = {dbs with assignments} in - (dbs , [new_constraint]) - | _ -> - (dbs , [new_constraint]) - -(** Evaluates a type-leval application. For now, only supports - immediate beta-reduction at the root of the type. *) -let type_level_eval : type_value -> type_value * type_constraint list = - fun tv -> Typesystem.Misc.Substitution.Pattern.eval_beta_root ~tv - -(** Checks that a type-level application has been fully reduced. For - now, only some simple cases like applications of `forall` - failwith "internal error: shouldn't happen" (* failwith "could not reduce type-level application. Arbitrary type-level applications are not supported for now." *) - | _ -> () - in x - -(* TODO: at some point there may be uses of named type aliases (type - foo = int; let x : foo = 42). These should be inlined. *) - -(** This function converts constraints from type_constraint to - type_constraint_simpl. The former has more possible cases, and the - latter uses a more minimalistic constraint language. - - It does not modify the dbs, and only rewrites the constraint - - TODO: update the code to show that the dbs are always copied as-is - *) -let rec normalizer_simpl : (type_constraint , type_constraint_simpl) normalizer = - fun dbs new_constraint -> - let insert_fresh a b = - let fresh = Core.fresh_type_variable () in - let (dbs , cs1) = normalizer_simpl dbs (c_equation (P_variable fresh) a "normalizer: simpl") in - let (dbs , cs2) = normalizer_simpl dbs (c_equation (P_variable fresh) b "normalizer: simpl") in - (dbs , cs1 @ cs2) in - let split_constant a c_tag args = - let fresh_vars = List.map (fun _ -> Core.fresh_type_variable ()) args in - let fresh_eqns = List.map (fun (v,t) -> c_equation (P_variable v) t "normalizer: split_constant") (List.combine fresh_vars args) in - let (dbs , recur) = List.fold_map_acc normalizer_simpl dbs fresh_eqns in - (dbs , [{c_simpl=SC_Constructor {tv=a;c_tag;tv_list=fresh_vars};reason_simpl="normalizer: split constant"}] @ List.flatten recur) in - let gather_forall a forall = (dbs , [{c_simpl=SC_Poly { tv=a; forall };reason_simpl="normalizer: gather_forall"}]) in - let gather_alias a b = (dbs , [{c_simpl=SC_Alias { a ; b };reason_simpl="normalizer: gather_alias"}]) in - let reduce_type_app a b = - let (reduced, new_constraints) = check_applied @@ type_level_eval b in - let (dbs , recur) = List.fold_map_acc normalizer_simpl dbs new_constraints in - let (dbs , resimpl) = normalizer_simpl dbs (c_equation a reduced "normalizer: reduce_type_app") in (* Note: this calls recursively but cant't fall in the same case. *) - (dbs , resimpl @ List.flatten recur) in - let split_typeclass args tc = - let fresh_vars = List.map (fun _ -> Core.fresh_type_variable ()) args in - let fresh_eqns = List.map (fun (v,t) -> c_equation (P_variable v) t "normalizer: split_typeclass") (List.combine fresh_vars args) in - let (dbs , recur) = List.fold_map_acc normalizer_simpl dbs fresh_eqns in - (dbs, [{c_simpl=SC_Typeclass { tc ; args = fresh_vars };reason_simpl="normalizer: split_typeclass"}] @ List.flatten recur) in - - match new_constraint.c with - (* break down (forall 'b, body = forall 'c, body') into ('a = forall 'b, body and 'a = forall 'c, body')) *) - | C_equation {aval=(P_forall _ as a); bval=(P_forall _ as b)} -> insert_fresh a b - (* break down (forall 'b, body = c(args)) into ('a = forall 'b, body and 'a = c(args)) *) - | C_equation {aval=(P_forall _ as a); bval=(P_constant _ as b)} -> insert_fresh a b - (* break down (c(args) = c'(args')) into ('a = c(args) and 'a = c'(args')) *) - | C_equation {aval=(P_constant _ as a); bval=(P_constant _ as b)} -> insert_fresh a b - (* break down (c(args) = forall 'b, body) into ('a = c(args) and 'a = forall 'b, body) *) - | C_equation {aval=(P_constant _ as a); bval=(P_forall _ as b)} -> insert_fresh a b - | C_equation {aval=(P_forall forall); bval=(P_variable b)} -> gather_forall b forall - | C_equation {aval=P_variable a; bval=P_forall forall} -> gather_forall a forall - | C_equation {aval=P_variable a; bval=P_variable b} -> gather_alias a b - | C_equation {aval=P_variable a; bval=P_constant { p_ctor_tag; p_ctor_args }} -> split_constant a p_ctor_tag p_ctor_args - | C_equation {aval=P_constant {p_ctor_tag; p_ctor_args}; bval=P_variable b} -> split_constant b p_ctor_tag p_ctor_args - (* Reduce the type-level application, and simplify the resulting constraint + the extra constraints (typeclasses) that appeared at the forall binding site *) - | C_equation {aval=(_ as a); bval=(P_apply _ as b)} -> reduce_type_app a b - | C_equation {aval=(P_apply _ as a); bval=(_ as b)} -> reduce_type_app b a - (* break down (TC(args)) into (TC('a, …) and ('a = arg) …) *) - | C_typeclass { tc_args; typeclass } -> split_typeclass tc_args typeclass - | C_access_label { c_access_label_tval; accessor; c_access_label_tvar } -> let _todo = ignore (c_access_label_tval, accessor, c_access_label_tvar) in failwith "TODO" (* tv, label, result *) - -(* Random notes from live discussion. Kept here to include bits as a rationale later on / remind me of the discussion in the short term. - * Feel free to erase if it rots here for too long. - * - * function (zetype, zevalue) { if (typeof(zevalue) != zetype) { ohlàlà; } else { return zevalue; } } - * - * let f = (fun {a : Type} (v : a) -> v) - * - * (forall 'a, 'a -> 'a) ~ (int -> int) - * (forall {a : Type}, forall (v : a), a) ~ (forall (v : int), int) - * ({a : Type} -> (v : a) -> a) ~ ((v : int) -> int) - * - * (@f int) - * - * - * 'c 'c - * 'd -> 'e && 'c ~ d && 'c ~ 'e - * 'c -> 'c ???????????????wtf---->???????????? [ scope of 'c is fun z ] - * 'tid ~ (forall 'c, 'c -> 'c) - * let id = (fun z -> z) in - * let ii = (fun z -> z + 0) : (int -> int) in - * - * 'a 'b ['a ~ 'b] 'a 'b - * 'a 'a 'a 'a 'a - * (forall 'a, 'a -> 'a -> 'a ) 'tid 'tid - * - * 'tid -> 'tid -> 'tid - * - * (forall 'a, 'a -> 'a -> 'a ) (forall 'c1, 'c1 -> 'c1) (int -> int) - * (forall 'c1, 'c1 -> 'c1)~(int -> int) - * ('c1 -> 'c1) ~ (int -> int) - * (fun x y -> if random then x else y) id ii as toto - * id "foo" *) - -type ('state, 'elt) state_list_monad = { state: 'state ; list : 'elt list } -let lift_state_list_monad ~state ~list = { state ; list } -let lift f = - fun { state ; list } -> - let (new_state , new_lists) = List.fold_map_acc f state list in - { state = new_state ; list = List.flatten new_lists } - -(* TODO: move this to the List module *) -let named_fold_left f ~acc ~lst = List.fold_left (fun acc elt -> f ~acc ~elt) acc lst - -module Fun = struct let id x = x end (* in stdlib as of 4.08, we're in 4.07 for now *) - -let normalizers : type_constraint -> structured_dbs -> (structured_dbs , 'modified_constraint) state_list_monad = - fun new_constraint dbs -> - Fun.id - @@ lift normalizer_grouped_by_variable - @@ lift normalizer_assignments - @@ lift normalizer_all_constraints - @@ lift normalizer_simpl - @@ lift_state_list_monad ~state:dbs ~list:[new_constraint] +open Solver_types (* sub-sub component: lazy selector (don't re-try all selectors every time) * For now: just re-try everytime *) -type 'old_constraint_type selector_input = 'old_constraint_type (* some info about the constraint just added, so that we know what to look for *) -type 'selector_output selector_outputs = - WasSelected of 'selector_output list - | WasNotSelected -type new_constraints = type_constraint list -type new_assignments = c_constructor_simpl list - -type ('old_constraint_type, 'selector_output) selector = 'old_constraint_type selector_input -> structured_dbs -> 'selector_output selector_outputs -type 'selector_output propagator = 'selector_output -> structured_dbs -> new_constraints * new_assignments - -(* selector / propagation rule for breaking down composite types - * For now: break pair(a, b) = pair(c, d) into a = c, b = d *) - -let selector_break_ctor : (type_constraint_simpl, output_break_ctor) selector = - (* find two rules with the shape a = k(var …) and a = k'(var' …) *) - fun type_constraint_simpl dbs -> - match type_constraint_simpl.c_simpl with - SC_Constructor c -> - (* finding other constraints related to the same type variable and - with the same sort of constraint (constructor vs. constructor) - is symmetric *) - let other_cs = (UnionFindWrapper.get_constraints_related_to c.tv dbs).constructor in - let other_cs = List.filter (fun (o : c_constructor_simpl) -> Var.equal c.tv o.tv) other_cs in - (* TODO double-check the conditions in the propagator, we had a - bug here because the selector was too permissive. *) - let cs_pairs = List.map (fun x -> { a_k_var = c ; a_k'_var' = x }) other_cs in - WasSelected cs_pairs - | SC_Alias _ -> WasNotSelected (* TODO: ??? (beware: symmetry) *) - | SC_Poly _ -> WasNotSelected (* TODO: ??? (beware: symmetry) *) - | SC_Typeclass _ -> WasNotSelected - -(* TODO: move this to a more appropriate place and/or auto-generate it. *) -let compare_simple_c_constant = function - | C_arrow -> (function - (* N/A -> 1 *) - | C_arrow -> 0 - | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_option -> (function - | C_arrow -> 1 - | C_option -> 0 - | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_record -> (function - | C_arrow | C_option -> 1 - | C_record -> 0 - | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_variant -> (function - | C_arrow | C_option | C_record -> 1 - | C_variant -> 0 - | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_map -> (function - | C_arrow | C_option | C_record | C_variant -> 1 - | C_map -> 0 - | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_big_map -> (function - | C_arrow | C_option | C_record | C_variant | C_map -> 1 - | C_big_map -> 0 - | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_list -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map -> 1 - | C_list -> 0 - | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_set -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list -> 1 - | C_set -> 0 - | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_unit -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set -> 1 - | C_unit -> 0 - | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_string -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit -> 1 - | C_string -> 0 - | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_nat -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string -> 1 - | C_nat -> 0 - | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_mutez -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat -> 1 - | C_mutez -> 0 - | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_timestamp -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez -> 1 - | C_timestamp -> 0 - | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_int -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp -> 1 - | C_int -> 0 - | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_address -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int -> 1 - | C_address -> 0 - | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_bytes -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address -> 1 - | C_bytes -> 0 - | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_key_hash -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes -> 1 - | C_key_hash -> 0 - | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_key -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash -> 1 - | C_key -> 0 - | C_signature | C_operation | C_contract | C_chain_id -> -1) - | C_signature -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key -> 1 - | C_signature -> 0 - | C_operation | C_contract | C_chain_id -> -1) - | C_operation -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature -> 1 - | C_operation -> 0 - | C_contract | C_chain_id -> -1) - | C_contract -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation -> 1 - | C_contract -> 0 - | C_chain_id -> -1) - | C_chain_id -> (function - | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract -> 1 - | C_chain_id -> 0 - (* N/A -> -1 *) - ) - -(* Using a pretty-printer from the PP.ml module creates a dependency - loop, so the one that we need temporarily for debugging purposes - has been copied here. *) -let debug_pp_constant : _ -> constant_tag -> unit = fun ppf c_tag -> - let ct = match c_tag with - | T.C_arrow -> "arrow" - | T.C_option -> "option" - | T.C_record -> failwith "record" - | T.C_variant -> failwith "variant" - | T.C_map -> "map" - | T.C_big_map -> "big_map" - | T.C_list -> "list" - | T.C_set -> "set" - | T.C_unit -> "unit" - | T.C_string -> "string" - | T.C_nat -> "nat" - | T.C_mutez -> "mutez" - | T.C_timestamp -> "timestamp" - | T.C_int -> "int" - | T.C_address -> "address" - | T.C_bytes -> "bytes" - | T.C_key_hash -> "key_hash" - | T.C_key -> "key" - | T.C_signature -> "signature" - | T.C_operation -> "operation" - | T.C_contract -> "contract" - | T.C_chain_id -> "chain_id" - in - Format.fprintf ppf "%s" ct - -let debug_pp_c_constructor_simpl ppf { tv; c_tag; tv_list } = - Format.fprintf ppf "CTOR %a %a(%a)" Var.pp tv debug_pp_constant c_tag PP_helpers.(list_sep Var.pp (const " , ")) tv_list - -let propagator_break_ctor : output_break_ctor propagator = - fun selected dbs -> - let () = ignore (dbs) in (* this propagator doesn't need to use the dbs *) - let a = selected.a_k_var in - let b = selected.a_k'_var' in - (* produce constraints: *) - - (* a.tv = b.tv *) - let eq1 = c_equation (P_variable a.tv) (P_variable b.tv) "propagator: break_ctor" in - (* a.c_tag = b.c_tag *) - if (compare_simple_c_constant a.c_tag b.c_tag) <> 0 then - failwith (Format.asprintf "type error: incompatible types, not same ctor %a vs. %a (compare returns %d)" debug_pp_c_constructor_simpl a debug_pp_c_constructor_simpl b (compare_simple_c_constant a.c_tag b.c_tag)) - else - (* a.tv_list = b.tv_list *) - if List.length a.tv_list <> List.length b.tv_list then - failwith "type error: incompatible types, not same length" - else - let eqs3 = List.map2 (fun aa bb -> c_equation (P_variable aa) (P_variable bb) "propagator: break_ctor") a.tv_list b.tv_list in - let eqs = eq1 :: eqs3 in - (eqs , []) (* no new assignments *) - (* TODO : with our selectors, the selection depends on the order in which the constraints are added :-( :-( :-( :-( We need to return a lazy stream of constraints. *) +let select_and_propagate : ('old_input, 'selector_output) selector -> _ propagator -> _ -> 'a -> structured_dbs -> _ * new_constraints * new_assignments = + fun selector propagator -> + fun already_selected old_type_constraint dbs -> + (* TODO: thread some state to know which selector outputs were already seen *) + match selector old_type_constraint dbs with + WasSelected selected_outputs -> + let Set.{ set = already_selected ; duplicates = _ ; added = selected_outputs } = Set.add_list selected_outputs already_selected in + (* Call the propagation rule *) + let new_contraints_and_assignments = List.map (fun s -> propagator s dbs) selected_outputs in + let (new_constraints , new_assignments) = List.split new_contraints_and_assignments in + (* return so that the new constraints are pushed to some kind of work queue and the new assignments stored *) + (already_selected , List.flatten new_constraints , List.flatten new_assignments) + | WasNotSelected -> + (already_selected, [] , []) - -let ( (function - [] -> 1 - | hd2::tl2 -> - f hd1 hd2 - compare_list f tl1 tl2) - | [] -> (function [] -> 0 | _::_ -> -1) (* This follows the behaviour of Pervasives.compare for lists of different length *) -let compare_type_variable a b = - Var.compare a b -let compare_label (a:label) (b:label) = - let Label a = a in - let Label b = b in - String.compare a b -let rec compare_typeclass a b = compare_list (compare_list compare_type_expression) a b -and compare_type_expression = function - | P_forall { binder=a1; constraints=a2; body=a3 } -> (function - | P_forall { binder=b1; constraints=b2; body=b3 } -> - compare_type_variable a1 b1 - compare_list compare_type_constraint a2 b2 - compare_type_expression a3 b3 - | P_variable _ -> -1 - | P_constant _ -> -1 - | P_apply _ -> -1) - | P_variable a -> (function - | P_forall _ -> 1 - | P_variable b -> compare_type_variable a b - | P_constant _ -> -1 - | P_apply _ -> -1) - | P_constant { p_ctor_tag=a1; p_ctor_args=a2 } -> (function - | P_forall _ -> 1 - | P_variable _ -> 1 - | P_constant { p_ctor_tag=b1; p_ctor_args=b2 } -> compare_simple_c_constant a1 b1 compare_list compare_type_expression a2 b2 - | P_apply _ -> -1) - | P_apply { tf=a1; targ=a2 } -> (function - | P_forall _ -> 1 - | P_variable _ -> 1 - | P_constant _ -> 1 - | P_apply { tf=b1; targ=b2 } -> compare_type_expression a1 b1 compare_type_expression a2 b2) -and compare_type_constraint = fun { c = ca ; reason = ra } { c = cb ; reason = rb } -> - let c = compare_type_constraint_ ca cb in - if c < 0 then -1 - else if c = 0 then String.compare ra rb - else 1 -and compare_type_constraint_ = function - | C_equation { aval=a1; bval=a2 } -> (function - | C_equation { aval=b1; bval=b2 } -> compare_type_expression a1 b1 compare_type_expression a2 b2 - | C_typeclass _ -> -1 - | C_access_label _ -> -1) - | C_typeclass { tc_args=a1; typeclass=a2 } -> (function - | C_equation _ -> 1 - | C_typeclass { tc_args=b1; typeclass=b2 } -> compare_list compare_type_expression a1 b1 compare_typeclass a2 b2 - | C_access_label _ -> -1) - | C_access_label { c_access_label_tval=a1; accessor=a2; c_access_label_tvar=a3 } -> (function - | C_equation _ -> 1 - | C_typeclass _ -> 1 - | C_access_label { c_access_label_tval=b1; accessor=b2; c_access_label_tvar=b3 } -> compare_type_expression a1 b1 compare_label a2 b2 compare_type_variable a3 b3) -let compare_type_constraint_list = compare_list compare_type_constraint -let compare_p_forall - { binder = a1; constraints = a2; body = a3 } - { binder = b1; constraints = b2; body = b3 } = - compare_type_variable a1 b1 - compare_type_constraint_list a2 b2 - compare_type_expression a3 b3 -let compare_c_poly_simpl { tv = a1; forall = a2 } { tv = b1; forall = b2 } = - compare_type_variable a1 b1 - compare_p_forall a2 b2 -let compare_c_constructor_simpl { tv=a1; c_tag=a2; tv_list=a3 } { tv=b1; c_tag=b2; tv_list=b3 } = - compare_type_variable a1 b1 compare_simple_c_constant a2 b2 compare_list compare_type_variable a3 b3 - -let compare_output_specialize1 { poly = a1; a_k_var = a2 } { poly = b1; a_k_var = b2 } = - compare_c_poly_simpl a1 b1 - compare_c_constructor_simpl a2 b2 - -let compare_output_break_ctor { a_k_var=a1; a_k'_var'=a2 } { a_k_var=b1; a_k'_var'=b2 } = - compare_c_constructor_simpl a1 b1 compare_c_constructor_simpl a2 b2 - -let selector_specialize1 : (type_constraint_simpl, output_specialize1) selector = - (* find two rules with the shape (a = forall b, d) and a = k'(var' …) or vice versa *) - (* TODO: do the same for two rules with the shape (a = forall b, d) and tc(a…) *) - (* TODO: do the appropriate thing for two rules with the shape (a = forall b, d) and (a = forall b', d') *) - fun type_constraint_simpl dbs -> - match type_constraint_simpl.c_simpl with - SC_Constructor c -> - (* vice versa *) - let other_cs = (UnionFindWrapper.get_constraints_related_to c.tv dbs).poly in - let other_cs = List.filter (fun (x : c_poly_simpl) -> c.tv = x.tv) other_cs in (* TODO: does equality work in OCaml? *) - let cs_pairs = List.map (fun x -> { poly = x ; a_k_var = c }) other_cs in - WasSelected cs_pairs - | SC_Alias _ -> WasNotSelected (* TODO: ??? *) - | SC_Poly p -> - let other_cs = (UnionFindWrapper.get_constraints_related_to p.tv dbs).constructor in - let other_cs = List.filter (fun (x : c_constructor_simpl) -> x.tv = p.tv) other_cs in (* TODO: does equality work in OCaml? *) - let cs_pairs = List.map (fun x -> { poly = p ; a_k_var = x }) other_cs in - WasSelected cs_pairs - | SC_Typeclass _ -> WasNotSelected - -let propagator_specialize1 : output_specialize1 propagator = - fun selected dbs -> - let () = ignore (dbs) in (* this propagator doesn't need to use the dbs *) - let a = selected.poly in - let b = selected.a_k_var in - let () = if (a.tv <> b.tv) then failwith "internal error" else () in - - (* produce constraints: *) - - (* create a fresh existential variable to instantiate the polymorphic type b *) - let fresh_existential = Core.fresh_type_variable () in - (* Produce the constraint (b.tv = a.body[a.binder |-> fresh_existential]) - The substitution is obtained by immediately applying the forall. *) - let apply = (P_apply {tf = (P_forall a.forall); targ = P_variable fresh_existential}) in - let (reduced, new_constraints) = check_applied @@ type_level_eval apply in - let eq1 = c_equation (P_variable b.tv) reduced "propagator: specialize1" in - let eqs = eq1 :: new_constraints in - (eqs, []) (* no new assignments *) - - let select_and_propagate : ('old_input, 'selector_output) selector -> _ propagator -> _ -> 'a -> structured_dbs -> _ * new_constraints * new_assignments = - let mem elt set = match RedBlackTrees.PolySet.find_opt elt set with None -> false | Some _ -> true in - fun selector propagator -> - fun already_selected old_type_constraint dbs -> - (* TODO: thread some state to know which selector outputs were already seen *) - match selector old_type_constraint dbs with - WasSelected selected_outputs -> - (* TODO: fold instead. *) - let (already_selected , selected_outputs) = List.fold_left (fun (already_selected, selected_outputs) elt -> if mem elt already_selected then (RedBlackTrees.PolySet.add elt already_selected , elt :: selected_outputs) - else (already_selected , selected_outputs)) (already_selected , selected_outputs) selected_outputs in - (* Call the propagation rule *) - let new_contraints_and_assignments = List.map (fun s -> propagator s dbs) selected_outputs in - let (new_constraints , new_assignments) = List.split new_contraints_and_assignments in - (* return so that the new constraints are pushed to some kind of work queue and the new assignments stored *) - (already_selected , List.flatten new_constraints , List.flatten new_assignments) - | WasNotSelected -> - (already_selected, [] , []) - -let select_and_propagate_break_ctor = select_and_propagate selector_break_ctor propagator_break_ctor -let select_and_propagate_specialize1 = select_and_propagate selector_specialize1 propagator_specialize1 +(* TODO: put the heuristics with their state in a list. *) +let select_and_propagate_break_ctor = select_and_propagate Heuristic_break_ctor.selector Heuristic_break_ctor.propagator +let select_and_propagate_specialize1 = select_and_propagate Heuristic_specialize1.selector Heuristic_specialize1.propagator (* Takes a constraint, applies all selector+propagator pairs to it. Keeps track of which constraints have already been selected. *) @@ -660,7 +62,7 @@ let rec select_and_propagate_all : _ -> type_constraint selector_input list -> s match new_constraints with | [] -> (already_selected, dbs) | new_constraint :: tl -> - let { state = dbs ; list = modified_constraints } = normalizers new_constraint dbs in + let { state = dbs ; list = modified_constraints } = Normalizer.normalizers new_constraint dbs in let (already_selected , new_constraints' , dbs) = List.fold_left (fun (already_selected , nc , dbs) c -> @@ -675,42 +77,22 @@ let rec select_and_propagate_all : _ -> type_constraint selector_input list -> s (* constraint propagation: (buch of constraints) → (new constraints * assignments) *) - - - - (* Below is a draft *) -(* type state = { - * (\* when α-renaming x to y, we put them in the same union-find class *\) - * unification_vars : unionfind ; - * - * (\* assigns a value to the representant in the unionfind *\) - * assignments : type_expression TypeVariableMap.t ; - * - * (\* constraints related to a type variable *\) - * constraints : constraints TypeVariableMap.t ; - * } *) - -let initial_state : typer_state = (* { - * unification_vars = UF.empty ; - * constraints = TypeVariableMap.empty ; - * assignments = TypeVariableMap.empty ; - * } *) -{ - structured_dbs = - { - all_constraints = [] ; (* type_constraint_simpl list *) - aliases = UF.empty (fun s -> Format.asprintf "%a" Var.pp s) Var.compare ; (* unionfind *) - assignments = Map.create ~cmp:Var.compare; (* c_constructor_simpl TypeVariableMap.t *) - grouped_by_variable = Map.create ~cmp:Var.compare; (* constraints TypeVariableMap.t *) - cycle_detection_toposort = (); (* unit *) - } ; - already_selected = { - break_ctor = Set.create ~cmp:compare_output_break_ctor; - specialize1 = Set.create ~cmp:compare_output_specialize1 ; +let initial_state : typer_state = { + structured_dbs = + { + all_constraints = ([] : type_constraint_simpl list) ; + aliases = UF.empty (fun s -> Format.asprintf "%a" Var.pp s) Var.compare; + assignments = (Map.create ~cmp:Var.compare : (type_variable, c_constructor_simpl) Map.t); + grouped_by_variable = (Map.create ~cmp:Var.compare : (type_variable, constraints) Map.t); + cycle_detection_toposort = (); + } ; + already_selected = { + break_ctor = Set.create ~cmp:Solver_should_be_generated.compare_output_break_ctor; + specialize1 = Set.create ~cmp:Solver_should_be_generated.compare_output_specialize1 ; + } } -} (* This function is called when a program is fully compiled, and the typechecker's state is discarded. TODO: either get rid of the state @@ -721,23 +103,6 @@ let initial_state : typer_state = (* { state any further. Suzanne *) let discard_state (_ : typer_state) = () -(* let replace_var_in_state = fun (v : type_variable) (state : state) -> *) -(* let aux_tv : type_expression -> _ = function *) -(* | P_forall (w , cs , tval) -> failwith "TODO" *) -(* | P_variable (w) -> *) -(* if w = v then *) -(* (*…*) *) -(* else *) -(* (*…*) *) -(* | P_constant (c , args) -> failwith "TODO" *) -(* | P_access_label (tv , label) -> failwith "TODO" in *) -(* let aux_tc tc = *) -(* List.map (fun l -> List.map aux_tv l) tc in *) -(* let aux : type_constraint -> _ = function *) -(* | C_equation (l , r) -> C_equation (aux_tv l , aux_tv r) *) -(* | C_typeclass (l , rs) -> C_typeclass (List.map aux_tv l , aux_tc rs) *) -(* in List.map aux state *) - (* This is the solver *) let aggregate_constraints : typer_state -> type_constraint list -> typer_state result = fun state newc -> (* TODO: Iterate over constraints *) @@ -747,12 +112,6 @@ let aggregate_constraints : typer_state -> type_constraint list -> typer_state r (*let { constraints ; eqv } = state in ok { constraints = constraints @ newc ; eqv }*) - - - - - - (* Later on, we'll ensure that all the heuristics register the existential/unification variables that they create, as well as the new constraints that they create. We will then check that they only diff --git a/src/passes/8-typer-new/solver_should_be_generated.ml b/src/passes/8-typer-new/solver_should_be_generated.ml new file mode 100644 index 000000000..91fc93b4a --- /dev/null +++ b/src/passes/8-typer-new/solver_should_be_generated.ml @@ -0,0 +1,214 @@ +(* The contents of this file should be auto-generated. *) + +open Ast_typed.Types +module T = Ast_typed.Types + +let compare_simple_c_constant = function + | C_arrow -> (function + (* N/A -> 1 *) + | C_arrow -> 0 + | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_option -> (function + | C_arrow -> 1 + | C_option -> 0 + | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_record -> (function + | C_arrow | C_option -> 1 + | C_record -> 0 + | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_variant -> (function + | C_arrow | C_option | C_record -> 1 + | C_variant -> 0 + | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_map -> (function + | C_arrow | C_option | C_record | C_variant -> 1 + | C_map -> 0 + | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_big_map -> (function + | C_arrow | C_option | C_record | C_variant | C_map -> 1 + | C_big_map -> 0 + | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_list -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map -> 1 + | C_list -> 0 + | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_set -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list -> 1 + | C_set -> 0 + | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_unit -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set -> 1 + | C_unit -> 0 + | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_string -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit -> 1 + | C_string -> 0 + | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_nat -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string -> 1 + | C_nat -> 0 + | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_mutez -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat -> 1 + | C_mutez -> 0 + | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_timestamp -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez -> 1 + | C_timestamp -> 0 + | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_int -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp -> 1 + | C_int -> 0 + | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_address -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int -> 1 + | C_address -> 0 + | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_bytes -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address -> 1 + | C_bytes -> 0 + | C_key_hash | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_key_hash -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes -> 1 + | C_key_hash -> 0 + | C_key | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_key -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash -> 1 + | C_key -> 0 + | C_signature | C_operation | C_contract | C_chain_id -> -1) + | C_signature -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key -> 1 + | C_signature -> 0 + | C_operation | C_contract | C_chain_id -> -1) + | C_operation -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature -> 1 + | C_operation -> 0 + | C_contract | C_chain_id -> -1) + | C_contract -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation -> 1 + | C_contract -> 0 + | C_chain_id -> -1) + | C_chain_id -> (function + | C_arrow | C_option | C_record | C_variant | C_map | C_big_map | C_list | C_set | C_unit | C_string | C_nat | C_mutez | C_timestamp | C_int | C_address | C_bytes | C_key_hash | C_key | C_signature | C_operation | C_contract -> 1 + | C_chain_id -> 0 + (* N/A -> -1 *) + ) + +let ( (function + [] -> 1 + | hd2::tl2 -> + f hd1 hd2 + compare_list f tl1 tl2) + | [] -> (function [] -> 0 | _::_ -> -1) (* This follows the behaviour of Pervasives.compare for lists of different length *) +let compare_type_variable a b = + Var.compare a b +let compare_label (a:label) (b:label) = + let Label a = a in + let Label b = b in + String.compare a b +let rec compare_typeclass a b = compare_list (compare_list compare_type_expression) a b +and compare_type_expression { tsrc = _ ; t = ta } { tsrc = _ ; t = tb } = + (* Note: this comparison ignores the tsrc, the idea is that types + will often be compared to see if they are the same, regardless of + where the type comes from .*) + compare_type_expression_ ta tb +and compare_type_expression_ = function + | P_forall { binder=a1; constraints=a2; body=a3 } -> (function + | P_forall { binder=b1; constraints=b2; body=b3 } -> + compare_type_variable a1 b1 + compare_list compare_type_constraint a2 b2 + compare_type_expression a3 b3 + | P_variable _ -> -1 + | P_constant _ -> -1 + | P_apply _ -> -1) + | P_variable a -> (function + | P_forall _ -> 1 + | P_variable b -> compare_type_variable a b + | P_constant _ -> -1 + | P_apply _ -> -1) + | P_constant { p_ctor_tag=a1; p_ctor_args=a2 } -> (function + | P_forall _ -> 1 + | P_variable _ -> 1 + | P_constant { p_ctor_tag=b1; p_ctor_args=b2 } -> compare_simple_c_constant a1 b1 compare_list compare_type_expression a2 b2 + | P_apply _ -> -1) + | P_apply { tf=a1; targ=a2 } -> (function + | P_forall _ -> 1 + | P_variable _ -> 1 + | P_constant _ -> 1 + | P_apply { tf=b1; targ=b2 } -> compare_type_expression a1 b1 compare_type_expression a2 b2) +and compare_type_constraint = fun { c = ca ; reason = ra } { c = cb ; reason = rb } -> + let c = compare_type_constraint_ ca cb in + if c < 0 then -1 + else if c = 0 then String.compare ra rb + else 1 +and compare_type_constraint_ = function + | C_equation { aval=a1; bval=a2 } -> (function + | C_equation { aval=b1; bval=b2 } -> compare_type_expression a1 b1 compare_type_expression a2 b2 + | C_typeclass _ -> -1 + | C_access_label _ -> -1) + | C_typeclass { tc_args=a1; typeclass=a2 } -> (function + | C_equation _ -> 1 + | C_typeclass { tc_args=b1; typeclass=b2 } -> compare_list compare_type_expression a1 b1 compare_typeclass a2 b2 + | C_access_label _ -> -1) + | C_access_label { c_access_label_tval=a1; accessor=a2; c_access_label_tvar=a3 } -> (function + | C_equation _ -> 1 + | C_typeclass _ -> 1 + | C_access_label { c_access_label_tval=b1; accessor=b2; c_access_label_tvar=b3 } -> compare_type_expression a1 b1 compare_label a2 b2 compare_type_variable a3 b3) +let compare_type_constraint_list = compare_list compare_type_constraint +let compare_p_forall + { binder = a1; constraints = a2; body = a3 } + { binder = b1; constraints = b2; body = b3 } = + compare_type_variable a1 b1 + compare_type_constraint_list a2 b2 + compare_type_expression a3 b3 +let compare_c_poly_simpl { tv = a1; forall = a2 } { tv = b1; forall = b2 } = + compare_type_variable a1 b1 + compare_p_forall a2 b2 +let compare_c_constructor_simpl { reason_constr_simpl = _ ; tv=a1; c_tag=a2; tv_list=a3 } { reason_constr_simpl = _ ; tv=b1; c_tag=b2; tv_list=b3 } = + (* We do not compare the reasons, as they are only for debugging and + not part of the type *) + compare_type_variable a1 b1 compare_simple_c_constant a2 b2 compare_list compare_type_variable a3 b3 + +(* TODO: use Ast_typed.Compare_generic.output_specialize1 etc. but don't compare the reasons *) +let compare_output_specialize1 { poly = a1; a_k_var = a2 } { poly = b1; a_k_var = b2 } = + compare_c_poly_simpl a1 b1 + compare_c_constructor_simpl a2 b2 + +let compare_output_break_ctor { a_k_var=a1; a_k'_var'=a2 } { a_k_var=b1; a_k'_var'=b2 } = + compare_c_constructor_simpl a1 b1 compare_c_constructor_simpl a2 b2 + +(* Using a pretty-printer from the PP.ml module creates a dependency + loop, so the one that we need temporarily for debugging purposes + has been copied here. *) +let debug_pp_constant : _ -> constant_tag -> unit = fun ppf c_tag -> + let ct = match c_tag with + | T.C_arrow -> "arrow" + | T.C_option -> "option" + | T.C_record -> failwith "record" + | T.C_variant -> failwith "variant" + | T.C_map -> "map" + | T.C_big_map -> "big_map" + | T.C_list -> "list" + | T.C_set -> "set" + | T.C_unit -> "unit" + | T.C_string -> "string" + | T.C_nat -> "nat" + | T.C_mutez -> "mutez" + | T.C_timestamp -> "timestamp" + | T.C_int -> "int" + | T.C_address -> "address" + | T.C_bytes -> "bytes" + | T.C_key_hash -> "key_hash" + | T.C_key -> "key" + | T.C_signature -> "signature" + | T.C_operation -> "operation" + | T.C_contract -> "contract" + | T.C_chain_id -> "chain_id" + in + Format.fprintf ppf "%s" ct + +let debug_pp_c_constructor_simpl ppf { tv; c_tag; tv_list } = + Format.fprintf ppf "CTOR %a %a(%a)" Var.pp tv debug_pp_constant c_tag PP_helpers.(list_sep Var.pp (const " , ")) tv_list diff --git a/src/passes/8-typer-new/solver_types.ml b/src/passes/8-typer-new/solver_types.ml new file mode 100644 index 000000000..9690d9c0a --- /dev/null +++ b/src/passes/8-typer-new/solver_types.ml @@ -0,0 +1,18 @@ +open Ast_typed.Types + +type 'old_constraint_type selector_input = 'old_constraint_type (* some info about the constraint just added, so that we know what to look for *) +type 'selector_output selector_outputs = + WasSelected of 'selector_output list + | WasNotSelected +type new_constraints = type_constraint list +type new_assignments = c_constructor_simpl list +type ('old_constraint_type, 'selector_output) selector = 'old_constraint_type selector_input -> structured_dbs -> 'selector_output selector_outputs +type 'selector_output propagator = 'selector_output -> structured_dbs -> new_constraints * new_assignments + +(* state+list monad *) +type ('state, 'elt) state_list_monad = { state: 'state ; list : 'elt list } +let lift_state_list_monad ~state ~list = { state ; list } +let lift f = + fun { state ; list } -> + let (new_state , new_lists) = List.fold_map_acc f state list in + { state = new_state ; list = List.flatten new_lists } diff --git a/src/passes/8-typer-new/typelang.ml b/src/passes/8-typer-new/typelang.ml new file mode 100644 index 000000000..ac9c3faa3 --- /dev/null +++ b/src/passes/8-typer-new/typelang.ml @@ -0,0 +1,18 @@ +(* This file implements the type-level language. For now limited to + type constants, type functions and their application. *) + +open Ast_typed.Types + +(** Evaluates a type-leval application. For now, only supports + immediate beta-reduction at the root of the type. *) +let type_level_eval : type_value -> type_value * type_constraint list = + fun tv -> Typesystem.Misc.Substitution.Pattern.eval_beta_root ~tv + +(** Checks that a type-level application has been fully reduced. For + now, only some simple cases like applications of `forall` + failwith "internal error: shouldn't happen" (* failwith "could not reduce type-level application. Arbitrary type-level applications are not supported for now." *) + | _ -> () + in x diff --git a/src/passes/8-typer-new/typer.ml b/src/passes/8-typer-new/typer.ml index 36fa997fe..604740583 100644 --- a/src/passes/8-typer-new/typer.ml +++ b/src/passes/8-typer-new/typer.ml @@ -29,7 +29,7 @@ let rec type_declaration env state : I.declaration -> (environment * O.typer_sta trace (constant_declaration_error binder expression tv'_opt) @@ type_expression env state expression in let post_env = Environment.add_ez_declaration binder expr env in - ok (post_env, state' , Some (O.Declaration_constant { binder ; expr ; inline ; post_env} )) + ok (post_env, state' , Some (O.Declaration_constant { binder ; expr ; inline} )) ) and type_match : environment -> O.typer_state -> O.type_expression -> I.matching_expr -> I.expression -> Location.t -> (O.matching_expr * O.typer_state) result = @@ -196,7 +196,7 @@ and type_expression : environment -> O.typer_state -> ?tv_opt:O.type_expression let%bind new_state = aggregate_constraints state constraints in let tv = t_variable type_name () in let location = ae.location in - let expr' = make_e ~location expr tv e in + let expr' = make_e ~location expr tv in ok @@ (expr' , new_state) in let return_wrapped expr state (constraints , expr_type) = return expr state constraints expr_type in let main_error = @@ -416,12 +416,11 @@ and type_lambda e state { let%bind input_type' = bind_map_option (evaluate_type e) input_type in let%bind output_type' = bind_map_option (evaluate_type e) output_type in - let fresh : O.type_expression = t_variable (Solver.Wrap.fresh_binder ()) () in + let fresh : O.type_expression = t_variable (Wrap.fresh_binder ()) () in let e' = Environment.add_ez_binder (binder) fresh e in let%bind (result , state') = type_expression e' state result in - let () = Printf.printf "this does not make use of the typed body, this code sounds buggy." in - let wrapped = Solver.Wrap.lambda fresh input_type' output_type' in + let wrapped = Wrap.lambda fresh input_type' output_type' result.type_expression in ok (({binder;result}:O.lambda),state',wrapped) and type_constant (name:I.constant') (lst:O.type_expression list) (tv_opt:O.type_expression option) : (O.constant' * O.type_expression) result = diff --git a/src/passes/8-typer-new/wrap.ml b/src/passes/8-typer-new/wrap.ml index d14397b51..5c0302887 100644 --- a/src/passes/8-typer-new/wrap.ml +++ b/src/passes/8-typer-new/wrap.ml @@ -44,7 +44,7 @@ let rec type_expression_to_type_value : T.type_expression -> O.type_value = fun | T_arrow {type1;type2} -> p_constant C_arrow (List.map type_expression_to_type_value [ type1 ; type2 ]) - | T_variable (type_name) -> P_variable type_name + | T_variable (type_name) -> { tsrc = "wrap: from source code maybe?" ; t = P_variable type_name } | T_constant (type_name) -> let csttag = T.(match type_name with | TC_unit -> C_unit @@ -89,7 +89,7 @@ let rec type_expression_to_type_value_copypasted : I.type_expression -> O.type_v p_constant C_record (List.map type_expression_to_type_value_copypasted tlist) | T_arrow {type1;type2} -> p_constant C_arrow (List.map type_expression_to_type_value_copypasted [ type1 ; type2 ]) - | T_variable type_name -> P_variable (type_name) (* eird stuff*) + | T_variable type_name -> { tsrc = "wrap: from source code maybe?" ; t = P_variable type_name } | T_constant (type_name) -> let csttag = T.(match type_name with | TC_unit -> C_unit @@ -121,12 +121,12 @@ let failwith_ : unit -> (constraints * O.type_variable) = fun () -> let variable : I.expression_variable -> T.type_expression -> (constraints * T.type_variable) = fun _name expr -> let pattern = type_expression_to_type_value expr in let type_name = Core.fresh_type_variable () in - [{ c = C_equation { aval = P_variable type_name ; bval = pattern } ; reason = "wrap: variable" }] , type_name + [{ c = C_equation { aval = { tsrc = "wrap: variable: whole" ; t = P_variable type_name } ; bval = pattern } ; reason = "wrap: variable" }] , type_name let literal : T.type_expression -> (constraints * T.type_variable) = fun t -> let pattern = type_expression_to_type_value t in let type_name = Core.fresh_type_variable () in - [{ c = C_equation { aval = P_variable type_name ; bval = pattern } ; reason = "wrap: literal" }] , type_name + [{ c = C_equation { aval = { tsrc = "wrap: literal: whole" ; t = P_variable type_name } ; bval = pattern } ; reason = "wrap: literal" }] , type_name (* let literal_bool : unit -> (constraints * O.type_variable) = fun () -> @@ -144,7 +144,7 @@ let tuple : T.type_expression list -> (constraints * T.type_variable) = fun tys let patterns = List.map type_expression_to_type_value tys in let pattern = p_constant C_record patterns in let type_name = Core.fresh_type_variable () in - [{ c = C_equation { aval = P_variable type_name ; bval = pattern} ; reason = "wrap: tuple" }] , type_name + [{ c = C_equation { aval = { tsrc = "wrap: tuple: whole" ; t = P_variable type_name } ; bval = pattern} ; reason = "wrap: tuple" }] , type_name (* let t_tuple = ('label:int, 'v) … -> record ('label : 'v) … *) (* let t_constructor = ('label:string, 'v) -> variant ('label : 'v) *) @@ -184,25 +184,25 @@ let constructor let sum = type_expression_to_type_value sum in let whole_expr = Core.fresh_type_variable () in [ - c_equation (P_variable whole_expr) sum "wrap: constructor: whole" ; + c_equation { tsrc = "wrap: constructor: whole" ; t = P_variable whole_expr } sum "wrap: constructor: whole" ; c_equation t_arg c_arg "wrap: construcotr: arg" ; ] , whole_expr let record : T.field_content T.label_map -> (constraints * T.type_variable) = fun fields -> let record_type = type_expression_to_type_value (T.t_record fields ()) in let whole_expr = Core.fresh_type_variable () in - [c_equation (P_variable whole_expr) record_type "wrap: record: whole"] , whole_expr + [c_equation { tsrc = "wrap: record: whole" ; t = P_variable whole_expr } record_type "wrap: record: whole"] , whole_expr let collection : O.constant_tag -> T.type_expression list -> (constraints * T.type_variable) = fun ctor element_tys -> - let elttype = T.P_variable (Core.fresh_type_variable ()) in + let elttype = T.{ tsrc = "wrap: collection: p_variable" ; t = P_variable (Core.fresh_type_variable ()) } in let aux elt = let elt' = type_expression_to_type_value elt in c_equation elttype elt' "wrap: collection: elt" in let equations = List.map aux element_tys in let whole_expr = Core.fresh_type_variable () in [ - c_equation (P_variable whole_expr) (p_constant ctor [elttype]) "wrap: collection: whole" ; + c_equation { tsrc = "wrap: collection: whole" ; t = P_variable whole_expr} (p_constant ctor [elttype]) "wrap: collection: whole" ; ] @ equations , whole_expr let list = collection T.C_list @@ -210,8 +210,8 @@ let set = collection T.C_set let map : (T.type_expression * T.type_expression) list -> (constraints * T.type_variable) = fun kv_tys -> - let k_type = T.P_variable (Core.fresh_type_variable ()) in - let v_type = T.P_variable (Core.fresh_type_variable ()) in + let k_type = T.{ tsrc = "wrap: map: k" ; t = P_variable (Core.fresh_type_variable ()) } in + let v_type = T.{ tsrc = "wrap: map: v" ; t = P_variable (Core.fresh_type_variable ()) } in let aux_k (k , _v) = let k' = type_expression_to_type_value k in c_equation k_type k' "wrap: map: key" in @@ -222,13 +222,13 @@ let map : (T.type_expression * T.type_expression) list -> (constraints * T.type_ let equations_v = List.map aux_v kv_tys in let whole_expr = Core.fresh_type_variable () in [ - c_equation (P_variable whole_expr) (p_constant C_map [k_type ; v_type]) "wrap: map: whole" ; + c_equation ({ tsrc = "wrap: map: whole" ; t = P_variable whole_expr }) (p_constant C_map [k_type ; v_type]) "wrap: map: whole" ; ] @ equations_k @ equations_v , whole_expr let big_map : (T.type_expression * T.type_expression) list -> (constraints * T.type_variable) = fun kv_tys -> - let k_type = T.P_variable (Core.fresh_type_variable ()) in - let v_type = T.P_variable (Core.fresh_type_variable ()) in + let k_type = T.{ tsrc = "wrap: big_map: k" ; t = P_variable (Core.fresh_type_variable ()) } in + let v_type = T.{ tsrc = "wrap: big_map: v" ; t = P_variable (Core.fresh_type_variable ()) } in let aux_k (k , _v) = let k' = type_expression_to_type_value k in c_equation k_type k' "wrap: big_map: key" in @@ -241,7 +241,7 @@ let big_map : (T.type_expression * T.type_expression) list -> (constraints * T.t [ (* TODO: this doesn't tag big_maps uniquely (i.e. if two big_map have the same type, they can be swapped. *) - c_equation (P_variable whole_expr) (p_constant C_big_map [k_type ; v_type]) "wrap: big_map: whole" ; + c_equation ({ tsrc = "wrap: big_map: whole" ; t = P_variable whole_expr}) (p_constant C_big_map [k_type ; v_type]) "wrap: big_map: whole" ; ] @ equations_k @ equations_v , whole_expr let application : T.type_expression -> T.type_expression -> (constraints * T.type_variable) = @@ -250,7 +250,7 @@ let application : T.type_expression -> T.type_expression -> (constraints * T.typ let f' = type_expression_to_type_value f in let arg' = type_expression_to_type_value arg in [ - c_equation f' (p_constant C_arrow [arg' ; P_variable whole_expr]) "wrap: application: f" ; + c_equation f' (p_constant C_arrow [arg' ; { tsrc = "wrap: application: whole" ; t = P_variable whole_expr }]) "wrap: application: f" ; ] , whole_expr let look_up : T.type_expression -> T.type_expression -> (constraints * T.type_variable) = @@ -258,10 +258,10 @@ let look_up : T.type_expression -> T.type_expression -> (constraints * T.type_va let ds' = type_expression_to_type_value ds in let ind' = type_expression_to_type_value ind in let whole_expr = Core.fresh_type_variable () in - let v = Core.fresh_type_variable () in + let v = T.{ tsrc = "wrap: look_up: ds" ; t = P_variable (Core.fresh_type_variable ()) } in [ - c_equation ds' (p_constant C_map [ind' ; P_variable v]) "wrap: look_up: map" ; - c_equation (P_variable whole_expr) (p_constant C_option [P_variable v]) "wrap: look_up: whole" ; + c_equation ds' (p_constant C_map [ind' ; v]) "wrap: look_up: map" ; + c_equation ({ tsrc = "wrap: look_up: whole" ; t = P_variable whole_expr }) (p_constant C_option [v]) "wrap: look_up: whole" ; ] , whole_expr let sequence : T.type_expression -> T.type_expression -> (constraints * T.type_variable) = @@ -271,7 +271,7 @@ let sequence : T.type_expression -> T.type_expression -> (constraints * T.type_v let whole_expr = Core.fresh_type_variable () in [ c_equation a' (p_constant C_unit []) "wrap: sequence: first" ; - c_equation b' (P_variable whole_expr) "wrap: sequence: second (whole)" ; + c_equation b' ({ tsrc = "wrap: sequence: whole" ; t = P_variable whole_expr}) "wrap: sequence: second (whole)" ; ] , whole_expr let loop : T.type_expression -> T.type_expression -> (constraints * T.type_variable) = @@ -280,9 +280,9 @@ let loop : T.type_expression -> T.type_expression -> (constraints * T.type_varia let body' = type_expression_to_type_value body in let whole_expr = Core.fresh_type_variable () in [ - c_equation expr' (P_variable Stage_common.Constant.t_bool) "wrap: loop: expr" ; + c_equation expr' ({ tsrc = "built-in type" ; t = P_variable Stage_common.Constant.t_bool }) "wrap: loop: expr" ; c_equation body' (p_constant C_unit []) "wrap: loop: body" ; - c_equation (P_variable whole_expr) (p_constant C_unit []) "wrap: loop: whole (unit)" ; + c_equation (p_constant C_unit []) ({ tsrc = "wrap: loop: whole" ; t = P_variable whole_expr}) "wrap: loop: whole (unit)" ; ] , whole_expr let let_in : T.type_expression -> T.type_expression option -> T.type_expression -> (constraints * T.type_variable) = @@ -294,7 +294,7 @@ let let_in : T.type_expression -> T.type_expression option -> T.type_expression | Some annot -> [c_equation rhs' (type_expression_to_type_value annot) "wrap: let_in: rhs"] in let whole_expr = Core.fresh_type_variable () in [ - c_equation result' (P_variable whole_expr) "wrap: let_in: result (whole)" ; + c_equation result' { tsrc = "wrap: let_in: whole" ; t = P_variable whole_expr } "wrap: let_in: result (whole)" ; ] @ rhs_tv_opt', whole_expr let recursive : T.type_expression -> (constraints * T.type_variable) = @@ -302,7 +302,7 @@ let recursive : T.type_expression -> (constraints * T.type_variable) = let fun_type = type_expression_to_type_value fun_type in let whole_expr = Core.fresh_type_variable () in [ - c_equation fun_type (P_variable whole_expr) "wrap: recursive: fun_type (whole)" ; + c_equation fun_type ({ tsrc = "wrap: recursive: whole" ; t = P_variable whole_expr }) "wrap: recursive: fun_type (whole)" ; ], whole_expr let assign : T.type_expression -> T.type_expression -> (constraints * T.type_variable) = @@ -312,7 +312,7 @@ let assign : T.type_expression -> T.type_expression -> (constraints * T.type_var let whole_expr = Core.fresh_type_variable () in [ c_equation v' e' "wrap: assign: var type must eq rhs type" ; - c_equation (P_variable whole_expr) (p_constant C_unit []) "wrap: assign: unit (whole)" ; + c_equation { tsrc = "wrap: assign: whole" ; t = P_variable whole_expr } (p_constant C_unit []) "wrap: assign: unit (whole)" ; ] , whole_expr let annotation : T.type_expression -> T.type_expression -> (constraints * T.type_variable) = @@ -322,14 +322,14 @@ let annotation : T.type_expression -> T.type_expression -> (constraints * T.type let whole_expr = Core.fresh_type_variable () in [ c_equation e' annot' "wrap: annotation: expr type must eq annot" ; - c_equation e' (P_variable whole_expr) "wrap: annotation: whole" ; + c_equation e' { tsrc = "wrap: annotation: whole" ; t = P_variable whole_expr } "wrap: annotation: whole" ; ] , whole_expr let matching : T.type_expression list -> (constraints * T.type_variable) = fun es -> let whole_expr = Core.fresh_type_variable () in let type_expressions = (List.map type_expression_to_type_value es) in - let cs = List.map (fun e -> c_equation (P_variable whole_expr) e "wrap: matching: case (whole)") type_expressions + let cs = List.map (fun e -> c_equation { tsrc = "wrap: matching: case" ; t = P_variable whole_expr } e "wrap: matching: case (whole)") type_expressions in cs, whole_expr let fresh_binder () = @@ -339,24 +339,26 @@ let lambda : T.type_expression -> T.type_expression option -> T.type_expression option -> + T.type_expression -> (constraints * T.type_variable) = - fun fresh arg body -> + fun fresh arg output result -> let whole_expr = Core.fresh_type_variable () in - let unification_arg = Core.fresh_type_variable () in - let unification_body = Core.fresh_type_variable () in + let unification_arg = T.{ tsrc = "wrap: lambda: arg" ; t = P_variable (Core.fresh_type_variable ()) } in + let unification_output = T.{ tsrc = "wrap: lambda: whole" ; t = P_variable (Core.fresh_type_variable ()) } in + let result' = type_expression_to_type_value result in let arg' = match arg with None -> [] - | Some arg -> [c_equation (P_variable unification_arg) (type_expression_to_type_value arg) "wrap: lambda: arg annot"] in - let body' = match body with + | Some arg -> [c_equation unification_arg (type_expression_to_type_value arg) "wrap: lambda: arg annot"] in + let output' = match output with None -> [] - | Some body -> [c_equation (P_variable unification_body) (type_expression_to_type_value body) "wrap: lambda: body annot"] + | Some output -> [c_equation unification_output (type_expression_to_type_value output) "wrap: lambda: output annot"] in [ - c_equation (type_expression_to_type_value fresh) (P_variable unification_arg) "wrap: lambda: arg" ; - c_equation (P_variable whole_expr) - (p_constant C_arrow ([P_variable unification_arg ; - P_variable unification_body])) + c_equation unification_output result' "wrap: lambda: result" ; + c_equation (type_expression_to_type_value fresh) unification_arg "wrap: lambda: arg" ; + c_equation ({ tsrc = "wrap: lambda: whole" ; t = P_variable whole_expr }) + (p_constant C_arrow ([unification_arg ; unification_output])) "wrap: lambda: arrow (whole)" - ] @ arg' @ body' , whole_expr + ] @ arg' @ output' , whole_expr (* This is pretty much a wrapper for an n-ary function. *) let constant : O.type_value -> T.type_expression list -> (constraints * T.type_variable) = @@ -365,5 +367,5 @@ let constant : O.type_value -> T.type_expression list -> (constraints * T.type_v let args' = List.map type_expression_to_type_value args in let args_tuple = p_constant C_record args' in [ - c_equation f (p_constant C_arrow ([args_tuple ; P_variable whole_expr])) "wrap: constant: as declared for built-in" + c_equation f (p_constant C_arrow ([args_tuple ; { tsrc = "wrap: lambda: whole" ; t = P_variable whole_expr }])) "wrap: constant: as declared for built-in" ] , whole_expr diff --git a/src/passes/8-typer-old/typer.ml b/src/passes/8-typer-old/typer.ml index 17af76c00..ca2a123a7 100644 --- a/src/passes/8-typer-old/typer.ml +++ b/src/passes/8-typer-old/typer.ml @@ -494,27 +494,25 @@ let rec type_program (p:I.program) : (O.program * O.typer_state) result = let%bind ed' = (bind_map_location (type_declaration e (Solver.placeholder_for_state_of_new_typer ()))) d in let loc : 'a . 'a Location.wrap -> _ -> _ = fun x v -> Location.wrap ~loc:x.location v in let (e', _placeholder_for_state_of_new_typer , d') = Location.unwrap ed' in - match d' with - | None -> ok (e', acc) - | Some d' -> ok (e', loc ed' d' :: acc) + ok (e', loc ed' d' :: acc) in let%bind (_, lst) = trace (fun () -> program_error p ()) @@ bind_fold_list aux (DEnv.default, []) p in ok @@ (List.rev lst , (Solver.placeholder_for_state_of_new_typer ())) -and type_declaration env (_placeholder_for_state_of_new_typer : O.typer_state) : I.declaration -> (environment * O.typer_state * O.declaration option) result = function - | Declaration_type (type_name , type_expression) -> - let%bind tv = evaluate_type env type_expression in - let env' = Environment.add_type (type_name) tv env in - ok (env', (Solver.placeholder_for_state_of_new_typer ()) , None) +and type_declaration env (_placeholder_for_state_of_new_typer : O.typer_state) : I.declaration -> (environment * O.typer_state * O.declaration) result = function + | Declaration_type (type_binder , type_expr) -> + let%bind tv = evaluate_type env type_expr in + let env' = Environment.add_type (type_binder) tv env in + ok (env', (Solver.placeholder_for_state_of_new_typer ()) , (O.Declaration_type { type_binder ; type_expr = tv } )) | Declaration_constant (binder , tv_opt , inline, expression) -> ( let%bind tv'_opt = bind_map_option (evaluate_type env) tv_opt in let%bind expr = trace (constant_declaration_error binder expression tv'_opt) @@ type_expression' ?tv_opt:tv'_opt env expression in let post_env = Environment.add_ez_declaration binder expr env in - ok (post_env, (Solver.placeholder_for_state_of_new_typer ()) , Some (O.Declaration_constant { binder ; expr ; inline ; post_env})) + ok (post_env, (Solver.placeholder_for_state_of_new_typer ()) , (O.Declaration_constant { binder ; expr ; inline})) ) and type_match : (environment -> I.expression -> O.expression result) -> environment -> O.type_expression -> I.matching_expr -> I.expression -> Location.t -> O.matching_expr result = @@ -674,6 +672,7 @@ and type_expression : environment -> O.typer_state -> ?tv_opt:O.type_expression = fun e _placeholder_for_state_of_new_typer ?tv_opt ae -> let%bind res = type_expression' e ?tv_opt ae in ok (res, (Solver.placeholder_for_state_of_new_typer ())) + and type_expression' : environment -> ?tv_opt:O.type_expression -> I.expression -> O.expression result = fun e ?tv_opt ae -> let module L = Logger.Stateful() in let return expr tv = @@ -682,7 +681,7 @@ and type_expression' : environment -> ?tv_opt:O.type_expression -> I.expression | None -> ok () | Some tv' -> O.assert_type_expression_eq (tv' , tv) in let location = ae.location in - ok @@ make_e ~location expr tv e in + ok @@ make_e ~location expr tv in let main_error = let title () = "typing expression" in let content () = "" in @@ -736,7 +735,7 @@ and type_expression' : environment -> ?tv_opt:O.type_expression -> I.expression generic_try (bad_record_access property ae prev.type_expression ae.location) @@ (fun () -> let ({field_type;_} : O.field_content) = O.LMap.find (convert_label property) r_tv in field_type) in let location = ae.location in - ok @@ make_e ~location (E_record_accessor {record=prev; path=convert_label property}) tv e + ok @@ make_e ~location (E_record_accessor {record=prev; path=convert_label property}) tv in let%bind ae = trace (simple_info "accessing") @@ aux e' path in @@ -832,7 +831,7 @@ and type_expression' : environment -> ?tv_opt:O.type_expression -> I.expression let e' = Environment.add_ez_binder lname input_type e in let%bind body = type_expression' ?tv_opt:(Some tv_out) e' result in let output_type = body.type_expression in - let lambda' = make_e (E_lambda {binder = lname ; result=body}) (t_function input_type output_type ()) e' in + let lambda' = make_e (E_lambda {binder = lname ; result=body}) (t_function input_type output_type ()) in let lst' = [lambda'; v_col; v_initr] in let tv_lst = List.map get_type_expression lst' in let%bind (opname', tv) = @@ -853,7 +852,7 @@ and type_expression' : environment -> ?tv_opt:O.type_expression -> I.expression let e' = Environment.add_ez_binder lname input_type e in let%bind body = type_expression' e' result in let output_type = body.type_expression in - let lambda' = make_e (E_lambda {binder = lname ; result=body}) (t_function input_type output_type ()) e' in + let lambda' = make_e (E_lambda {binder = lname ; result=body}) (t_function input_type output_type ()) in let lst' = [lambda';v_initr] in let tv_lst = List.map get_type_expression lst' in let%bind (opname',tv) = type_constant opname tv_lst tv_opt in diff --git a/src/passes/8-typer-old/typer.mli b/src/passes/8-typer-old/typer.mli index ff7009a8c..531a6b751 100644 --- a/src/passes/8-typer-old/typer.mli +++ b/src/passes/8-typer-old/typer.mli @@ -39,7 +39,7 @@ module Errors : sig end val type_program : I.program -> (O.program * O.typer_state) result -val type_declaration : environment -> O.typer_state -> I.declaration -> (environment * O.typer_state * O.declaration option) result +val type_declaration : environment -> O.typer_state -> I.declaration -> (environment * O.typer_state * O.declaration) result (* val type_match : (environment -> 'i -> 'o result) -> environment -> O.type_value -> 'i I.matching -> I.expression -> Location.t -> 'o O.matching result *) val evaluate_type : environment -> I.type_expression -> O.type_expression result val type_expression : environment -> O.typer_state -> ?tv_opt:O.type_expression -> I.expression -> (O.expression * O.typer_state) result diff --git a/src/passes/9-self_ast_typed/helpers.ml b/src/passes/9-self_ast_typed/helpers.ml index f42d1ea37..a63a2893a 100644 --- a/src/passes/9-self_ast_typed/helpers.ml +++ b/src/passes/9-self_ast_typed/helpers.ml @@ -156,10 +156,11 @@ and map_cases : mapper -> matching_expr -> matching_expr result = fun f m -> and map_program : mapper -> program -> program result = fun m p -> let aux = fun (x : declaration) -> match x with - | Declaration_constant {binder; expr ; inline ; post_env} -> ( + | Declaration_constant {binder; expr ; inline} -> ( let%bind expr = map_expression m expr in - ok (Declaration_constant {binder; expr ; inline ; post_env}) - ) + ok (Declaration_constant {binder; expr ; inline}) + ) + | Declaration_type t -> ok (Declaration_type t) in bind_map_list (bind_map_location aux) p @@ -246,11 +247,15 @@ and fold_map_cases : 'a . 'a fold_mapper -> 'a -> matching_expr -> ('a * matchin and fold_map_program : 'a . 'a fold_mapper -> 'a -> program -> ('a * program) result = fun m init p -> let aux = fun (acc,acc_prg) (x : declaration Location.wrap) -> match Location.unwrap x with - | Declaration_constant {binder ; expr ; inline ; post_env} -> ( + | Declaration_constant {binder ; expr ; inline} -> ( let%bind (acc', expr) = fold_map_expression m acc expr in - let wrap_content = Declaration_constant {binder ; expr ; inline ; post_env} in + let wrap_content = Declaration_constant {binder ; expr ; inline} in ok (acc', List.append acc_prg [{x with wrap_content}]) ) + | Declaration_type t -> ( + let wrap_content = Declaration_type t in + ok (acc, List.append acc_prg [{x with wrap_content}]) + ) in bind_fold_list aux (init,[]) p @@ -298,30 +303,31 @@ type contract_type = { } let fetch_contract_type : string -> program -> contract_type result = fun main_fname program -> - let main_decl = List.rev @@ List.filter - (fun declt -> - let (Declaration_constant { binder ; expr=_ ; inline=_ ; post_env=_ }) = Location.unwrap declt in - String.equal (Var.to_name binder) main_fname - ) - program + let aux declt = match Location.unwrap declt with + | Declaration_constant ({ binder ; expr=_ ; inline=_ } as p) -> + if String.equal (Var.to_name binder) main_fname + then Some p + else None + | Declaration_type _ -> None in - match main_decl with - | (hd::_) -> ( - let (Declaration_constant { binder=_ ; expr ; inline=_ ; post_env=_ }) = Location.unwrap hd in - match expr.type_expression.type_content with - | T_arrow {type1 ; type2} -> ( - match type1.type_content , type2.type_content with - | T_record tin , T_record tout when (is_tuple_lmap tin) && (is_tuple_lmap tout) -> - let%bind (parameter,storage) = Ast_typed.Helpers.get_pair tin in - let%bind (listop,storage') = Ast_typed.Helpers.get_pair tout in - let%bind () = trace_strong (Errors.expected_list_operation main_fname listop expr) @@ - Ast_typed.assert_t_list_operation listop in - let%bind () = trace_strong (Errors.expected_same main_fname storage storage' expr) @@ - Ast_typed.assert_type_expression_eq (storage,storage') in - (* TODO: on storage/parameter : assert_storable, assert_passable ? *) - ok { parameter ; storage } - | _ -> fail @@ Errors.bad_contract_io main_fname expr - ) - | _ -> fail @@ Errors.bad_contract_io main_fname expr + let main_decl_opt = List.find_map aux @@ List.rev program in + let%bind main_decl = + trace_option (simple_error ("Entrypoint '"^main_fname^"' does not exist")) @@ + main_decl_opt + in + let { binder=_ ; expr ; inline=_ } = main_decl in + match expr.type_expression.type_content with + | T_arrow {type1 ; type2} -> ( + match type1.type_content , type2.type_content with + | T_record tin , T_record tout when (is_tuple_lmap tin) && (is_tuple_lmap tout) -> + let%bind (parameter,storage) = Ast_typed.Helpers.get_pair tin in + let%bind (listop,storage') = Ast_typed.Helpers.get_pair tout in + let%bind () = trace_strong (Errors.expected_list_operation main_fname listop expr) @@ + Ast_typed.assert_t_list_operation listop in + let%bind () = trace_strong (Errors.expected_same main_fname storage storage' expr) @@ + Ast_typed.assert_type_expression_eq (storage,storage') in + (* TODO: on storage/parameter : assert_storable, assert_passable ? *) + ok { parameter ; storage } + | _ -> fail @@ Errors.bad_contract_io main_fname expr ) - | [] -> simple_fail ("Entrypoint '"^main_fname^"' does not exist") + | _ -> fail @@ Errors.bad_contract_io main_fname expr diff --git a/src/passes/9-self_ast_typed/michelson_layout.ml b/src/passes/9-self_ast_typed/michelson_layout.ml index 2211715b9..ce59c0898 100644 --- a/src/passes/9-self_ast_typed/michelson_layout.ml +++ b/src/passes/9-self_ast_typed/michelson_layout.ml @@ -13,25 +13,25 @@ let accessor (record:expression) (path:label) (t:type_expression) = { expression_content = E_record_accessor {record; path} ; location = Location.generated ; type_expression = t ; - environment = record.environment } + } let constructor (constructor:constructor') (element:expression) (t:type_expression) = { expression_content = E_constructor { constructor ; element } ; location = Location.generated ; type_expression = t ; - environment = element.environment } + } let match_var (t:type_expression) = { expression_content = E_variable (Var.of_name "x") ; location = Location.generated ; type_expression = t ; - environment = Environment.add_ez_binder (Var.of_name "x") t Environment.empty} + } let matching (e:expression) matchee cases = { expression_content = E_matching {matchee ; cases}; location = Location.generated ; type_expression = e.type_expression ; - environment = e.environment } + } let rec descend_types s lmap i = if i > 0 then @@ -105,7 +105,7 @@ let rec to_right_comb_record let exp = { expression_content = E_record_accessor {record = prev ; path = label } ; location = Location.generated ; type_expression = field_type ; - environment = prev.environment } in + } in let conv_map' = LMap.add (Label "0") exp conv_map in LMap.add (Label "1") ({exp with expression_content = E_record (to_right_comb_record prev tl conv_map')}) conv_map' @@ -275,4 +275,4 @@ let peephole_expression : expression -> expression result = fun e -> return match_expr.expression_content | _ -> return e.expression_content ) - | _ as e -> return e \ No newline at end of file + | _ as e -> return e diff --git a/src/passes/9-self_ast_typed/self_ast_typed.ml b/src/passes/9-self_ast_typed/self_ast_typed.ml index 77b50ce9c..442564638 100644 --- a/src/passes/9-self_ast_typed/self_ast_typed.ml +++ b/src/passes/9-self_ast_typed/self_ast_typed.ml @@ -13,8 +13,7 @@ let contract_passes = [ let all_program program = let all_p = List.map Helpers.map_program all_passes in let%bind program' = bind_chain all_p program in - let program'' = Recompute_environment.program Environment.default program' in - ok program'' + ok program' let all_expression = let all_p = List.map Helpers.map_expression all_passes in diff --git a/src/passes/operators/operators.ml b/src/passes/operators/operators.ml index ce870c27c..dc63d5573 100644 --- a/src/passes/operators/operators.ml +++ b/src/passes/operators/operators.ml @@ -434,17 +434,17 @@ module Typer = struct module Operators_types = struct open Typesystem.Shorthands - let tc_subarg a b c = tc [a;b;c] [ (*TODO…*) ] - let tc_sizearg a = tc [a] [ [int] ] - let tc_packable a = tc [a] [ [int] ; [string] ; [bool] (*TODO…*) ] - let tc_timargs a b c = tc [a;b;c] [ [nat;nat;nat] ; [int;int;int] (*TODO…*) ] - let tc_edivargs a b c = tc [a;b;c] [ (*TODO…*) ] - let tc_divargs a b c = tc [a;b;c] [ (*TODO…*) ] - let tc_modargs a b c = tc [a;b;c] [ (*TODO…*) ] - let tc_addargs a b c = tc [a;b;c] [ (*TODO…*) ] - let tc_comparable a = tc [a] [ [nat] ; [int] ; [mutez] ; [timestamp] ] - let tc_concatable a = tc [a] [ [string] ; [bytes] ] - let tc_storable a = tc [a] [ [string] ; [bytes] ; (*Humm .. TODO ?*) ] + let tc_subarg a b c = tc "arguments for (-)" [a;b;c] [ (*TODO…*) ] + let tc_sizearg a = tc "arguments for size" [a] [ [int] ] + let tc_packable a = tc "packable" [a] [ [int] ; [string] ; [bool] (*TODO…*) ] + let tc_timargs a b c = tc "arguments for ( * )" [a;b;c] [ [nat;nat;nat] ; [int;int;int] (*TODO…*) ] + let tc_edivargs a b c = tc "arguments for ediv" [a;b;c] [ (*TODO…*) ] + let tc_divargs a b c = tc "arguments for div" [a;b;c] [ (*TODO…*) ] + let tc_modargs a b c = tc "arguments for mod" [a;b;c] [ (*TODO…*) ] + let tc_addargs a b c = tc "arguments for (+)" [a;b;c] [ [nat;nat;nat] ; [int;int;int] (*TODO…*) ] + let tc_comparable a = tc "comparable" [a] [ [nat] ; [int] ; [mutez] ; [timestamp] ] + let tc_concatable a = tc "concatenable" [a] [ [string] ; [bytes] ] + let tc_storable a = tc "storable" [a] [ [string] ; [bytes] ; (*Humm .. TODO ?*) ] let t_none = forall "a" @@ fun a -> option a diff --git a/src/stages/1-ast_imperative/ast_imperative.ml b/src/stages/1-ast_imperative/ast_imperative.ml index e9614490a..7fa34e677 100644 --- a/src/stages/1-ast_imperative/ast_imperative.ml +++ b/src/stages/1-ast_imperative/ast_imperative.ml @@ -3,6 +3,5 @@ include Types (* include Misc *) include Combinators module Types = Types -module Misc = Misc module PP=PP module Combinators = Combinators diff --git a/src/stages/1-ast_imperative/misc.ml b/src/stages/1-ast_imperative/misc.ml deleted file mode 100644 index cf27a497d..000000000 --- a/src/stages/1-ast_imperative/misc.ml +++ /dev/null @@ -1,353 +0,0 @@ -open Trace -open Types - -open Stage_common.Helpers -module Errors = struct - let different_literals_because_different_types name a b () = - let title () = "literals have different types: " ^ name in - let message () = "" in - let data = [ - ("a" , fun () -> Format.asprintf "%a" PP.literal a) ; - ("b" , fun () -> Format.asprintf "%a" PP.literal b ) - ] in - error ~data title message () - - let different_literals name a b () = - let title () = name ^ " are different" in - let message () = "" in - let data = [ - ("a" , fun () -> Format.asprintf "%a" PP.literal a) ; - ("b" , fun () -> Format.asprintf "%a" PP.literal b ) - ] in - error ~data title message () - - let error_uncomparable_literals name a b () = - let title () = name ^ " are not comparable" in - let message () = "" in - let data = [ - ("a" , fun () -> Format.asprintf "%a" PP.literal a) ; - ("b" , fun () -> Format.asprintf "%a" PP.literal b ) - ] in - error ~data title message () -end -open Errors - -let assert_literal_eq (a, b : literal * literal) : unit result = - match (a, b) with - | Literal_int a, Literal_int b when a = b -> ok () - | Literal_int _, Literal_int _ -> fail @@ different_literals "different ints" a b - | Literal_int _, _ -> fail @@ different_literals_because_different_types "int vs non-int" a b - | Literal_nat a, Literal_nat b when a = b -> ok () - | Literal_nat _, Literal_nat _ -> fail @@ different_literals "different nats" a b - | Literal_nat _, _ -> fail @@ different_literals_because_different_types "nat vs non-nat" a b - | Literal_timestamp a, Literal_timestamp b when a = b -> ok () - | Literal_timestamp _, Literal_timestamp _ -> fail @@ different_literals "different timestamps" a b - | Literal_timestamp _, _ -> fail @@ different_literals_because_different_types "timestamp vs non-timestamp" a b - | Literal_mutez a, Literal_mutez b when a = b -> ok () - | Literal_mutez _, Literal_mutez _ -> fail @@ different_literals "different tezs" a b - | Literal_mutez _, _ -> fail @@ different_literals_because_different_types "tez vs non-tez" a b - | Literal_string a, Literal_string b when a = b -> ok () - | Literal_string _, Literal_string _ -> fail @@ different_literals "different strings" a b - | Literal_string _, _ -> fail @@ different_literals_because_different_types "string vs non-string" a b - | Literal_bytes a, Literal_bytes b when a = b -> ok () - | Literal_bytes _, Literal_bytes _ -> fail @@ different_literals "different bytess" a b - | Literal_bytes _, _ -> fail @@ different_literals_because_different_types "bytes vs non-bytes" a b - | Literal_void, Literal_void -> ok () - | Literal_void, _ -> fail @@ different_literals_because_different_types "void vs non-void" a b - | Literal_unit, Literal_unit -> ok () - | Literal_unit, _ -> fail @@ different_literals_because_different_types "unit vs non-unit" a b - | Literal_address a, Literal_address b when a = b -> ok () - | Literal_address _, Literal_address _ -> fail @@ different_literals "different addresss" a b - | Literal_address _, _ -> fail @@ different_literals_because_different_types "address vs non-address" a b - | Literal_operation _, Literal_operation _ -> fail @@ error_uncomparable_literals "can't compare operations" a b - | Literal_operation _, _ -> fail @@ different_literals_because_different_types "operation vs non-operation" a b - | Literal_signature a, Literal_signature b when a = b -> ok () - | Literal_signature _, Literal_signature _ -> fail @@ different_literals "different signature" a b - | Literal_signature _, _ -> fail @@ different_literals_because_different_types "signature vs non-signature" a b - | Literal_key a, Literal_key b when a = b -> ok () - | Literal_key _, Literal_key _ -> fail @@ different_literals "different key" a b - | Literal_key _, _ -> fail @@ different_literals_because_different_types "key vs non-key" a b - | Literal_key_hash a, Literal_key_hash b when a = b -> ok () - | Literal_key_hash _, Literal_key_hash _ -> fail @@ different_literals "different key_hash" a b - | Literal_key_hash _, _ -> fail @@ different_literals_because_different_types "key_hash vs non-key_hash" a b - | Literal_chain_id a, Literal_chain_id b when a = b -> ok () - | Literal_chain_id _, Literal_chain_id _ -> fail @@ different_literals "different chain_id" a b - | Literal_chain_id _, _ -> fail @@ different_literals_because_different_types "chain_id vs non-chain_id" a b - -let rec assert_value_eq (a, b: (expression * expression )) : unit result = - Format.printf "in assert_value_eq %a %a\n%!" PP.expression a PP.expression b; - let error_content () = - Format.asprintf "\n@[- %a@;- %a]" PP.expression a PP.expression b - in - trace (fun () -> error (thunk "not equal") error_content ()) @@ - match (a.expression_content , b.expression_content) with - | E_literal a , E_literal b -> - assert_literal_eq (a, b) - | E_literal _ , _ -> - simple_fail "comparing a literal with not a literal" - | E_constant (ca) , E_constant (cb) when ca.cons_name = cb.cons_name -> ( - let%bind lst = - generic_try (simple_error "constants with different number of elements") - (fun () -> List.combine ca.arguments cb.arguments) in - let%bind _all = bind_list @@ List.map assert_value_eq lst in - ok () - ) - | E_constant _ , E_constant _ -> - simple_fail "different constants" - | E_constant _ , _ -> - let error_content () = - Format.asprintf "%a vs %a" - PP.expression a - PP.expression b - in - fail @@ (fun () -> error (thunk "comparing constant with other expression") error_content ()) - - | E_constructor (ca), E_constructor (cb) when ca.constructor = cb.constructor -> ( - let%bind _eq = assert_value_eq (ca.element, cb.element) in - ok () - ) - | E_constructor _, E_constructor _ -> - simple_fail "different constructors" - | E_constructor _, _ -> - simple_fail "comparing constructor with other expression" - - - | E_record sma, E_record smb -> ( - let aux _ a b = - match a, b with - | Some a, Some b -> Some (assert_value_eq (a, b)) - | _ -> Some (simple_fail "different record keys") - in - let%bind _all = bind_lmap @@ LMap.merge aux sma smb in - ok () - ) - | E_record _, _ -> - simple_fail "comparing record with other expression" - - | E_record_update ura, E_record_update urb -> - let _ = - generic_try (simple_error "Updating different record") @@ - fun () -> assert_value_eq (ura.record, urb.record) in - let aux (Label a,Label b) = - assert (String.equal a b) - in - let () = aux (ura.path, urb.path) in - let%bind () = assert_value_eq (ura.update,urb.update) in - ok () - | E_record_update _, _ -> - simple_fail "comparing record update with other expression" - - | E_tuple lsta, E_tuple lstb -> ( - let%bind lst = - generic_try (simple_error "tuples with different number of elements") - (fun () -> List.combine lsta lstb) in - let%bind _all = bind_list @@ List.map assert_value_eq lst in - ok () - ) - | E_tuple _, _ -> - simple_fail "comparing tuple with other expression" - - | E_tuple_update uta, E_tuple_update utb -> - let _ = - generic_try (simple_error "Updating different tuple") @@ - fun () -> assert_value_eq (uta.tuple, utb.tuple) in - let () = assert (uta.path == utb.path) in - let%bind () = assert_value_eq (uta.update,utb.update) in - ok () - | E_tuple_update _, _ -> - simple_fail "comparing tuple update with other expression" - - | (E_map lsta, E_map lstb | E_big_map lsta, E_big_map lstb) -> ( - let%bind lst = generic_try (simple_error "maps of different lengths") - (fun () -> - let lsta' = List.sort compare lsta in - let lstb' = List.sort compare lstb in - List.combine lsta' lstb') in - let aux = fun ((ka, va), (kb, vb)) -> - let%bind _ = assert_value_eq (ka, kb) in - let%bind _ = assert_value_eq (va, vb) in - ok () in - let%bind _all = bind_map_list aux lst in - ok () - ) - | (E_map _ | E_big_map _), _ -> - simple_fail "comparing map with other expression" - - | E_list lsta, E_list lstb -> ( - let%bind lst = - generic_try (simple_error "list of different lengths") - (fun () -> List.combine lsta lstb) in - let%bind _all = bind_map_list assert_value_eq lst in - ok () - ) - | E_list _, _ -> - simple_fail "comparing list with other expression" - - | E_set lsta, E_set lstb -> ( - let lsta' = List.sort (compare) lsta in - let lstb' = List.sort (compare) lstb in - let%bind lst = - generic_try (simple_error "set of different lengths") - (fun () -> List.combine lsta' lstb') in - let%bind _all = bind_map_list assert_value_eq lst in - ok () - ) - | E_set _, _ -> - simple_fail "comparing set with other expression" - - | (E_ascription a , _b') -> assert_value_eq (a.anno_expr , b) - | (_a' , E_ascription b) -> assert_value_eq (a , b.anno_expr) - | (E_variable _, _) | (E_lambda _, _) - | (E_application _, _) | (E_let_in _, _) - | (E_recursive _,_) - | (E_record_accessor _, _) | (E_tuple_accessor _, _) - | (E_look_up _, _) - | (E_matching _, _) | (E_cond _, _) - | (E_sequence _, _) | (E_skip, _) - | (E_assign _, _) - | (E_for _, _) | (E_for_each _, _) - | (E_while _, _) -> simple_fail "comparing not a value" - -let is_value_eq (a , b) = to_bool @@ assert_value_eq (a , b) - -(* module Rename = struct - * open Trace - * - * module Type = struct - * (\* Type renaming, not needed. Yet. *\) - * end - * - * module Value = struct - * type renaming = string * (string * access_path) (\* src -> dst *\) - * type renamings = renaming list - * let filter (r:renamings) (s:string) : renamings = - * List.filter (fun (x, _) -> not (x = s)) r - * let filters (r:renamings) (ss:string list) : renamings = - * List.filter (fun (x, _) -> not (List.mem x ss)) r - * - * let rec rename_instruction (r:renamings) (i:instruction) : instruction result = - * match i with - * | I_assignment ({name;annotated_expression = e} as a) -> ( - * match List.assoc_opt name r with - * | None -> - * let%bind annotated_expression = rename_annotated_expression (filter r name) e in - * ok (I_assignment {a with annotated_expression}) - * | Some (name', lst) -> ( - * let%bind annotated_expression = rename_annotated_expression r e in - * match lst with - * | [] -> ok (I_assignment {name = name' ; annotated_expression}) - * | lst -> - * let (hds, tl) = - * let open List in - * let r = rev lst in - * rev @@ tl r, hd r - * in - * let%bind tl' = match tl with - * | Access_record n -> ok n - * | Access_tuple _ -> simple_fail "no support for renaming into tuples yet" in - * ok (I_record_patch (name', hds, [tl', annotated_expression])) - * ) - * ) - * | I_skip -> ok I_skip - * | I_fail e -> - * let%bind e' = rename_annotated_expression r e in - * ok (I_fail e') - * | I_loop (cond, body) -> - * let%bind cond' = rename_annotated_expression r cond in - * let%bind body' = rename_block r body in - * ok (I_loop (cond', body')) - * | I_matching (ae, m) -> - * let%bind ae' = rename_annotated_expression r ae in - * let%bind m' = rename_matching rename_block r m in - * ok (I_matching (ae', m')) - * | I_record_patch (v, path, lst) -> - * let aux (x, y) = - * let%bind y' = rename_annotated_expression (filter r v) y in - * ok (x, y') in - * let%bind lst' = bind_map_list aux lst in - * match List.assoc_opt v r with - * | None -> ( - * ok (I_record_patch (v, path, lst')) - * ) - * | Some (v', path') -> ( - * ok (I_record_patch (v', path' @ path, lst')) - * ) - * and rename_block (r:renamings) (bl:block) : block result = - * bind_map_list (rename_instruction r) bl - * - * and rename_matching : type a . (renamings -> a -> a result) -> renamings -> a matching -> a matching result = - * fun f r m -> - * match m with - * | Match_bool { match_true = mt ; match_false = mf } -> - * let%bind match_true = f r mt in - * let%bind match_false = f r mf in - * ok (Match_bool {match_true ; match_false}) - * | Match_option { match_none = mn ; match_some = (some, ms) } -> - * let%bind match_none = f r mn in - * let%bind ms' = f (filter r some) ms in - * ok (Match_option {match_none ; match_some = (some, ms')}) - * | Match_list { match_nil = mn ; match_cons = (hd, tl, mc) } -> - * let%bind match_nil = f r mn in - * let%bind mc' = f (filters r [hd;tl]) mc in - * ok (Match_list {match_nil ; match_cons = (hd, tl, mc')}) - * | Match_tuple (lst, body) -> - * let%bind body' = f (filters r lst) body in - * ok (Match_tuple (lst, body')) - * - * and rename_matching_instruction = fun x -> rename_matching rename_block x - * - * and rename_matching_expr = fun x -> rename_matching rename_expression x - * - * and rename_annotated_expression (r:renamings) (ae:annotated_expression) : annotated_expression result = - * let%bind expression = rename_expression r ae.expression in - * ok {ae with expression} - * - * and rename_expression : renamings -> expression -> expression result = fun r e -> - * match e with - * | E_literal _ as l -> ok l - * | E_constant (name, lst) -> - * let%bind lst' = bind_map_list (rename_annotated_expression r) lst in - * ok (E_constant (name, lst')) - * | E_constructor (name, ae) -> - * let%bind ae' = rename_annotated_expression r ae in - * ok (E_constructor (name, ae')) - * | E_variable v -> ( - * match List.assoc_opt v r with - * | None -> ok (E_variable v) - * | Some (name, path) -> ok (E_accessor (ae (E_variable (name)), path)) - * ) - * | E_lambda ({binder;body;result} as l) -> - * let r' = filter r binder in - * let%bind body = rename_block r' body in - * let%bind result = rename_annotated_expression r' result in - * ok (E_lambda {l with body ; result}) - * | E_application (f, arg) -> - * let%bind f' = rename_annotated_expression r f in - * let%bind arg' = rename_annotated_expression r arg in - * ok (E_application (f', arg')) - * | E_tuple lst -> - * let%bind lst' = bind_map_list (rename_annotated_expression r) lst in - * ok (E_tuple lst') - * | E_accessor (ae, p) -> - * let%bind ae' = rename_annotated_expression r ae in - * ok (E_accessor (ae', p)) - * | E_record sm -> - * let%bind sm' = bind_smap - * @@ SMap.map (rename_annotated_expression r) sm in - * ok (E_record sm') - * | E_map m -> - * let%bind m' = bind_map_list - * (fun (x, y) -> bind_map_pair (rename_annotated_expression r) (x, y)) m in - * ok (E_map m') - * | E_list lst -> - * let%bind lst' = bind_map_list (rename_annotated_expression r) lst in - * ok (E_list lst') - * | E_look_up m -> - * let%bind m' = bind_map_pair (rename_annotated_expression r) m in - * ok (E_look_up m') - * | E_matching (ae, m) -> - * let%bind ae' = rename_annotated_expression r ae in - * let%bind m' = rename_matching rename_annotated_expression r m in - * ok (E_matching (ae', m')) - * end - * end *) diff --git a/src/stages/1-ast_imperative/misc.mli b/src/stages/1-ast_imperative/misc.mli deleted file mode 100644 index 0784d109c..000000000 --- a/src/stages/1-ast_imperative/misc.mli +++ /dev/null @@ -1,20 +0,0 @@ -open Trace -open Types - - -(* - -module Errors : sig - val different_literals_because_different_types : name -> literal -> literal -> unit -> error - - val different_literals : name -> literal -> literal -> unit -> error - - val error_uncomparable_literals : name -> literal -> literal -> unit -> error -end - -val assert_literal_eq : ( literal * literal ) -> unit result -*) - -val assert_value_eq : ( expression * expression ) -> unit result - -val is_value_eq : ( expression * expression ) -> bool diff --git a/src/stages/2-ast_sugar/ast_sugar.ml b/src/stages/2-ast_sugar/ast_sugar.ml index e9614490a..7fa34e677 100644 --- a/src/stages/2-ast_sugar/ast_sugar.ml +++ b/src/stages/2-ast_sugar/ast_sugar.ml @@ -3,6 +3,5 @@ include Types (* include Misc *) include Combinators module Types = Types -module Misc = Misc module PP=PP module Combinators = Combinators diff --git a/src/stages/2-ast_sugar/misc.ml b/src/stages/2-ast_sugar/misc.ml deleted file mode 100644 index f65e95796..000000000 --- a/src/stages/2-ast_sugar/misc.ml +++ /dev/null @@ -1,350 +0,0 @@ -open Trace -open Types - -open Stage_common.Helpers -module Errors = struct - let different_literals_because_different_types name a b () = - let title () = "literals have different types: " ^ name in - let message () = "" in - let data = [ - ("a" , fun () -> Format.asprintf "%a" PP.literal a) ; - ("b" , fun () -> Format.asprintf "%a" PP.literal b ) - ] in - error ~data title message () - - let different_literals name a b () = - let title () = name ^ " are different" in - let message () = "" in - let data = [ - ("a" , fun () -> Format.asprintf "%a" PP.literal a) ; - ("b" , fun () -> Format.asprintf "%a" PP.literal b ) - ] in - error ~data title message () - - let error_uncomparable_literals name a b () = - let title () = name ^ " are not comparable" in - let message () = "" in - let data = [ - ("a" , fun () -> Format.asprintf "%a" PP.literal a) ; - ("b" , fun () -> Format.asprintf "%a" PP.literal b ) - ] in - error ~data title message () -end -open Errors - -let assert_literal_eq (a, b : literal * literal) : unit result = - match (a, b) with - | Literal_int a, Literal_int b when a = b -> ok () - | Literal_int _, Literal_int _ -> fail @@ different_literals "different ints" a b - | Literal_int _, _ -> fail @@ different_literals_because_different_types "int vs non-int" a b - | Literal_nat a, Literal_nat b when a = b -> ok () - | Literal_nat _, Literal_nat _ -> fail @@ different_literals "different nats" a b - | Literal_nat _, _ -> fail @@ different_literals_because_different_types "nat vs non-nat" a b - | Literal_timestamp a, Literal_timestamp b when a = b -> ok () - | Literal_timestamp _, Literal_timestamp _ -> fail @@ different_literals "different timestamps" a b - | Literal_timestamp _, _ -> fail @@ different_literals_because_different_types "timestamp vs non-timestamp" a b - | Literal_mutez a, Literal_mutez b when a = b -> ok () - | Literal_mutez _, Literal_mutez _ -> fail @@ different_literals "different tezs" a b - | Literal_mutez _, _ -> fail @@ different_literals_because_different_types "tez vs non-tez" a b - | Literal_string a, Literal_string b when a = b -> ok () - | Literal_string _, Literal_string _ -> fail @@ different_literals "different strings" a b - | Literal_string _, _ -> fail @@ different_literals_because_different_types "string vs non-string" a b - | Literal_bytes a, Literal_bytes b when a = b -> ok () - | Literal_bytes _, Literal_bytes _ -> fail @@ different_literals "different bytess" a b - | Literal_bytes _, _ -> fail @@ different_literals_because_different_types "bytes vs non-bytes" a b - | Literal_void, Literal_void -> ok () - | Literal_void, _ -> fail @@ different_literals_because_different_types "void vs non-void" a b - | Literal_unit, Literal_unit -> ok () - | Literal_unit, _ -> fail @@ different_literals_because_different_types "unit vs non-unit" a b - | Literal_address a, Literal_address b when a = b -> ok () - | Literal_address _, Literal_address _ -> fail @@ different_literals "different addresss" a b - | Literal_address _, _ -> fail @@ different_literals_because_different_types "address vs non-address" a b - | Literal_operation _, Literal_operation _ -> fail @@ error_uncomparable_literals "can't compare operations" a b - | Literal_operation _, _ -> fail @@ different_literals_because_different_types "operation vs non-operation" a b - | Literal_signature a, Literal_signature b when a = b -> ok () - | Literal_signature _, Literal_signature _ -> fail @@ different_literals "different signature" a b - | Literal_signature _, _ -> fail @@ different_literals_because_different_types "signature vs non-signature" a b - | Literal_key a, Literal_key b when a = b -> ok () - | Literal_key _, Literal_key _ -> fail @@ different_literals "different key" a b - | Literal_key _, _ -> fail @@ different_literals_because_different_types "key vs non-key" a b - | Literal_key_hash a, Literal_key_hash b when a = b -> ok () - | Literal_key_hash _, Literal_key_hash _ -> fail @@ different_literals "different key_hash" a b - | Literal_key_hash _, _ -> fail @@ different_literals_because_different_types "key_hash vs non-key_hash" a b - | Literal_chain_id a, Literal_chain_id b when a = b -> ok () - | Literal_chain_id _, Literal_chain_id _ -> fail @@ different_literals "different chain_id" a b - | Literal_chain_id _, _ -> fail @@ different_literals_because_different_types "chain_id vs non-chain_id" a b - -let rec assert_value_eq (a, b: (expression * expression )) : unit result = - Format.printf "in assert_value_eq %a %a\n%!" PP.expression a PP.expression b; - let error_content () = - Format.asprintf "\n@[- %a@;- %a]" PP.expression a PP.expression b - in - trace (fun () -> error (thunk "not equal") error_content ()) @@ - match (a.expression_content , b.expression_content) with - | E_literal a , E_literal b -> - assert_literal_eq (a, b) - | E_literal _ , _ -> - simple_fail "comparing a literal with not a literal" - | E_constant (ca) , E_constant (cb) when ca.cons_name = cb.cons_name -> ( - let%bind lst = - generic_try (simple_error "constants with different number of elements") - (fun () -> List.combine ca.arguments cb.arguments) in - let%bind _all = bind_list @@ List.map assert_value_eq lst in - ok () - ) - | E_constant _ , E_constant _ -> - simple_fail "different constants" - | E_constant _ , _ -> - let error_content () = - Format.asprintf "%a vs %a" - PP.expression a - PP.expression b - in - fail @@ (fun () -> error (thunk "comparing constant with other expression") error_content ()) - - | E_constructor (ca), E_constructor (cb) when ca.constructor = cb.constructor -> ( - let%bind _eq = assert_value_eq (ca.element, cb.element) in - ok () - ) - | E_constructor _, E_constructor _ -> - simple_fail "different constructors" - | E_constructor _, _ -> - simple_fail "comparing constructor with other expression" - - - | E_record sma, E_record smb -> ( - let aux _ a b = - match a, b with - | Some a, Some b -> Some (assert_value_eq (a, b)) - | _ -> Some (simple_fail "different record keys") - in - let%bind _all = bind_lmap @@ LMap.merge aux sma smb in - ok () - ) - | E_record _, _ -> - simple_fail "comparing record with other expression" - - | E_record_update ura, E_record_update urb -> - let _ = - generic_try (simple_error "Updating different record") @@ - fun () -> assert_value_eq (ura.record, urb.record) in - let aux (Label a,Label b) = - assert (String.equal a b) - in - let () = aux (ura.path, urb.path) in - let%bind () = assert_value_eq (ura.update,urb.update) in - ok () - | E_record_update _, _ -> - simple_fail "comparing record update with other expression" - - | E_tuple lsta, E_tuple lstb -> ( - let%bind lst = - generic_try (simple_error "tuples with different number of elements") - (fun () -> List.combine lsta lstb) in - let%bind _all = bind_list @@ List.map assert_value_eq lst in - ok () - ) - | E_tuple _, _ -> - simple_fail "comparing tuple with other expression" - - | E_tuple_update uta, E_tuple_update utb -> - let _ = - generic_try (simple_error "Updating different tuple") @@ - fun () -> assert_value_eq (uta.tuple, utb.tuple) in - let () = assert (uta.path == utb.path) in - let%bind () = assert_value_eq (uta.update,utb.update) in - ok () - | E_tuple_update _, _ -> - simple_fail "comparing tuple update with other expression" - - | (E_map lsta, E_map lstb | E_big_map lsta, E_big_map lstb) -> ( - let%bind lst = generic_try (simple_error "maps of different lengths") - (fun () -> - let lsta' = List.sort compare lsta in - let lstb' = List.sort compare lstb in - List.combine lsta' lstb') in - let aux = fun ((ka, va), (kb, vb)) -> - let%bind _ = assert_value_eq (ka, kb) in - let%bind _ = assert_value_eq (va, vb) in - ok () in - let%bind _all = bind_map_list aux lst in - ok () - ) - | (E_map _ | E_big_map _), _ -> - simple_fail "comparing map with other expression" - - | E_list lsta, E_list lstb -> ( - let%bind lst = - generic_try (simple_error "list of different lengths") - (fun () -> List.combine lsta lstb) in - let%bind _all = bind_map_list assert_value_eq lst in - ok () - ) - | E_list _, _ -> - simple_fail "comparing list with other expression" - - | E_set lsta, E_set lstb -> ( - let lsta' = List.sort (compare) lsta in - let lstb' = List.sort (compare) lstb in - let%bind lst = - generic_try (simple_error "set of different lengths") - (fun () -> List.combine lsta' lstb') in - let%bind _all = bind_map_list assert_value_eq lst in - ok () - ) - | E_set _, _ -> - simple_fail "comparing set with other expression" - - | (E_ascription a , _b') -> assert_value_eq (a.anno_expr , b) - | (_a' , E_ascription b) -> assert_value_eq (a , b.anno_expr) - | (E_variable _, _) | (E_lambda _, _) - | (E_application _, _) | (E_let_in _, _) - | (E_recursive _,_) - | (E_record_accessor _, _) | (E_tuple_accessor _, _) - | (E_look_up _, _) - | (E_matching _, _) | (E_cond _, _) - | (E_sequence _, _) | (E_skip, _) -> simple_fail "comparing not a value" - -let is_value_eq (a , b) = to_bool @@ assert_value_eq (a , b) - -(* module Rename = struct - * open Trace - * - * module Type = struct - * (\* Type renaming, not needed. Yet. *\) - * end - * - * module Value = struct - * type renaming = string * (string * access_path) (\* src -> dst *\) - * type renamings = renaming list - * let filter (r:renamings) (s:string) : renamings = - * List.filter (fun (x, _) -> not (x = s)) r - * let filters (r:renamings) (ss:string list) : renamings = - * List.filter (fun (x, _) -> not (List.mem x ss)) r - * - * let rec rename_instruction (r:renamings) (i:instruction) : instruction result = - * match i with - * | I_assignment ({name;annotated_expression = e} as a) -> ( - * match List.assoc_opt name r with - * | None -> - * let%bind annotated_expression = rename_annotated_expression (filter r name) e in - * ok (I_assignment {a with annotated_expression}) - * | Some (name', lst) -> ( - * let%bind annotated_expression = rename_annotated_expression r e in - * match lst with - * | [] -> ok (I_assignment {name = name' ; annotated_expression}) - * | lst -> - * let (hds, tl) = - * let open List in - * let r = rev lst in - * rev @@ tl r, hd r - * in - * let%bind tl' = match tl with - * | Access_record n -> ok n - * | Access_tuple _ -> simple_fail "no support for renaming into tuples yet" in - * ok (I_record_patch (name', hds, [tl', annotated_expression])) - * ) - * ) - * | I_skip -> ok I_skip - * | I_fail e -> - * let%bind e' = rename_annotated_expression r e in - * ok (I_fail e') - * | I_loop (cond, body) -> - * let%bind cond' = rename_annotated_expression r cond in - * let%bind body' = rename_block r body in - * ok (I_loop (cond', body')) - * | I_matching (ae, m) -> - * let%bind ae' = rename_annotated_expression r ae in - * let%bind m' = rename_matching rename_block r m in - * ok (I_matching (ae', m')) - * | I_record_patch (v, path, lst) -> - * let aux (x, y) = - * let%bind y' = rename_annotated_expression (filter r v) y in - * ok (x, y') in - * let%bind lst' = bind_map_list aux lst in - * match List.assoc_opt v r with - * | None -> ( - * ok (I_record_patch (v, path, lst')) - * ) - * | Some (v', path') -> ( - * ok (I_record_patch (v', path' @ path, lst')) - * ) - * and rename_block (r:renamings) (bl:block) : block result = - * bind_map_list (rename_instruction r) bl - * - * and rename_matching : type a . (renamings -> a -> a result) -> renamings -> a matching -> a matching result = - * fun f r m -> - * match m with - * | Match_bool { match_true = mt ; match_false = mf } -> - * let%bind match_true = f r mt in - * let%bind match_false = f r mf in - * ok (Match_bool {match_true ; match_false}) - * | Match_option { match_none = mn ; match_some = (some, ms) } -> - * let%bind match_none = f r mn in - * let%bind ms' = f (filter r some) ms in - * ok (Match_option {match_none ; match_some = (some, ms')}) - * | Match_list { match_nil = mn ; match_cons = (hd, tl, mc) } -> - * let%bind match_nil = f r mn in - * let%bind mc' = f (filters r [hd;tl]) mc in - * ok (Match_list {match_nil ; match_cons = (hd, tl, mc')}) - * | Match_tuple (lst, body) -> - * let%bind body' = f (filters r lst) body in - * ok (Match_tuple (lst, body')) - * - * and rename_matching_instruction = fun x -> rename_matching rename_block x - * - * and rename_matching_expr = fun x -> rename_matching rename_expression x - * - * and rename_annotated_expression (r:renamings) (ae:annotated_expression) : annotated_expression result = - * let%bind expression = rename_expression r ae.expression in - * ok {ae with expression} - * - * and rename_expression : renamings -> expression -> expression result = fun r e -> - * match e with - * | E_literal _ as l -> ok l - * | E_constant (name, lst) -> - * let%bind lst' = bind_map_list (rename_annotated_expression r) lst in - * ok (E_constant (name, lst')) - * | E_constructor (name, ae) -> - * let%bind ae' = rename_annotated_expression r ae in - * ok (E_constructor (name, ae')) - * | E_variable v -> ( - * match List.assoc_opt v r with - * | None -> ok (E_variable v) - * | Some (name, path) -> ok (E_accessor (ae (E_variable (name)), path)) - * ) - * | E_lambda ({binder;body;result} as l) -> - * let r' = filter r binder in - * let%bind body = rename_block r' body in - * let%bind result = rename_annotated_expression r' result in - * ok (E_lambda {l with body ; result}) - * | E_application (f, arg) -> - * let%bind f' = rename_annotated_expression r f in - * let%bind arg' = rename_annotated_expression r arg in - * ok (E_application (f', arg')) - * | E_tuple lst -> - * let%bind lst' = bind_map_list (rename_annotated_expression r) lst in - * ok (E_tuple lst') - * | E_accessor (ae, p) -> - * let%bind ae' = rename_annotated_expression r ae in - * ok (E_accessor (ae', p)) - * | E_record sm -> - * let%bind sm' = bind_smap - * @@ SMap.map (rename_annotated_expression r) sm in - * ok (E_record sm') - * | E_map m -> - * let%bind m' = bind_map_list - * (fun (x, y) -> bind_map_pair (rename_annotated_expression r) (x, y)) m in - * ok (E_map m') - * | E_list lst -> - * let%bind lst' = bind_map_list (rename_annotated_expression r) lst in - * ok (E_list lst') - * | E_look_up m -> - * let%bind m' = bind_map_pair (rename_annotated_expression r) m in - * ok (E_look_up m') - * | E_matching (ae, m) -> - * let%bind ae' = rename_annotated_expression r ae in - * let%bind m' = rename_matching rename_annotated_expression r m in - * ok (E_matching (ae', m')) - * end - * end *) diff --git a/src/stages/2-ast_sugar/misc.mli b/src/stages/2-ast_sugar/misc.mli deleted file mode 100644 index 0784d109c..000000000 --- a/src/stages/2-ast_sugar/misc.mli +++ /dev/null @@ -1,20 +0,0 @@ -open Trace -open Types - - -(* - -module Errors : sig - val different_literals_because_different_types : name -> literal -> literal -> unit -> error - - val different_literals : name -> literal -> literal -> unit -> error - - val error_uncomparable_literals : name -> literal -> literal -> unit -> error -end - -val assert_literal_eq : ( literal * literal ) -> unit result -*) - -val assert_value_eq : ( expression * expression ) -> unit result - -val is_value_eq : ( expression * expression ) -> bool diff --git a/src/stages/4-ast_typed/.gitignore b/src/stages/4-ast_typed/.gitignore index 39f5407d5..189a4ee60 100644 --- a/src/stages/4-ast_typed/.gitignore +++ b/src/stages/4-ast_typed/.gitignore @@ -1,2 +1,3 @@ /generated_fold.ml - +/generated_map.ml +/generated_o.ml diff --git a/src/stages/4-ast_typed/PP.ml b/src/stages/4-ast_typed/PP.ml index 5691cac65..08e2f778c 100644 --- a/src/stages/4-ast_typed/PP.ml +++ b/src/stages/4-ast_typed/PP.ml @@ -326,8 +326,10 @@ and matching : (formatter -> expression -> unit) -> _ -> matching_expr -> unit = let declaration ppf (d : declaration) = match d with - | Declaration_constant {binder; expr; inline; post_env=_} -> + | Declaration_constant {binder; expr; inline} -> fprintf ppf "const %a = %a%a" expression_variable binder expression expr option_inline inline + | Declaration_type {type_binder; type_expr} -> + fprintf ppf "type %a = %a" type_variable type_binder type_expression type_expr let program ppf (p : program) = fprintf ppf "@[%a@]" diff --git a/src/stages/4-ast_typed/PP_generic.ml b/src/stages/4-ast_typed/PP_generic.ml index c36fcebcb..1e503ace6 100644 --- a/src/stages/4-ast_typed/PP_generic.ml +++ b/src/stages/4-ast_typed/PP_generic.ml @@ -1,116 +1,119 @@ +open Types open Fold open Format open PP_helpers -let needs_parens = { - generic = (fun state info -> - match info.node_instance.instance_kind with - | RecordInstance _ -> false - | VariantInstance _ -> true - | PolyInstance { poly =_; arguments=_; poly_continue } -> - (poly_continue state) - ); - type_variable = (fun _ _ _ -> true) ; - bool = (fun _ _ _ -> false) ; - int = (fun _ _ _ -> false) ; - z = (fun _ _ _ -> false) ; - string = (fun _ _ _ -> false) ; - ligo_string = (fun _ _ _ -> false) ; - bytes = (fun _ _ _ -> false) ; - unit = (fun _ _ _ -> false) ; - packed_internal_operation = (fun _ _ _ -> false) ; - expression_variable = (fun _ _ _ -> false) ; - constructor' = (fun _ _ _ -> false) ; - location = (fun _ _ _ -> false) ; - label = (fun _ _ _ -> false) ; - ast_core_type_expression = (fun _ _ _ -> true) ; - constructor_map = (fun _ _ _ _ -> false) ; - label_map = (fun _ _ _ _ -> false) ; - list = (fun _ _ _ _ -> false) ; - location_wrap = (fun _ _ _ _ -> false) ; - option = (fun _visitor _continue _state o -> - match o with None -> false | Some _ -> true) ; - poly_unionfind = (fun _ _ _ _ -> false) ; - poly_set = (fun _ _ _ _ -> false) ; - typeVariableMap = (fun _ _ _ _ -> false) ; - } +module M = struct + type no_state = NoState + let needs_parens = { + generic = (fun NoState info -> + match info.node_instance.instance_kind with + | RecordInstance _ -> false + | VariantInstance _ -> true + | PolyInstance { poly =_; arguments=_; poly_continue } -> + (poly_continue NoState) + ); + generic_empty_ctor = (fun _ -> false) ; + type_variable = (fun _ _ _ -> true) ; + bool = (fun _ _ _ -> false) ; + int = (fun _ _ _ -> false) ; + z = (fun _ _ _ -> false) ; + string = (fun _ _ _ -> false) ; + ligo_string = (fun _ _ _ -> false) ; + bytes = (fun _ _ _ -> false) ; + unit = (fun _ _ _ -> false) ; + packed_internal_operation = (fun _ _ _ -> false) ; + expression_variable = (fun _ _ _ -> false) ; + constructor' = (fun _ _ _ -> false) ; + location = (fun _ _ _ -> false) ; + label = (fun _ _ _ -> false) ; + ast_core_type_expression = (fun _ _ _ -> true) ; + constructor_map = (fun _ _ _ _ -> false) ; + label_map = (fun _ _ _ _ -> false) ; + list = (fun _ _ _ _ -> false) ; + location_wrap = (fun _ _ _ _ -> false) ; + option = (fun _visitor _continue _state o -> + match o with None -> false | Some _ -> true) ; + poly_unionfind = (fun _ _ _ _ -> false) ; + poly_set = (fun _ _ _ _ -> false) ; + typeVariableMap = (fun _ _ _ _ -> false) ; + } -let op ppf = { - generic = (fun () info -> - match info.node_instance.instance_kind with - | RecordInstance { fields } -> - let aux ppf (fld : 'x Adt_info.ctor_or_field_instance) = - fprintf ppf "%s = %a" fld.cf.name (fun _ppf -> fld.cf_continue) () in - fprintf ppf "{@,@[ %a @]@,}" (list_sep aux (fun ppf () -> fprintf ppf " ;@ ")) fields - | VariantInstance { constructor ; _ } -> - if constructor.cf_new_fold needs_parens false - then fprintf ppf "%s (%a)" constructor.cf.name (fun _ppf -> constructor.cf_continue) () - else let spc = if String.equal constructor.cf.type_ "" then "" else " " in - fprintf ppf "%s%s%a" constructor.cf.name spc (fun _ppf -> constructor.cf_continue) () - | PolyInstance { poly=_; arguments=_; poly_continue } -> - (poly_continue ()) - ); - int = (fun _visitor () i -> fprintf ppf "%i" i ); - type_variable = (fun _visitor () type_variable -> fprintf ppf "Var %a" Var.pp type_variable) ; - bool = (fun _visitor () b -> fprintf ppf "%s" (if b then "true" else "false")) ; - z = (fun _visitor () i -> fprintf ppf "%a" Z.pp_print i) ; - string = (fun _visitor () str -> fprintf ppf "\"%s\"" str) ; - ligo_string = (fun _visitor () str -> fprintf ppf "%a" Ligo_string.pp str) ; - bytes = (fun _visitor () _bytes -> fprintf ppf "bytes...") ; - unit = (fun _visitor () () -> fprintf ppf "()") ; - packed_internal_operation = (fun _visitor () _op -> fprintf ppf "Operation(...bytes)") ; - expression_variable = (fun _visitor () ev -> fprintf ppf "%a" Var.pp ev) ; - constructor' = (fun _visitor () (Constructor c) -> fprintf ppf "Constructor %s" c) ; - location = (fun _visitor () loc -> fprintf ppf "%a" Location.pp loc) ; - label = (fun _visitor () (Label lbl) -> fprintf ppf "Label %s" lbl) ; - ast_core_type_expression = (fun _visitor () te -> fprintf ppf "%a" Ast_core.PP.type_expression te) ; - constructor_map = (fun _visitor continue () cmap -> - let lst = List.sort (fun (Constructor a, _) (Constructor b, _) -> String.compare a b) (CMap.bindings cmap) in - let aux ppf (Constructor k, v) = - fprintf ppf "(Constructor %s, %a)" k (fun _ppf -> continue ()) v in - fprintf ppf "CMap [@,@[ %a @]@,]" (list_sep aux (fun ppf () -> fprintf ppf " ; ")) lst); - label_map = (fun _visitor continue () lmap -> - let lst = List.sort (fun (Label a, _) (Label b, _) -> String.compare a b) (LMap.bindings lmap) in - let aux ppf (Label k, v) = - fprintf ppf "(Constructor %s, %a)" k (fun _ppf -> continue ()) v in - fprintf ppf "LMap [@,@[ %a @]@,]" (list_sep aux (fun ppf () -> fprintf ppf " ; ")) lst); - list = (fun _visitor continue () lst -> - let aux ppf elt = - fprintf ppf "%a" (fun _ppf -> continue ()) elt in - fprintf ppf "[@,@[ %a @]@,]" (list_sep aux (fun ppf () -> fprintf ppf " ;@ ")) lst); - location_wrap = (fun _visitor continue () lwrap -> - let ({ wrap_content; location } : _ Location.wrap) = lwrap in - fprintf ppf "{ wrap_content = %a ; location = %a }" (fun _ppf -> continue ()) wrap_content Location.pp location); - (* list_ne = (fun _visitor continue () (first, lst) -> - let aux ppf elt = - fprintf ppf "%a" (fun _ppf -> continue ()) elt in - fprintf ppf "[@,@[ %a @]@,]" (list_sep aux (fun ppf () -> fprintf ppf " ;@ ")) (first::lst)); *) - option = (fun _visitor continue () o -> - match o with - | None -> fprintf ppf "None" - | Some v -> fprintf ppf "%a" (fun _ppf -> continue ()) v) ; - poly_unionfind = (fun _visitor continue () p -> - let lst = (UnionFind.Poly2.partitions p) in - let aux1 l = fprintf ppf "[@,@[ (*%a*) %a @]@,]" - (fun _ppf -> continue ()) (UnionFind.Poly2.repr (List.hd l) p) - (list_sep (fun _ppf -> continue ()) (fun ppf () -> fprintf ppf " ;@ ")) l in - let aux2 = list_sep (fun _ppf -> aux1) (fun ppf () -> fprintf ppf " ;@ ") in - fprintf ppf "UnionFind [@,@[ %a @]@,]" aux2 lst); - poly_set = (fun _visitor continue () set -> - let lst = (RedBlackTrees.PolySet.elements set) in - fprintf ppf "Set [@,@[ %a @]@,]" (list_sep (fun _ppf -> continue ()) (fun ppf () -> fprintf ppf " ;@ ")) lst); - typeVariableMap = (fun _visitor continue () tvmap -> - let lst = List.sort (fun (a, _) (b, _) -> Var.compare a b) (RedBlackTrees.PolyMap.bindings tvmap) in - let aux ppf (k, v) = - fprintf ppf "(Var %a, %a)" Var.pp k (fun _ppf -> continue ()) v in - fprintf ppf "typeVariableMap [@,@[ %a @]@,]" (list_sep aux (fun ppf () -> fprintf ppf " ;@ ")) lst); - } + let op ppf : (no_state, unit) fold_config = { + generic = (fun NoState info -> + match info.node_instance.instance_kind with + | RecordInstance { fields } -> + let aux ppf (fld : ('xi , 'xo) Adt_info.ctor_or_field_instance) = + fprintf ppf "%s = %a" fld.cf.name (fun _ppf -> fld.cf_continue) NoState in + fprintf ppf "{@,@[ %a @]@,}" (list_sep aux (fun ppf () -> fprintf ppf " ;@ ")) fields + | VariantInstance { constructor ; _ } -> + if constructor.cf_new_fold needs_parens NoState + then fprintf ppf "%s (%a)" constructor.cf.name (fun _ppf -> constructor.cf_continue) NoState + else let spc = if String.equal constructor.cf.type_ "" then "" else " " in + fprintf ppf "%s%s%a" constructor.cf.name spc (fun _ppf -> constructor.cf_continue) NoState + | PolyInstance { poly=_; arguments=_; poly_continue } -> + (poly_continue NoState) + ); + generic_empty_ctor = (fun NoState -> ()) ; + int = (fun _visitor NoState i -> fprintf ppf "%i" i ); + type_variable = (fun _visitor NoState type_variable -> fprintf ppf "Var %a" Var.pp type_variable) ; + bool = (fun _visitor NoState b -> fprintf ppf "%s" (if b then "true" else "false")) ; + z = (fun _visitor NoState i -> fprintf ppf "%a" Z.pp_print i) ; + string = (fun _visitor NoState str -> fprintf ppf "\"%s\"" str) ; + ligo_string = (fun _visitor NoState str -> fprintf ppf "%a" Ligo_string.pp str) ; + bytes = (fun _visitor NoState _bytes -> fprintf ppf "bytes...") ; + unit = (fun _visitor NoState () -> fprintf ppf "()") ; + packed_internal_operation = (fun _visitor NoState _op -> fprintf ppf "Operation(...bytes)") ; + expression_variable = (fun _visitor NoState ev -> fprintf ppf "%a" Var.pp ev) ; + constructor' = (fun _visitor NoState (Constructor c) -> fprintf ppf "Constructor %s" c) ; + location = (fun _visitor NoState loc -> fprintf ppf "%a" Location.pp loc) ; + label = (fun _visitor NoState (Label lbl) -> fprintf ppf "Label %s" lbl) ; + ast_core_type_expression = (fun _visitor NoState te -> fprintf ppf "%a" Ast_core.PP.type_expression te) ; + constructor_map = (fun _visitor continue NoState cmap -> + let lst = List.sort (fun (Constructor a, _) (Constructor b, _) -> String.compare a b) (CMap.bindings cmap) in + let aux ppf (Constructor k, v) = + fprintf ppf "(Constructor %s, %a)" k (fun _ppf -> continue NoState) v in + fprintf ppf "CMap [@,@[ %a @]@,]" (list_sep aux (fun ppf () -> fprintf ppf " ; ")) lst); + label_map = (fun _visitor continue NoState lmap -> + let lst = List.sort (fun (Label a, _) (Label b, _) -> String.compare a b) (LMap.bindings lmap) in + let aux ppf (Label k, v) = + fprintf ppf "(Constructor %s, %a)" k (fun _ppf -> continue NoState) v in + fprintf ppf "LMap [@,@[ %a @]@,]" (list_sep aux (fun ppf () -> fprintf ppf " ; ")) lst); + list = (fun _visitor continue NoState lst -> + let aux ppf elt = + fprintf ppf "%a" (fun _ppf -> continue NoState) elt in + fprintf ppf "[@,@[ %a @]@,]" (list_sep aux (fun ppf () -> fprintf ppf " ;@ ")) lst); + location_wrap = (fun _visitor continue NoState lwrap -> + let ({ wrap_content; location } : _ Location.wrap) = lwrap in + fprintf ppf "{ wrap_content = %a ; location = %a }" (fun _ppf -> continue NoState) wrap_content Location.pp location); + option = (fun _visitor continue NoState o -> + match o with + | None -> fprintf ppf "None" + | Some v -> fprintf ppf "%a" (fun _ppf -> continue NoState) v) ; + poly_unionfind = (fun _visitor continue NoState p -> + let lst = (UnionFind.Poly2.partitions p) in + let aux1 l = fprintf ppf "[@,@[ (*%a*) %a @]@,]" + (fun _ppf -> continue NoState) (UnionFind.Poly2.repr (List.hd l) p) + (list_sep (fun _ppf -> continue NoState) (fun ppf () -> fprintf ppf " ;@ ")) l in + let aux2 = list_sep (fun _ppf -> aux1) (fun ppf () -> fprintf ppf " ;@ ") in + fprintf ppf "UnionFind [@,@[ %a @]@,]" aux2 lst); + poly_set = (fun _visitor continue NoState set -> + let lst = (RedBlackTrees.PolySet.elements set) in + fprintf ppf "Set [@,@[ %a @]@,]" (list_sep (fun _ppf -> continue NoState) (fun ppf () -> fprintf ppf " ;@ ")) lst); + typeVariableMap = (fun _visitor continue NoState tvmap -> + let lst = List.sort (fun (a, _) (b, _) -> Var.compare a b) (RedBlackTrees.PolyMap.bindings tvmap) in + let aux ppf (k, v) = + fprintf ppf "(Var %a, %a)" Var.pp k (fun _ppf -> continue NoState) v in + fprintf ppf "typeVariableMap [@,@[ %a @]@,]" (list_sep aux (fun ppf () -> fprintf ppf " ;@ ")) lst); + } -let print : (unit fold_config -> unit -> 'a -> unit) -> formatter -> 'a -> unit = fun fold ppf v -> - fold (op ppf) () v + let print : ((no_state, unit) fold_config -> no_state -> 'a -> unit) -> formatter -> 'a -> unit = fun fold ppf v -> + fold (op ppf) NoState v +end include Fold.Folds(struct - type state = unit ;; + type in_state = M.no_state ;; + type out_state = unit ;; type 'a t = formatter -> 'a -> unit ;; - let f = print ;; + let f = M.print ;; end) diff --git a/src/stages/4-ast_typed/ast.ml b/src/stages/4-ast_typed/ast.ml new file mode 100644 index 000000000..99b532754 --- /dev/null +++ b/src/stages/4-ast_typed/ast.ml @@ -0,0 +1,625 @@ +[@@@warning "-30"] + +open Types_utils + +(* pseudo-typeclasses: interfaces that must be provided for arguments + of the givent polymmorphic types. For now, only one typeclass can + be specified for a given polymorphic type. The implementation is + provided by the Comparable module *) +(*@ typeclass poly_unionfind comparable *) +(*@ typeclass poly_set comparable *) + +type type_constant = + | TC_unit + | TC_string + | TC_bytes + | TC_nat + | TC_int + | TC_mutez + | TC_operation + | TC_address + | TC_key + | TC_key_hash + | TC_chain_id + | TC_signature + | TC_timestamp + | TC_void + +type te_cmap = ctor_content constructor_map +and te_lmap = field_content label_map +and type_meta = ast_core_type_expression option + +and type_content = + | T_sum of te_cmap + | T_record of te_lmap + | T_arrow of arrow + | T_variable of type_variable + | T_constant of type_constant + | T_operator of type_operator + +and arrow = { + type1: type_expression; + type2: type_expression; + } + +and annot_option = string option + +and ctor_content = { + ctor_type : type_expression; + michelson_annotation : annot_option; + ctor_decl_pos : int; +} + +and field_content = { + field_type : type_expression; + michelson_annotation : annot_option; + field_decl_pos : int; +} + +and type_map_args = { + k : type_expression; + v : type_expression; + } + +and michelson_or_args = { + l : type_expression; + r : type_expression; + } + +and type_operator = + | TC_contract of type_expression + | TC_option of type_expression + | TC_list of type_expression + | TC_set of type_expression + | TC_map of type_map_args + | TC_big_map of type_map_args + | TC_map_or_big_map of type_map_args + +and type_expression = { + type_content: type_content; + type_meta: type_meta; + location: location; + } + +type literal = + | Literal_unit + | Literal_int of z + | Literal_nat of z + | Literal_timestamp of z + | Literal_mutez of z + | Literal_string of ligo_string + | Literal_bytes of bytes + | Literal_address of string + | Literal_signature of string + | Literal_key of string + | Literal_key_hash of string + | Literal_chain_id of string + | Literal_void + | Literal_operation of packed_internal_operation + + +and matching_content_cons = { + hd : expression_variable; + tl : expression_variable; + body : expression; + tv : type_expression; + } + +and matching_content_list = { + match_nil : expression ; + match_cons : matching_content_cons; + } + +and matching_content_some = { + opt : expression_variable ; + body : expression ; + tv : type_expression ; + } + +and matching_content_option = { + match_none : expression ; + match_some : matching_content_some ; + } + +and expression_variable_list = expression_variable list +and type_expression_list = type_expression list + +and matching_content_tuple = { + vars : expression_variable_list ; + body : expression ; + tvs : type_expression_list ; + } + +and matching_content_case = { + constructor : constructor' ; + pattern : expression_variable ; + body : expression ; + } + +and matching_content_case_list = matching_content_case list + +and matching_content_variant = { + cases: matching_content_case_list; + tv: type_expression; + } + +and matching_expr = + | Match_list of matching_content_list + | Match_option of matching_content_option + | Match_tuple of matching_content_tuple + | Match_variant of matching_content_variant + +and constant' = + | C_INT + | C_UNIT + | C_NIL + | C_NOW + | C_IS_NAT + | C_SOME + | C_NONE + | C_ASSERTION + | C_ASSERT_INFERRED + | C_FAILWITH + | C_UPDATE + (* Loops *) + | C_ITER + | C_FOLD_WHILE + | C_FOLD_CONTINUE + | C_FOLD_STOP + | C_LOOP_LEFT + | C_LOOP_CONTINUE + | C_LOOP_STOP + | C_FOLD + (* MATH *) + | C_NEG + | C_ABS + | C_ADD + | C_SUB + | C_MUL + | C_EDIV + | C_DIV + | C_MOD + (* LOGIC *) + | C_NOT + | C_AND + | C_OR + | C_XOR + | C_LSL + | C_LSR + (* COMPARATOR *) + | C_EQ + | C_NEQ + | C_LT + | C_GT + | C_LE + | C_GE + (* Bytes/ String *) + | C_SIZE + | C_CONCAT + | C_SLICE + | C_BYTES_PACK + | C_BYTES_UNPACK + | C_CONS + (* Pair *) + | C_PAIR + | C_CAR + | C_CDR + | C_LEFT + | C_RIGHT + (* Set *) + | C_SET_EMPTY + | C_SET_LITERAL + | C_SET_ADD + | C_SET_REMOVE + | C_SET_ITER + | C_SET_FOLD + | C_SET_MEM + (* List *) + | C_LIST_EMPTY + | C_LIST_LITERAL + | C_LIST_ITER + | C_LIST_MAP + | C_LIST_FOLD + (* Maps *) + | C_MAP + | C_MAP_EMPTY + | C_MAP_LITERAL + | C_MAP_GET + | C_MAP_GET_FORCE + | C_MAP_ADD + | C_MAP_REMOVE + | C_MAP_UPDATE + | C_MAP_ITER + | C_MAP_MAP + | C_MAP_FOLD + | C_MAP_MEM + | C_MAP_FIND + | C_MAP_FIND_OPT + (* Big Maps *) + | C_BIG_MAP + | C_BIG_MAP_EMPTY + | C_BIG_MAP_LITERAL + (* Crypto *) + | C_SHA256 + | C_SHA512 + | C_BLAKE2b + | C_HASH + | C_HASH_KEY + | C_CHECK_SIGNATURE + | C_CHAIN_ID + (* Blockchain *) + | C_CALL + | C_CONTRACT + | C_CONTRACT_OPT + | C_CONTRACT_ENTRYPOINT + | C_CONTRACT_ENTRYPOINT_OPT + | C_AMOUNT + | C_BALANCE + | C_SOURCE + | C_SENDER + | C_ADDRESS + | C_SELF + | C_SELF_ADDRESS + | C_IMPLICIT_ACCOUNT + | C_SET_DELEGATE + | C_CREATE_CONTRACT + | C_CONVERT_TO_LEFT_COMB + | C_CONVERT_TO_RIGHT_COMB + | C_CONVERT_FROM_LEFT_COMB + | C_CONVERT_FROM_RIGHT_COMB + +and declaration_loc = declaration location_wrap + +and program = declaration_loc list + +(* A Declaration_constant is described by + * a name + a type-annotated expression + * a boolean indicating whether it should be inlined + * the environment before the declaration (the original environment) + * the environment after the declaration (i.e. with that new declaration added to the original environment). *) +and declaration_constant = { + binder : expression_variable ; + expr : expression ; + inline : bool ; + } + +and declaration_type = { + type_binder : type_variable ; + type_expr : type_expression ; + } + +and declaration = + | Declaration_constant of declaration_constant + | Declaration_type of declaration_type + +and expression = { + expression_content: expression_content ; + location: location ; + type_expression: type_expression ; + } + +and map_kv = { + k : expression ; + v : expression ; + } + +and look_up = { + ds : expression; + ind : expression; + } + +and expression_label_map = expression label_map +and map_kv_list = map_kv list +and expression_list = expression list + +and expression_content = + (* Base *) + | E_literal of literal + | E_constant of constant (* For language constants, like (Cons hd tl) or (plus i j) *) + | E_variable of expression_variable + | E_application of application + | E_lambda of lambda + | E_recursive of recursive + | E_let_in of let_in + (* Variant *) + | E_constructor of constructor (* For user defined constructors *) + | E_matching of matching + (* Record *) + | E_record of expression_label_map + | E_record_accessor of record_accessor + | E_record_update of record_update + +and constant = { + cons_name: constant' ; + arguments: expression_list ; + } + +and application = { + lamb: expression ; + args: expression ; + } + +and lambda = { + binder: expression_variable ; + (* input_type: type_expression option ; *) + (* output_type: type_expression option ; *) + result: expression ; + } + +and let_in = { + let_binder: expression_variable ; + rhs: expression ; + let_result: expression ; + inline : bool ; + } + +and recursive = { + fun_name : expression_variable; + fun_type : type_expression; + lambda : lambda; +} + +and constructor = { + constructor: constructor'; + element: expression ; + } + +and record_accessor = { + record: expression ; + path: label ; + } + +and record_update = { + record: expression ; + path: label ; + update: expression ; + } + +and matching = { + matchee: expression ; + cases: matching_expr ; + } + +and ascription = { + anno_expr: expression ; + type_annotation: type_expression ; + } + +and environment_element_definition = + | ED_binder + | ED_declaration of environment_element_definition_declaration + +and environment_element_definition_declaration = { + expr: expression ; + free_variables: free_variables ; + } + +and free_variables = expression_variable list + +and environment_element = { + type_value: type_expression ; + source_environment: environment ; + definition: environment_element_definition ; + } + +and expression_environment = environment_binding list + +and environment_binding = { + expr_var: expression_variable ; + env_elt: environment_element ; + } + +and type_environment = type_environment_binding list + +and type_environment_binding = { + type_variable: type_variable ; + type_: type_expression ; +} + +and environment = { + expression_environment: expression_environment ; + type_environment: type_environment ; +} + +and named_type_content = { + type_name : type_variable; + type_value : type_expression; + } + + + + + +(* Solver types *) + +(* typevariable: to_string = (fun s -> Format.asprintf "%a" Var.pp s) *) +type unionfind = type_variable poly_unionfind + +(* core *) + +(* add information on the type or the kind for operator *) +type constant_tag = + | C_arrow (* * -> * -> * isn't this wrong? *) + | C_option (* * -> * *) + | C_record (* ( label , * ) … -> * *) + | C_variant (* ( label , * ) … -> * *) + | C_map (* * -> * -> * *) + | C_big_map (* * -> * -> * *) + | C_list (* * -> * *) + | C_set (* * -> * *) + | C_unit (* * *) + | C_string (* * *) + | C_nat (* * *) + | C_mutez (* * *) + | C_timestamp (* * *) + | C_int (* * *) + | C_address (* * *) + | C_bytes (* * *) + | C_key_hash (* * *) + | C_key (* * *) + | C_signature (* * *) + | C_operation (* * *) + | C_contract (* * -> * *) + | C_chain_id (* * *) + +(* TODO: rename to type_expression or something similar (it includes variables, and unevaluated functions + applications *) +type type_value_ = + | P_forall of p_forall + | P_variable of type_variable + | P_constant of p_constant + | P_apply of p_apply +and type_value = { + tsrc : string; + t : type_value_ ; +} + +and p_apply = { + tf : type_value ; + targ : type_value ; +} +and p_ctor_args = type_value list +and p_constant = { + p_ctor_tag : constant_tag ; + p_ctor_args : p_ctor_args ; + } +and p_constraints = type_constraint list +and p_forall = { + binder : type_variable ; + constraints : p_constraints ; + body : type_value ; +} + +(* Different type of constraint *) +and ctor_args = type_variable list (* non-empty list *) +and simple_c_constructor = { + ctor_tag : constant_tag ; + ctor_args : ctor_args ; + } +and simple_c_constant = { + constant_tag: constant_tag ; (* for type constructors that do not take arguments *) + } +and c_const = { + c_const_tvar : type_variable ; + c_const_tval : type_value ; + } +and c_equation = { + aval : type_value ; + bval : type_value ; +} +and tc_args = type_value list +and c_typeclass = { + tc_args : tc_args ; + typeclass : typeclass ; +} +and c_access_label = { + c_access_label_tval : type_value ; + accessor : label ; + c_access_label_tvar : type_variable ; + } + +and type_constraint = { + reason : string ; + c : type_constraint_ ; +} +and type_constraint_ = + (* | C_assignment of (type_variable * type_pattern) *) + | C_equation of c_equation (* TVA = TVB *) + | C_typeclass of c_typeclass (* TVL ∈ TVLs, for now in extension, later add intensional (rule-based system for inclusion in the typeclass) *) + | C_access_label of c_access_label (* poor man's type-level computation to ensure that TV.label is type_variable *) +(* | … *) + +(* is the first list in case on of the type of the type class as a kind *->*->* ? *) +and tc_allowed = type_value list +and typeclass = tc_allowed list + +(* end core *) + +type c_constructor_simpl_typeVariableMap = c_constructor_simpl typeVariableMap +and constraints_typeVariableMap = constraints typeVariableMap +and type_constraint_simpl_list = type_constraint_simpl list +and structured_dbs = { + all_constraints : type_constraint_simpl_list ; + aliases : unionfind ; + (* assignments (passive data structure). *) + (* Now : just a map from unification vars to types (pb: what about partial types?) *) + (* maybe just local assignments (allow only vars as children of pair(α,β)) *) + (* TODO : the rhs of the map should not repeat the variable name. *) + assignments : c_constructor_simpl_typeVariableMap ; + grouped_by_variable : constraints_typeVariableMap ; (* map from (unionfind) variables to constraints containing them *) + cycle_detection_toposort : unit ; (* example of structured db that we'll add later *) +} + +and c_constructor_simpl_list = c_constructor_simpl list +and c_poly_simpl_list = c_poly_simpl list +and c_typeclass_simpl_list = c_typeclass_simpl list +and constraints = { + (* If implemented in a language with decent sets, these should be sets not lists. *) + constructor : c_constructor_simpl_list ; (* List of ('a = constructor(args…)) constraints *) + poly : c_poly_simpl_list ; (* List of ('a = forall 'b, some_type) constraints *) + tc : c_typeclass_simpl_list ; (* List of (typeclass(args…)) constraints *) +} +and type_variable_list = type_variable list +and c_constructor_simpl = { + reason_constr_simpl : string ; + tv : type_variable; + c_tag : constant_tag; + tv_list : type_variable_list; +} +and c_const_e = { + c_const_e_tv : type_variable ; + c_const_e_te : type_expression ; + } +and c_equation_e = { + aex : type_expression ; + bex : type_expression ; + } +and c_typeclass_simpl = { + reason_typeclass_simpl : string ; + tc : typeclass ; + args : type_variable_list ; +} +and c_poly_simpl = { + reason_poly_simpl : string ; + tv : type_variable ; + forall : p_forall ; +} +and type_constraint_simpl = + | SC_Constructor of c_constructor_simpl (* α = ctor(β, …) *) + | SC_Alias of c_alias (* α = β *) + | SC_Poly of c_poly_simpl (* α = forall β, δ where δ can be a more complex type *) + | SC_Typeclass of c_typeclass_simpl (* TC(α, …) *) + +and c_alias = { + reason_alias_simpl : string ; + a : type_variable ; + b : type_variable ; + } + + +(* sub-sub component: lazy selector (don't re-try all selectors every time) *) +(* For now: just re-try everytime *) + +(* selector / propagation rule for breaking down composite types *) +(* For now: break pair(a, b) = pair(c, d) into a = c, b = d *) +type output_break_ctor = { + a_k_var : c_constructor_simpl ; + a_k'_var' : c_constructor_simpl ; + } + +type output_specialize1 = { + poly : c_poly_simpl ; + a_k_var : c_constructor_simpl ; + } + +type m_break_ctor__already_selected = output_break_ctor poly_set +type m_specialize1__already_selected = output_specialize1 poly_set + +type already_selected = { + break_ctor : m_break_ctor__already_selected ; + specialize1 : m_specialize1__already_selected ; +} + +type typer_state = { + structured_dbs : structured_dbs ; + already_selected : already_selected ; +} diff --git a/src/stages/4-ast_typed/ast_typed.ml b/src/stages/4-ast_typed/ast_typed.ml index e78dc9188..b97117f9c 100644 --- a/src/stages/4-ast_typed/ast_typed.ml +++ b/src/stages/4-ast_typed/ast_typed.ml @@ -2,9 +2,9 @@ module Types = Types module Environment = Environment module PP = PP module PP_generic = PP_generic +module Compare_generic = Compare_generic module Combinators = struct include Combinators - include Combinators_environment end module Misc = struct include Misc @@ -15,3 +15,5 @@ module Helpers = Helpers include Types include Misc include Combinators + +let program_environment env program = fst (Compute_environment.program env program) diff --git a/src/stages/4-ast_typed/combinators.ml b/src/stages/4-ast_typed/combinators.ml index e7959cec7..b423da73d 100644 --- a/src/stages/4-ast_typed/combinators.ml +++ b/src/stages/4-ast_typed/combinators.ml @@ -24,10 +24,9 @@ module Errors = struct end let make_t ?(loc = Location.generated) type_content core = {type_content; location=loc; type_meta = core} -let make_e ?(location = Location.generated) expression_content type_expression environment = { +let make_e ?(location = Location.generated) expression_content type_expression = { expression_content ; type_expression ; - environment ; location ; } let make_n_t type_name type_value = { type_name ; type_value } @@ -83,7 +82,6 @@ let t_shallow_closure param result ?loc ?s () : type_expression = make_t ?loc (T let get_type_expression (x:expression) = x.type_expression let get_type' (x:type_expression) = x.type_content -let get_environment (x:expression) = x.environment let get_expression (x:expression) = x.expression_content let get_lambda e : _ result = match e.expression_content with @@ -330,13 +328,13 @@ let e_let_in let_binder inline rhs let_result = E_let_in { let_binder ; rhs ; le let e_constructor constructor element: expression_content = E_constructor {constructor;element} -let e_bool b env : expression_content = e_constructor (Constructor (string_of_bool b)) (make_e (e_unit ())(t_unit()) env) +let e_bool b : expression_content = e_constructor (Constructor (string_of_bool b)) (make_e (e_unit ())(t_unit())) let e_a_unit = make_e (e_unit ()) (t_unit ()) let e_a_int n = make_e (e_int n) (t_int ()) let e_a_nat n = make_e (e_nat n) (t_nat ()) let e_a_mutez n = make_e (e_mutez n) (t_mutez ()) -let e_a_bool b = fun env -> make_e (e_bool b env) (t_bool ()) env +let e_a_bool b = make_e (e_bool b) (t_bool ()) let e_a_string s = make_e (e_string s) (t_string ()) let e_a_address s = make_e (e_address s) (t_address ()) let e_a_pair a b = make_e (e_pair a b) @@ -381,7 +379,8 @@ let get_a_record_accessor = fun t -> let get_declaration_by_name : program -> string -> declaration result = fun p name -> let aux : declaration -> bool = fun declaration -> match declaration with - | Declaration_constant { binder ; expr=_ ; inline=_ ; post_env=_ } -> binder = Var.of_name name + | Declaration_constant { binder ; expr=_ ; inline=_ } -> binder = Var.of_name name + | Declaration_type _ -> false in trace_option (Errors.declaration_not_found name ()) @@ List.find_opt aux @@ List.map Location.unwrap p diff --git a/src/stages/4-ast_typed/combinators.mli b/src/stages/4-ast_typed/combinators.mli index 192939c72..f4fe615b2 100644 --- a/src/stages/4-ast_typed/combinators.mli +++ b/src/stages/4-ast_typed/combinators.mli @@ -3,7 +3,7 @@ open Types val make_n_t : type_variable -> type_expression -> named_type_content val make_t : ?loc:Location.t -> type_content -> S.type_expression option -> type_expression -val make_e : ?location:Location.t -> expression_content -> type_expression -> environment -> expression +val make_e : ?location:Location.t -> expression_content -> type_expression -> expression val t_bool : ?loc:Location.t -> ?s:S.type_expression -> unit -> type_expression val t_string : ?loc:Location.t -> ?s:S.type_expression -> unit -> type_expression @@ -38,7 +38,6 @@ val t_function : type_expression -> type_expression -> ?loc:Location.t -> ?s:S.t val t_shallow_closure : type_expression -> type_expression -> ?loc:Location.t -> ?s:S.type_expression -> unit -> type_expression val get_type_expression : expression -> type_expression val get_type' : type_expression -> type_content -val get_environment : expression -> environment val get_expression : expression -> expression_content val get_lambda : expression -> lambda result val get_lambda_with_type : expression -> (lambda * ( type_expression * type_expression) ) result @@ -119,7 +118,7 @@ val e_unit : unit -> expression_content val e_int : Z.t -> expression_content val e_nat : Z.t -> expression_content val e_mutez : Z.t -> expression_content -val e_bool : bool -> environment -> expression_content +val e_bool : bool -> expression_content val e_string : ligo_string -> expression_content val e_bytes : bytes -> expression_content val e_timestamp : Z.t -> expression_content @@ -135,22 +134,22 @@ val e_application : expression -> expression -> expression_content val e_variable : expression_variable -> expression_content val e_let_in : expression_variable -> inline -> expression -> expression -> expression_content -val e_a_unit : environment -> expression -val e_a_int : Z.t -> environment -> expression -val e_a_nat : Z.t -> environment -> expression -val e_a_mutez : Z.t -> environment -> expression -val e_a_bool : bool -> environment -> expression -val e_a_string : ligo_string -> environment -> expression -val e_a_address : string -> environment -> expression -val e_a_pair : expression -> expression -> environment -> expression -val e_a_some : expression -> environment -> expression -val e_a_lambda : lambda -> type_expression -> type_expression -> environment -> expression -val e_a_none : type_expression -> environment -> expression -val e_a_record : expression label_map -> environment -> expression -val e_a_application : expression -> expression -> environment -> expression -val e_a_variable : expression_variable -> type_expression -> environment -> expression -val ez_e_a_record : ( label * expression ) list -> environment -> expression -val e_a_let_in : expression_variable -> bool -> expression -> expression -> environment -> expression +val e_a_unit : expression +val e_a_int : Z.t -> expression +val e_a_nat : Z.t -> expression +val e_a_mutez : Z.t -> expression +val e_a_bool : bool -> expression +val e_a_string : ligo_string -> expression +val e_a_address : string -> expression +val e_a_pair : expression -> expression -> expression +val e_a_some : expression -> expression +val e_a_lambda : lambda -> type_expression -> type_expression -> expression +val e_a_none : type_expression -> expression +val e_a_record : expression label_map -> expression +val e_a_application : expression -> expression -> expression +val e_a_variable : expression_variable -> type_expression -> expression +val ez_e_a_record : ( label * expression ) list -> expression +val e_a_let_in : expression_variable -> bool -> expression -> expression -> expression val get_a_int : expression -> Z.t result val get_a_unit : expression -> unit result diff --git a/src/stages/4-ast_typed/combinators_environment.ml b/src/stages/4-ast_typed/combinators_environment.ml deleted file mode 100644 index 78e11ad9a..000000000 --- a/src/stages/4-ast_typed/combinators_environment.ml +++ /dev/null @@ -1,25 +0,0 @@ -open Types -open Combinators - -let make_a_e_empty expression type_annotation = make_e expression type_annotation Environment.empty - -let e_a_empty_unit = e_a_unit Environment.empty -let e_a_empty_int n = e_a_int n Environment.empty -let e_a_empty_nat n = e_a_nat n Environment.empty -let e_a_empty_mutez n = e_a_mutez n Environment.empty -let e_a_empty_bool b = e_a_bool b Environment.empty -let e_a_empty_string s = e_a_string s Environment.empty -let e_a_empty_address s = e_a_address s Environment.empty -let e_a_empty_pair a b = e_a_pair a b Environment.empty -let e_a_empty_some s = e_a_some s Environment.empty -let e_a_empty_none t = e_a_none t Environment.empty -let e_a_empty_record r = e_a_record r Environment.empty -let ez_e_a_empty_record r = ez_e_a_record r Environment.empty -let e_a_empty_lambda l i o = e_a_lambda l i o Environment.empty - -open Environment - -let env_sum_type ?(env = empty) - ?(type_name = Var.of_name "a_sum_type") - (lst : (constructor' * ctor_content) list) = - add_type type_name (make_t_ez_sum lst) env diff --git a/src/stages/4-ast_typed/combinators_environment.mli b/src/stages/4-ast_typed/combinators_environment.mli deleted file mode 100644 index 64b325975..000000000 --- a/src/stages/4-ast_typed/combinators_environment.mli +++ /dev/null @@ -1,19 +0,0 @@ -open Types - -val make_a_e_empty : expression_content -> type_expression -> expression - -val e_a_empty_unit : expression -val e_a_empty_int : Z.t -> expression -val e_a_empty_nat : Z.t -> expression -val e_a_empty_mutez : Z.t -> expression -val e_a_empty_bool : bool -> expression -val e_a_empty_string : ligo_string -> expression -val e_a_empty_address : string -> expression -val e_a_empty_pair : expression -> expression -> expression -val e_a_empty_some : expression -> expression -val e_a_empty_none : type_expression -> expression -val e_a_empty_record : expression label_map -> expression -val ez_e_a_empty_record : ( label * expression ) list -> expression -val e_a_empty_lambda : lambda -> type_expression -> type_expression -> expression - -val env_sum_type : ?env:environment -> ?type_name:type_variable -> (constructor' * ctor_content) list -> environment diff --git a/src/stages/4-ast_typed/comparable.ml b/src/stages/4-ast_typed/comparable.ml new file mode 100644 index 000000000..255ed7fbe --- /dev/null +++ b/src/stages/4-ast_typed/comparable.ml @@ -0,0 +1 @@ +include Compare_generic.Comparable diff --git a/src/stages/4-ast_typed/compare_generic.ml b/src/stages/4-ast_typed/compare_generic.ml new file mode 100644 index 000000000..e630f1e3a --- /dev/null +++ b/src/stages/4-ast_typed/compare_generic.ml @@ -0,0 +1,196 @@ +open Types +open Generated_fold + +module M = struct + let compare = () (* Hide Pervasives.compare to avoid calling it without explicit qualification. *) + type 'a lz = unit -> 'a (* Lazy values *) + type t = + | EmptyCtor + | Record of string * (string * t lz) list + | VariantConstructor of string * string * t lz + | Bool of inline + | Bytes of bytes + | Constructor' of string + | Expression_variable of expression_variable + | Int of int + | Label' of string + | Ligo_string of ligo_string + | Location of location + | Operation of packed_internal_operation + | Str of string + | Type_expression of ast_core_type_expression + | Unit of unit + | Var of type_variable + | Z of z + | List of t lz list + | Location_wrap of t lz Location.wrap + | CMap of (constructor' * t lz) list + | LMap of (label * t lz) list + | UnionFind of t lz list list + | Set of t lz list + | TypeVariableMap of (type_variable * t lz) list + + type no_state = NoState + + (* TODO: make these functions return a lazy stucture *) + let op : (no_state, t) fold_config = { + generic = (fun NoState info -> + match info.node_instance.instance_kind with + | RecordInstance { fields } -> + let aux (fld : ('xi, 'xo) Adt_info.ctor_or_field_instance) = + ( fld.cf.name , fun () -> fld.cf_continue NoState ) in + Record ("name_of_the_record", List.map aux fields) + | VariantInstance { constructor ; _ } -> + VariantConstructor ("name_of_the_variant", constructor.cf.name, fun () -> constructor.cf_continue NoState) + | PolyInstance { poly=_; arguments=_; poly_continue } -> + poly_continue NoState + ); + generic_empty_ctor = (fun NoState -> EmptyCtor) ; + int = (fun _visitor _state i -> Int i ); + type_variable = (fun _visitor _state type_variable -> Var type_variable) ; + bool = (fun _visitor _state b -> Bool b) ; + z = (fun _visitor _state i -> Z i) ; + string = (fun _visitor _state str -> Str str) ; + ligo_string = (fun _visitor _state str -> Ligo_string str) ; + bytes = (fun _visitor _state bytes -> Bytes bytes) ; + unit = (fun _visitor _state () -> Unit ()) ; + packed_internal_operation = (fun _visitor _state op -> Operation op) ; + expression_variable = (fun _visitor _state ev -> Expression_variable ev) ; + constructor' = (fun _visitor _state (Constructor c) -> Constructor' c) ; + location = (fun _visitor _state loc -> Location loc) ; + label = (fun _visitor _state (Label lbl) -> Label' lbl) ; + ast_core_type_expression = (fun _visitor _state te -> Type_expression te) ; + constructor_map = (fun _visitor continue _state cmap -> + let kcmp (Constructor a, _) (Constructor b, _) = String.compare a b in + let lst = List.sort kcmp (CMap.bindings cmap) in + CMap (List.map (fun (k, v) -> (k, fun () -> continue NoState v)) lst)); + label_map = (fun _visitor continue _state lmap -> + let kcmp (Label a, _) (Label b, _) = String.compare a b in + let lst = List.sort kcmp (LMap.bindings lmap) in + LMap (List.map (fun (k, v) -> (k, fun () -> continue NoState v)) lst)); + list = (fun _visitor continue _state lst -> + (List (List.map (fun x () -> continue NoState x) lst))); + location_wrap = (fun _visitor continue _state lwrap -> + let ({ wrap_content; location } : _ Location.wrap) = lwrap in + (Location_wrap { wrap_content = (fun () -> continue NoState wrap_content) ; location})); + option = (fun _visitor continue _state o -> + match o with + | None -> VariantConstructor ("built-in:option", "None", fun () -> EmptyCtor) + | Some v -> VariantConstructor ("built-in:option", "Some", fun () -> continue NoState v)); + poly_unionfind = (fun _visitor continue _state p -> + (* UnionFind.Poly2.partitions returns the partitions in a + deterministic order, and the elements within a given + partition also follow a deterministic order. *) + let lst = (UnionFind.Poly2.partitions p) in + let aux l = List.map (fun x () -> continue NoState x) l in + UnionFind (List.map aux lst)); + poly_set = (fun _visitor continue _state set -> + Set (List.map (fun x () -> continue NoState x) (RedBlackTrees.PolySet.elements set))); + typeVariableMap = (fun _visitor continue _state tvmap -> + let kcmp (a, _) (b, _) = Var.compare a b in + let lst = List.sort kcmp (RedBlackTrees.PolyMap.bindings tvmap) in + TypeVariableMap (List.map (fun (k, v) -> (k, fun () -> continue NoState v)) lst)); + } + + let serialize : ((no_state, t) fold_config -> no_state -> 'a -> t) -> 'a -> t = fun fold v -> + fold op NoState v + + (* What follows should be roughly the same for all ASTs, so it + should be easy to share a single copy of that and of the t type + definition above. *) + + (* Generate a unique tag for each case handled below. We can then + compare data by their tag and contents. *) + let tag = function + | EmptyCtor -> 0 + | Record _ -> 1 + | VariantConstructor _ -> 2 + | Bool _ -> 3 + | Bytes _ -> 4 + | Constructor' _ -> 5 + | Expression_variable _ -> 6 + | Int _ -> 7 + | Label' _ -> 8 + | Ligo_string _ -> 9 + | Location _ -> 10 + | Operation _ -> 11 + | Str _ -> 12 + | Type_expression _ -> 13 + | Unit _ -> 14 + | Var _ -> 15 + | Z _ -> 16 + | List _ -> 17 + | Location_wrap _ -> 18 + | CMap _ -> 19 + | LMap _ -> 20 + | UnionFind _ -> 21 + | Set _ -> 22 + | TypeVariableMap _ -> 23 + + let cmp2 f a1 b1 g a2 b2 = match f a1 b1 with 0 -> g a2 b2 | c -> c + let cmp3 f a1 b1 g a2 b2 h a3 b3 = match f a1 b1 with 0 -> (match g a2 b2 with 0 -> h a3 b3 | c -> c) | c -> c + let rec compare_field (na, va) (nb, vb) = cmp2 String.compare na nb compare_lz_t va vb + and compare_cmap_entry (Constructor na, va) (Constructor nb, vb) = cmp2 String.compare na nb compare_lz_t va vb + and compare_lmap_entry (Label na, va) (Label nb, vb) = cmp2 String.compare na nb compare_lz_t va vb + and compare_tvmap_entry (tva, va) (tvb, vb) = cmp2 Var.compare tva tvb compare_lz_t va vb + and compare_lz_t a b = compare_t (a ()) (b ()) + and compare_t (a : t) (b : t) = + match (a, b) with + | (EmptyCtor, EmptyCtor) -> failwith "Should not happen (unless for ctors with no args?)" + | (Record (a, fa), Record (b, fb)) -> cmp2 String.compare a b (List.compare ~compare:compare_field) fa fb + | (VariantConstructor (va, ca, xa), VariantConstructor (vb, cb, xb)) -> + cmp3 + String.compare va vb + String.compare ca cb + compare_lz_t xa xb + | (Bool a, Bool b) -> (Pervasives.compare : bool -> bool -> int) a b + | (Bytes a, Bytes b) -> Bytes.compare a b + | (Constructor' a, Constructor' b) -> String.compare a b + | (Expression_variable a, Expression_variable b) -> Var.compare a b + | (Int a, Int b) -> Int.compare a b + | (Label' a, Label' b) -> String.compare a b + | (Ligo_string a, Ligo_string b) -> Simple_utils.Ligo_string.compare a b + | (Location a, Location b) -> Location.compare a b + | (Operation a, Operation b) -> Pervasives.compare a b (* TODO: is there a proper comparison function defined for packed_internal_operation ? *) + | (Str a, Str b) -> String.compare a b + | (Type_expression a, Type_expression b) -> Pervasives.compare a b (* TODO: is there a proper comparison function defined for ast_core_type_expression ? *) + | (Unit (), Unit ()) -> 0 + | (Var a, Var b) -> Var.compare a b + | (Z a, Z b) -> Z.compare a b + | (List a, List b) -> List.compare ~compare:compare_lz_t a b + | (Location_wrap a, Location_wrap b) -> Location.compare_wrap ~compare:compare_lz_t a b + | (CMap a, CMap b) -> List.compare ~compare:compare_cmap_entry a b + | (LMap a, LMap b) -> List.compare ~compare:compare_lmap_entry a b + | (UnionFind a, UnionFind b) -> List.compare ~compare:(List.compare ~compare:compare_lz_t) a b + | (Set a, Set b) -> List.compare ~compare:compare_lz_t a b + | (TypeVariableMap a, TypeVariableMap b) -> List.compare ~compare:compare_tvmap_entry a b + + | ((EmptyCtor | Record _ | VariantConstructor _ | Bool _ | Bytes _ | Constructor' _ | Expression_variable _ | Int _ | Label' _ | Ligo_string _ | Location _ | Operation _ | Str _ | Type_expression _ | Unit _ | Var _ | Z _ | List _ | Location_wrap _ | CMap _ | LMap _ | UnionFind _ | Set _ | TypeVariableMap _) as a), + ((EmptyCtor | Record _ | VariantConstructor _ | Bool _ | Bytes _ | Constructor' _ | Expression_variable _ | Int _ | Label' _ | Ligo_string _ | Location _ | Operation _ | Str _ | Type_expression _ | Unit _ | Var _ | Z _ | List _ | Location_wrap _ | CMap _ | LMap _ | UnionFind _ | Set _ | TypeVariableMap _) as b) -> + Int.compare (tag a) (tag b) + + + let mk_compare : ((no_state , t) fold_config -> no_state -> 'a -> t) -> 'a -> 'a -> int = fun fold a b -> + compare_t (serialize fold a) (serialize fold b) + + let mk_comparable : ((no_state , t) fold_config -> no_state -> 'a -> t) -> 'a extra_info__comparable = fun fold -> + { compare = mk_compare fold } +end + +(* Generate a comparison function for each type, named like the type itself. *) +include Folds(struct + type in_state = M.no_state ;; + type out_state = M.t ;; + type 'a t = 'a -> 'a -> int ;; + let f = M.mk_compare ;; +end) + +module Comparable = struct + (* Generate a comparator typeclass-like object for each type, named like the type itself. *) + include Folds(struct + type in_state = M.no_state ;; + type out_state = M.t ;; + type 'a t = 'a extra_info__comparable ;; + let f = M.mk_comparable ;; + end) +end diff --git a/src/passes/9-self_ast_typed/recompute_environment.ml b/src/stages/4-ast_typed/compute_environment.ml similarity index 75% rename from src/passes/9-self_ast_typed/recompute_environment.ml rename to src/stages/4-ast_typed/compute_environment.ml index 4124038c2..ce4013a28 100644 --- a/src/passes/9-self_ast_typed/recompute_environment.ml +++ b/src/stages/4-ast_typed/compute_environment.ml @@ -1,23 +1,9 @@ -open Ast_typed - -(* - During the modifications of the passes on `Ast_typed`, the binding - environments are not kept in sync. To palliate this, this module - recomputes them from scratch. -*) - -(* - This module is very coupled to `typer.ml`. Given environments are - not used until the next pass, it makes sense to split this into - its own separate pass. This pass would go from `Ast_typed` without - environments to `Ast_typed` with embedded environments. -*) +open Types let rec expression : environment -> expression -> expression = fun env expr -> (* Standard helper functions to help with the fold *) - let return ?(env' = env) content = { + let return content = { expr with - environment = env' ; expression_content = content ; } in let return_id = return expr.expression_content in @@ -34,9 +20,9 @@ let rec expression : environment -> expression -> expression = fun env expr -> return @@ E_lambda { c with result } ) | E_let_in c -> ( - let env' = Environment.add_ez_declaration c.let_binder c.rhs env in - let let_result = self ~env' c.let_result in let rhs = self c.rhs in + let env' = Environment.add_ez_declaration c.let_binder rhs env in + let let_result = self ~env' c.let_result in return @@ E_let_in { c with rhs ; let_result } ) (* rec fun_name binder -> result *) @@ -90,7 +76,7 @@ and cases : environment -> matching_expr -> matching_expr = fun env cs -> let match_cons = let mc = c.match_cons in let env_hd = Environment.add_ez_binder mc.hd mc.tv env in - let env_tl = Environment.add_ez_binder mc.tl (t_list mc.tv ()) env_hd in + let env_tl = Environment.add_ez_binder mc.tl (Combinators.t_list mc.tv ()) env_hd in let body = self ~env':env_tl mc.body in { mc with body } in @@ -139,24 +125,27 @@ and cases : environment -> matching_expr -> matching_expr = fun env cs -> return @@ Match_variant { c with cases } ) -let program : environment -> program -> program = fun init_env prog -> +let program : environment -> program -> environment * program = fun init_env prog -> (* BAD We take the old type environment and add it to the current value environment because type declarations are removed in the typer. They should be added back. *) - let merge old_env re_env = { - expression_environment = re_env.expression_environment ; - type_environment = old_env.type_environment ; - } in let aux (pre_env , rev_decls) decl_wrapped = - let (Declaration_constant c) = Location.unwrap decl_wrapped in - let expr = expression pre_env c.expr in - let post_env = Environment.add_ez_declaration c.binder c.expr pre_env in - let post_env' = merge c.post_env post_env in - let wrap_content = Declaration_constant { c with expr ; post_env = post_env' } in - let decl_wrapped' = { decl_wrapped with wrap_content } in - (post_env , decl_wrapped' :: rev_decls) + match Location.unwrap decl_wrapped with + | Declaration_constant c -> ( + let expr = expression pre_env c.expr in + let post_env = Environment.add_ez_declaration c.binder expr pre_env in + let wrap_content = Declaration_constant { c with expr } in + let decl_wrapped' = { decl_wrapped with wrap_content } in + (post_env , decl_wrapped' :: rev_decls) + ) + | Declaration_type t -> ( + let post_env = Environment.add_type t.type_binder t.type_expr pre_env in + let wrap_content = Declaration_type t in + let decl_wrapped' = { decl_wrapped with wrap_content } in + (post_env , decl_wrapped' :: rev_decls) + ) in - let (_last_env , rev_decls) = List.fold_left aux (init_env , []) prog in - List.rev rev_decls + let (last_env , rev_decls) = List.fold_left aux (init_env , []) prog in + (last_env , List.rev rev_decls) diff --git a/src/stages/4-ast_typed/dune b/src/stages/4-ast_typed/dune index 874a19c0a..b2993c400 100644 --- a/src/stages/4-ast_typed/dune +++ b/src/stages/4-ast_typed/dune @@ -1,7 +1,7 @@ (rule - (target generated_fold.ml) - (deps ../adt_generator/generator.raku types.ml) - (action (with-stdout-to generated_fold.ml (run perl6 ../adt_generator/generator.raku types.ml))) + (targets generated_fold.ml generated_map.ml generated_o.ml) + (deps ../adt_generator/generator.raku ast.ml) + (action (run perl6 ../adt_generator/generator.raku ast.ml Generated_o generated_o.ml generated_fold.ml generated_map.ml)) (mode (promote (until-clean) (only *))) ) @@ -19,5 +19,6 @@ (preprocess (pps ppx_let bisect_ppx --conditional) ) +;; (modules_without_implementation generated_fold_x) (flags (:standard -open Simple_utils)) ) diff --git a/src/stages/4-ast_typed/environment.ml b/src/stages/4-ast_typed/environment.ml index 30e59ebab..0b9457466 100644 --- a/src/stages/4-ast_typed/environment.ml +++ b/src/stages/4-ast_typed/environment.ml @@ -38,6 +38,9 @@ let add_ez_binder : expression_variable -> type_expression -> t -> t = fun k v e let add_ez_declaration : expression_variable -> expression -> t -> t = fun k ae e -> add_expr k (make_element_declaration e ae) e +let add_ez_sum_type ?(env = empty) ?(type_name = Var.of_name "a_sum_type") (lst : (constructor' * ctor_content) list) = + add_type type_name (make_t_ez_sum lst) env + let convert_constructor' (S.Constructor c) = Constructor c let get_constructor : Ast_core.constructor' -> t -> (type_expression * type_expression) option = fun k x -> (* Left is the constructor, right is the sum type *) @@ -76,4 +79,4 @@ module PP = struct expr_environment (get_expr_environment e) type_environment (get_type_environment e) -end \ No newline at end of file +end diff --git a/src/stages/4-ast_typed/environment.mli b/src/stages/4-ast_typed/environment.mli index 6b3fb52e2..d73279d85 100644 --- a/src/stages/4-ast_typed/environment.mli +++ b/src/stages/4-ast_typed/environment.mli @@ -11,6 +11,7 @@ val get_opt : expression_variable -> t -> element option val get_type_opt : type_variable -> t -> type_expression option val get_constructor : Ast_core.constructor' -> t -> (type_expression * type_expression) option +val add_ez_sum_type : ?env:environment -> ?type_name:type_variable -> (constructor' * ctor_content) list -> environment module PP : sig open Format diff --git a/src/stages/4-ast_typed/fold.ml b/src/stages/4-ast_typed/fold.ml index 271974820..cc02b5fba 100644 --- a/src/stages/4-ast_typed/fold.ml +++ b/src/stages/4-ast_typed/fold.ml @@ -1 +1,3 @@ include Generated_fold +include Generated_map +include Generated_o diff --git a/src/stages/4-ast_typed/misc.ml b/src/stages/4-ast_typed/misc.ml index a3df9718f..537a734f3 100644 --- a/src/stages/4-ast_typed/misc.ml +++ b/src/stages/4-ast_typed/misc.ml @@ -511,28 +511,35 @@ let merge_annotation (a:type_expression option) (b:type_expression option) err : let get_entry (lst : program) (name : string) : expression result = trace_option (Errors.missing_entry_point name) @@ - let aux x = - let (Declaration_constant { binder ; expr ; inline=_ ; _ }) = Location.unwrap x in - if Var.equal binder (Var.of_name name) - then Some expr - else None + let aux x = + match Location.unwrap x with + | Declaration_constant { binder ; expr ; inline=_ } -> ( + if Var.equal binder (Var.of_name name) + then Some expr + else None + ) + | Declaration_type _ -> None in List.find_map aux lst -let program_environment (program : program) : environment = - let last_declaration = Location.unwrap List.(hd @@ rev program) in - match last_declaration with - | Declaration_constant { binder=_ ; expr=_ ; inline=_ ; post_env } -> post_env - let equal_variables a b : bool = match a.expression_content, b.expression_content with | E_variable a, E_variable b -> Var.equal a b | _, _ -> false -let p_constant (p_ctor_tag : constant_tag) (p_ctor_args : p_ctor_args) = - P_constant { +let p_constant (p_ctor_tag : constant_tag) (p_ctor_args : p_ctor_args) = { + tsrc = "misc.ml/p_constant" ; + t = P_constant { p_ctor_tag : constant_tag ; p_ctor_args : p_ctor_args ; } +} let c_equation aval bval reason = { c = C_equation { aval ; bval }; reason } + +let reason_simpl : type_constraint_simpl -> string = function + | SC_Constructor { reason_constr_simpl=reason; _ } + | SC_Alias { reason_alias_simpl=reason; _ } + | SC_Poly { reason_poly_simpl=reason; _ } + | SC_Typeclass { reason_typeclass_simpl=reason; _ } + -> reason diff --git a/src/stages/4-ast_typed/misc.mli b/src/stages/4-ast_typed/misc.mli index ae0bb692f..71bb8a291 100644 --- a/src/stages/4-ast_typed/misc.mli +++ b/src/stages/4-ast_typed/misc.mli @@ -70,7 +70,8 @@ val assert_literal_eq : ( literal * literal ) -> unit result *) val get_entry : program -> string -> expression result -val program_environment : program -> environment val p_constant : constant_tag -> p_ctor_args -> type_value val c_equation : type_value -> type_value -> string -> type_constraint + +val reason_simpl : type_constraint_simpl -> string diff --git a/src/stages/4-ast_typed/misc_smart.ml b/src/stages/4-ast_typed/misc_smart.ml index a09ed2acc..d62665149 100644 --- a/src/stages/4-ast_typed/misc_smart.ml +++ b/src/stages/4-ast_typed/misc_smart.ml @@ -8,8 +8,9 @@ let program_to_main : program -> string -> lambda result = fun p s -> let%bind (main , input_type , _) = let pred = fun d -> match d with - | Declaration_constant { binder; expr; inline=_ ; post_env=_ } when binder = Var.of_name s -> Some expr + | Declaration_constant { binder; expr; inline=_ } when binder = Var.of_name s -> Some expr | Declaration_constant _ -> None + | Declaration_type _ -> None in let%bind main = trace_option (simple_error "no main with given name") @@ @@ -20,16 +21,11 @@ let program_to_main : program -> string -> lambda result = fun p s -> | _ -> simple_fail "program main isn't a function" in ok (main , input_ty , output_ty) in - let env = - let aux = fun _ d -> - match d with - | Declaration_constant {binder=_ ; expr= _ ; inline=_ ; post_env } -> post_env in - List.fold_left aux Environment.empty (List.map Location.unwrap p) in let binder = Var.of_name "@contract_input" in let result = - let input_expr = e_a_variable binder input_type env in - let main_expr = e_a_variable (Var.of_name s) (get_type_expression main) env in - e_a_application main_expr input_expr env in + let input_expr = e_a_variable binder input_type in + let main_expr = e_a_variable (Var.of_name s) (get_type_expression main) in + e_a_application main_expr input_expr in ok { binder ; result ; @@ -46,8 +42,8 @@ module Captured_variables = struct let of_list : expression_variable list -> bindings = fun x -> x let rec expression : bindings -> expression -> bindings result = fun b e -> - expression_content b e.environment e.expression_content - and expression_content : bindings -> environment -> expression_content -> bindings result = fun b env ec -> + expression_content b e.expression_content + and expression_content : bindings -> expression_content -> bindings result = fun b ec -> let self = expression b in match ec with | E_lambda l -> ok @@ Free_variables.lambda empty l @@ -56,12 +52,7 @@ module Captured_variables = struct let%bind lst' = bind_map_list self arguments in ok @@ unions lst' | E_variable name -> ( - let%bind env_element = - trace_option (simple_error "missing var in env") @@ - Environment.get_opt name env in - match env_element.definition with - | ED_binder -> ok empty - | ED_declaration {expr=_ ; free_variables=_} -> simple_fail "todo" + if mem name b then ok empty else ok (singleton name) ) | E_application {lamb;args} -> let%bind lst' = bind_map_list self [ lamb ; args ] in @@ -84,7 +75,7 @@ module Captured_variables = struct expression b' li.let_result | E_recursive r -> let b' = union (singleton r.fun_name) b in - expression_content b' env @@ E_lambda r.lambda + expression_content b' @@ E_lambda r.lambda and matching_variant_case : (bindings -> expression -> bindings result) -> bindings -> matching_content_case -> bindings result = fun f b { constructor=_ ; pattern ; body } -> f (union (singleton pattern) b) body diff --git a/src/stages/4-ast_typed/types.ml b/src/stages/4-ast_typed/types.ml index be7a7a287..6f4ee13b2 100644 --- a/src/stages/4-ast_typed/types.ml +++ b/src/stages/4-ast_typed/types.ml @@ -1,615 +1,5 @@ -[@@@warning "-30"] - +(* The content of types.ml has been split into Ast which contains only + type declarations, and Types_utils which contains some alias + declarations and other definitions used by the fold generator. *) include Types_utils - -type type_constant = - | TC_unit - | TC_string - | TC_bytes - | TC_nat - | TC_int - | TC_mutez - | TC_operation - | TC_address - | TC_key - | TC_key_hash - | TC_chain_id - | TC_signature - | TC_timestamp - | TC_void - -type te_cmap = ctor_content constructor_map -and te_lmap = field_content label_map -and type_meta = ast_core_type_expression option - -and type_content = - | T_sum of te_cmap - | T_record of te_lmap - | T_arrow of arrow - | T_variable of type_variable - | T_constant of type_constant - | T_operator of type_operator - -and arrow = { - type1: type_expression; - type2: type_expression; - } - -and annot_option = string option - -and ctor_content = { - ctor_type : type_expression; - michelson_annotation : annot_option; - ctor_decl_pos : int; -} - -and field_content = { - field_type : type_expression; - michelson_annotation : annot_option; - field_decl_pos : int; -} - -and type_map_args = { - k : type_expression; - v : type_expression; - } - -and michelson_or_args = { - l : type_expression; - r : type_expression; - } - -and type_operator = - | TC_contract of type_expression - | TC_option of type_expression - | TC_list of type_expression - | TC_set of type_expression - | TC_map of type_map_args - | TC_big_map of type_map_args - | TC_map_or_big_map of type_map_args - -and type_expression = { - type_content: type_content; - type_meta: type_meta; - location: location; - } - -type literal = - | Literal_unit - | Literal_int of z - | Literal_nat of z - | Literal_timestamp of z - | Literal_mutez of z - | Literal_string of ligo_string - | Literal_bytes of bytes - | Literal_address of string - | Literal_signature of string - | Literal_key of string - | Literal_key_hash of string - | Literal_chain_id of string - | Literal_void - | Literal_operation of packed_internal_operation - - -and matching_content_cons = { - hd : expression_variable; - tl : expression_variable; - body : expression; - tv : type_expression; - } - -and matching_content_list = { - match_nil : expression ; - match_cons : matching_content_cons; - } - -and matching_content_some = { - opt : expression_variable ; - body : expression ; - tv : type_expression ; - } - -and matching_content_option = { - match_none : expression ; - match_some : matching_content_some ; - } - -and expression_variable_list = expression_variable list -and type_expression_list = type_expression list - -and matching_content_tuple = { - vars : expression_variable_list ; - body : expression ; - tvs : type_expression_list ; - } - -and matching_content_case = { - constructor : constructor' ; - pattern : expression_variable ; - body : expression ; - } - -and matching_content_case_list = matching_content_case list - -and matching_content_variant = { - cases: matching_content_case_list; - tv: type_expression; - } - -and matching_expr = - | Match_list of matching_content_list - | Match_option of matching_content_option - | Match_tuple of matching_content_tuple - | Match_variant of matching_content_variant - -and constant' = - | C_INT - | C_UNIT - | C_NIL - | C_NOW - | C_IS_NAT - | C_SOME - | C_NONE - | C_ASSERTION - | C_ASSERT_INFERRED - | C_FAILWITH - | C_UPDATE - (* Loops *) - | C_ITER - | C_FOLD_WHILE - | C_FOLD_CONTINUE - | C_FOLD_STOP - | C_LOOP_LEFT - | C_LOOP_CONTINUE - | C_LOOP_STOP - | C_FOLD - (* MATH *) - | C_NEG - | C_ABS - | C_ADD - | C_SUB - | C_MUL - | C_EDIV - | C_DIV - | C_MOD - (* LOGIC *) - | C_NOT - | C_AND - | C_OR - | C_XOR - | C_LSL - | C_LSR - (* COMPARATOR *) - | C_EQ - | C_NEQ - | C_LT - | C_GT - | C_LE - | C_GE - (* Bytes/ String *) - | C_SIZE - | C_CONCAT - | C_SLICE - | C_BYTES_PACK - | C_BYTES_UNPACK - | C_CONS - (* Pair *) - | C_PAIR - | C_CAR - | C_CDR - | C_LEFT - | C_RIGHT - (* Set *) - | C_SET_EMPTY - | C_SET_LITERAL - | C_SET_ADD - | C_SET_REMOVE - | C_SET_ITER - | C_SET_FOLD - | C_SET_MEM - (* List *) - | C_LIST_EMPTY - | C_LIST_LITERAL - | C_LIST_ITER - | C_LIST_MAP - | C_LIST_FOLD - (* Maps *) - | C_MAP - | C_MAP_EMPTY - | C_MAP_LITERAL - | C_MAP_GET - | C_MAP_GET_FORCE - | C_MAP_ADD - | C_MAP_REMOVE - | C_MAP_UPDATE - | C_MAP_ITER - | C_MAP_MAP - | C_MAP_FOLD - | C_MAP_MEM - | C_MAP_FIND - | C_MAP_FIND_OPT - (* Big Maps *) - | C_BIG_MAP - | C_BIG_MAP_EMPTY - | C_BIG_MAP_LITERAL - (* Crypto *) - | C_SHA256 - | C_SHA512 - | C_BLAKE2b - | C_HASH - | C_HASH_KEY - | C_CHECK_SIGNATURE - | C_CHAIN_ID - (* Blockchain *) - | C_CALL - | C_CONTRACT - | C_CONTRACT_OPT - | C_CONTRACT_ENTRYPOINT - | C_CONTRACT_ENTRYPOINT_OPT - | C_AMOUNT - | C_BALANCE - | C_SOURCE - | C_SENDER - | C_ADDRESS - | C_SELF - | C_SELF_ADDRESS - | C_IMPLICIT_ACCOUNT - | C_SET_DELEGATE - | C_CREATE_CONTRACT - | C_CONVERT_TO_LEFT_COMB - | C_CONVERT_TO_RIGHT_COMB - | C_CONVERT_FROM_LEFT_COMB - | C_CONVERT_FROM_RIGHT_COMB - -and declaration_loc = declaration location_wrap - -and program = declaration_loc list - -and declaration_constant = { - binder : expression_variable ; - expr : expression ; - inline : bool ; - post_env : environment ; - } - -and declaration = - (* A Declaration_constant is described by - * a name + a type-annotated expression - * a boolean indicating whether it should be inlined - * the environment before the declaration (the original environment) - * the environment after the declaration (i.e. with that new declaration added to the original environment). *) - | Declaration_constant of declaration_constant - (* - | Declaration_type of (type_variable * type_expression) - | Declaration_constant of (named_expression * (environment * environment)) - *) -(* | Macro_declaration of macro_declaration *) - -and expression = { - expression_content: expression_content ; - location: location ; - type_expression: type_expression ; - environment: environment ; - } - -and map_kv = { - k : expression ; - v : expression ; - } - -and look_up = { - ds : expression; - ind : expression; - } - -and expression_label_map = expression label_map -and map_kv_list = map_kv list -and expression_list = expression list - -and expression_content = - (* Base *) - | E_literal of literal - | E_constant of constant (* For language constants, like (Cons hd tl) or (plus i j) *) - | E_variable of expression_variable - | E_application of application - | E_lambda of lambda - | E_recursive of recursive - | E_let_in of let_in - (* Variant *) - | E_constructor of constructor (* For user defined constructors *) - | E_matching of matching - (* Record *) - | E_record of expression_label_map - | E_record_accessor of record_accessor - | E_record_update of record_update - -and constant = { - cons_name: constant' ; - arguments: expression_list ; - } - -and application = { - lamb: expression ; - args: expression ; - } - -and lambda = { - binder: expression_variable ; - (* input_type: type_expression option ; *) - (* output_type: type_expression option ; *) - result: expression ; - } - -and let_in = { - let_binder: expression_variable ; - rhs: expression ; - let_result: expression ; - inline : bool ; - } - -and recursive = { - fun_name : expression_variable; - fun_type : type_expression; - lambda : lambda; -} - -and constructor = { - constructor: constructor'; - element: expression ; - } - -and record_accessor = { - record: expression ; - path: label ; - } - -and record_update = { - record: expression ; - path: label ; - update: expression ; - } - -and matching = { - matchee: expression ; - cases: matching_expr ; - } - -and ascription = { - anno_expr: expression ; - type_annotation: type_expression ; - } - -and environment_element_definition = - | ED_binder - | ED_declaration of environment_element_definition_declaration - -and environment_element_definition_declaration = { - expr: expression ; - free_variables: free_variables ; - } - -and free_variables = expression_variable list - -and environment_element = { - type_value: type_expression ; - source_environment: environment ; - definition: environment_element_definition ; - } - -and expression_environment = environment_binding list - -and environment_binding = { - expr_var: expression_variable ; - env_elt: environment_element ; - } - -and type_environment = type_environment_binding list - -and type_environment_binding = { - type_variable: type_variable ; - type_: type_expression ; -} - -and environment = { - expression_environment: expression_environment ; - type_environment: type_environment ; -} - -and named_type_content = { - type_name : type_variable; - type_value : type_expression; - } - - - - - -(* Solver types *) - -(* typevariable: to_string = (fun s -> Format.asprintf "%a" Var.pp s) *) -type unionfind = type_variable poly_unionfind - -(* core *) - -(* add information on the type or the kind for operator *) -type constant_tag = - | C_arrow (* * -> * -> * isn't this wrong? *) - | C_option (* * -> * *) - | C_record (* ( label , * ) … -> * *) - | C_variant (* ( label , * ) … -> * *) - | C_map (* * -> * -> * *) - | C_big_map (* * -> * -> * *) - | C_list (* * -> * *) - | C_set (* * -> * *) - | C_unit (* * *) - | C_string (* * *) - | C_nat (* * *) - | C_mutez (* * *) - | C_timestamp (* * *) - | C_int (* * *) - | C_address (* * *) - | C_bytes (* * *) - | C_key_hash (* * *) - | C_key (* * *) - | C_signature (* * *) - | C_operation (* * *) - | C_contract (* * -> * *) - | C_chain_id (* * *) - -(* TODO: rename to type_expression or something similar (it includes variables, and unevaluated functions + applications *) -type type_value = - | P_forall of p_forall - | P_variable of type_variable - | P_constant of p_constant - | P_apply of p_apply - -and p_apply = { - tf : type_value ; - targ : type_value ; -} -and p_ctor_args = type_value list -and p_constant = { - p_ctor_tag : constant_tag ; - p_ctor_args : p_ctor_args ; - } -and p_constraints = type_constraint list -and p_forall = { - binder : type_variable ; - constraints : p_constraints ; - body : type_value ; -} - -(* Different type of constraint *) -and ctor_args = type_variable list (* non-empty list *) -and simple_c_constructor = { - ctor_tag : constant_tag ; - ctor_args : ctor_args ; - } -and simple_c_constant = { - constant_tag: constant_tag ; (* for type constructors that do not take arguments *) - } -and c_const = { - c_const_tvar : type_variable ; - c_const_tval : type_value ; - } -and c_equation = { - aval : type_value ; - bval : type_value ; -} -and tc_args = type_value list -and c_typeclass = { - tc_args : tc_args ; - typeclass : typeclass ; -} -and c_access_label = { - c_access_label_tval : type_value ; - accessor : label ; - c_access_label_tvar : type_variable ; - } - -and type_constraint = { - reason : string ; - c : type_constraint_ ; -} -and type_constraint_ = - (* | C_assignment of (type_variable * type_pattern) *) - | C_equation of c_equation (* TVA = TVB *) - | C_typeclass of c_typeclass (* TVL ∈ TVLs, for now in extension, later add intensional (rule-based system for inclusion in the typeclass) *) - | C_access_label of c_access_label (* poor man's type-level computation to ensure that TV.label is type_variable *) -(* | … *) - -(* is the first list in case on of the type of the type class as a kind *->*->* ? *) -and tc_allowed = type_value list -and typeclass = tc_allowed list - -(* end core *) - -type c_constructor_simpl_typeVariableMap = c_constructor_simpl typeVariableMap -and constraints_typeVariableMap = constraints typeVariableMap -and type_constraint_simpl_list = type_constraint_simpl list -and structured_dbs = { - all_constraints : type_constraint_simpl_list ; - aliases : unionfind ; - (* assignments (passive data structure). *) - (* Now : just a map from unification vars to types (pb: what about partial types?) *) - (* maybe just local assignments (allow only vars as children of pair(α,β)) *) - (* TODO : the rhs of the map should not repeat the variable name. *) - assignments : c_constructor_simpl_typeVariableMap ; - grouped_by_variable : constraints_typeVariableMap ; (* map from (unionfind) variables to constraints containing them *) - cycle_detection_toposort : unit ; (* example of structured db that we'll add later *) -} - -and c_constructor_simpl_list = c_constructor_simpl list -and c_poly_simpl_list = c_poly_simpl list -and c_typeclass_simpl_list = c_typeclass_simpl list -and constraints = { - (* If implemented in a language with decent sets, these should be sets not lists. *) - constructor : c_constructor_simpl_list ; (* List of ('a = constructor(args…)) constraints *) - poly : c_poly_simpl_list ; (* List of ('a = forall 'b, some_type) constraints *) - tc : c_typeclass_simpl_list ; (* List of (typeclass(args…)) constraints *) -} -and type_variable_list = type_variable list -and c_constructor_simpl = { - tv : type_variable; - c_tag : constant_tag; - tv_list : type_variable_list; -} -and c_const_e = { - c_const_e_tv : type_variable ; - c_const_e_te : type_expression ; - } -and c_equation_e = { - aex : type_expression ; - bex : type_expression ; - } -and c_typeclass_simpl = { - tc : typeclass ; - args : type_variable_list ; -} -and c_poly_simpl = { - tv : type_variable ; - forall : p_forall ; -} -and type_constraint_simpl = { - reason_simpl : string ; - c_simpl : type_constraint_simpl_ ; - } -and type_constraint_simpl_ = - | SC_Constructor of c_constructor_simpl (* α = ctor(β, …) *) - | SC_Alias of c_alias (* α = β *) - | SC_Poly of c_poly_simpl (* α = forall β, δ where δ can be a more complex type *) - | SC_Typeclass of c_typeclass_simpl (* TC(α, …) *) - -and c_alias = { - a : type_variable ; - b : type_variable ; - } - - -(* sub-sub component: lazy selector (don't re-try all selectors every time) *) -(* For now: just re-try everytime *) - -(* selector / propagation rule for breaking down composite types *) -(* For now: break pair(a, b) = pair(c, d) into a = c, b = d *) -type output_break_ctor = { - a_k_var : c_constructor_simpl ; - a_k'_var' : c_constructor_simpl ; - } - -type output_specialize1 = { - poly : c_poly_simpl ; - a_k_var : c_constructor_simpl ; - } - -type m_break_ctor__already_selected = output_break_ctor poly_set -type m_specialize1__already_selected = output_specialize1 poly_set - -type already_selected = { - break_ctor : m_break_ctor__already_selected ; - specialize1 : m_specialize1__already_selected ; -} - -type typer_state = { - structured_dbs : structured_dbs ; - already_selected : already_selected ; -} +include Ast diff --git a/src/stages/4-ast_typed/types_utils.ml b/src/stages/4-ast_typed/types_utils.ml index 2c77f5c7d..8b6138f56 100644 --- a/src/stages/4-ast_typed/types_utils.ml +++ b/src/stages/4-ast_typed/types_utils.ml @@ -32,6 +32,10 @@ type packed_internal_operation = Memory_proto_alpha.Protocol.Alpha_context.packe type location = Location.t type inline = bool +type 'a extra_info__comparable = { + compare : 'a -> 'a -> int ; +} + let fold_map__constructor_map : type a new_a state . (state -> a -> (state * new_a) result) -> state -> a constructor_map -> (state * new_a constructor_map) result = fun f state m -> let aux k v acc = @@ -93,9 +97,9 @@ type 'v typeVariableMap = (type_variable, 'v) RedBlackTrees.PolyMap.t type 'a poly_set = 'a RedBlackTrees.PolySet.t -let fold_map__poly_unionfind : type a state new_a . (state -> a -> (state * new_a) result) -> state -> a poly_unionfind -> (state * new_a poly_unionfind) Simple_utils.Trace.result = - fun f state l -> - ignore (f, state, l) ; failwith "TODO +let fold_map__poly_unionfind : type a state new_a . new_a extra_info__comparable -> (state -> a -> (state * new_a) result) -> state -> a poly_unionfind -> (state * new_a poly_unionfind) Simple_utils.Trace.result = + fun extra_info f state l -> + ignore (extra_info, f, state, l) ; failwith "TODO let aux acc element = let%bind state , l = acc in let%bind (state , new_element) = f state element in ok (state , new_element :: l) in @@ -114,9 +118,9 @@ let fold_map__PolyMap : type k v state new_v . (state -> v -> (state * new_v) re let fold_map__typeVariableMap : type a state new_a . (state -> a -> (state * new_a) result) -> state -> a typeVariableMap -> (state * new_a typeVariableMap) result = fold_map__PolyMap -let fold_map__poly_set : type a state new_a . (state -> a -> (state * new_a) result) -> state -> a poly_set -> (state * new_a poly_set) result = - fun f state s -> - let new_compare : (new_a -> new_a -> int) = failwith "TODO: thread enough information about the target AST so that we may compare things here." in +let fold_map__poly_set : type a state new_a . new_a extra_info__comparable -> (state -> a -> (state * new_a) result) -> state -> a poly_set -> (state * new_a poly_set) result = + fun extra_info f state s -> + let new_compare : (new_a -> new_a -> int) = extra_info.compare in let aux elt ~acc = let%bind (state , s) = acc in let%bind (state , new_elt) = f state elt in diff --git a/src/stages/5-mini_c/combinators.ml b/src/stages/5-mini_c/combinators.ml index ff421421c..f01eda745 100644 --- a/src/stages/5-mini_c/combinators.ml +++ b/src/stages/5-mini_c/combinators.ml @@ -183,6 +183,15 @@ let e_let_in ?loc v tv inline expr body : expression = Expression.(make_tpl ?loc E_let_in ((v , tv) , inline, expr , body) , get_type body )) +let e_application ?loc f t arg: expression = Expression.(make_tpl ?loc( + E_application (f,arg) , + t + )) +let e_var ?loc vname t: expression = Expression.(make_tpl ?loc( + E_variable vname , + t + )) + let ez_e_sequence ?loc a b : expression = Expression.(make_tpl (E_sequence (make_tpl ?loc (a , t_unit ()) , b) , get_type b)) diff --git a/src/stages/5-mini_c/combinators.mli b/src/stages/5-mini_c/combinators.mli index f198e8b8e..3a9aab3ed 100644 --- a/src/stages/5-mini_c/combinators.mli +++ b/src/stages/5-mini_c/combinators.mli @@ -78,3 +78,5 @@ val d_unit : value val environment_wrap : environment -> environment -> environment_wrap val id_environment_wrap : environment -> environment_wrap +val e_var : ?loc:Location.t -> var_name -> type_expression -> expression +val e_application : ?loc:Location.t -> expression -> type_expression -> expression -> expression diff --git a/src/stages/adt_generator/generator.raku b/src/stages/adt_generator/generator.raku index 8b323c157..aa5de686b 100644 --- a/src/stages/adt_generator/generator.raku +++ b/src/stages/adt_generator/generator.raku @@ -8,17 +8,27 @@ use worries; # TODO: shorthand for `foo list` etc. in field and constructor types # TODO: error when reserved names are used ("state", … please list them here) -my $moduleName = @*ARGS[0].subst(/\.ml$/, '').samecase("A_"); +my $inputADTfile = @*ARGS[0]; +my $oModuleName = @*ARGS[1]; +my $combinators_filename = @*ARGS[2]; +my $folder_filename = @*ARGS[3]; +my $mapper_filename = @*ARGS[4]; + +my $moduleName = $inputADTfile.subst(/\.ml$/, '').samecase("A_"); my $variant = "_ _variant"; my $record = "_ _ record"; sub poly { $^type_name } -my $l = @*ARGS[0].IO.lines; +my $l = $inputADTfile.IO.lines; $l = $l.map(*.subst: /(^\s+|\s+$)/, ""); $l = $l.list.cache; my $statement_re = /^((\(\*\s+)?(open|include)\s|\[\@\@\@warning\s)/; my $statements = $l.grep($statement_re); $l = $l.grep(none $statement_re); +$l = $l.list.cache; +my $typeclass_re = /^\(\*\@ \s* typeclass \s+ (\w+) \s+ (\w+) \s* \*\)/; +my $typeclasses = %($l.grep($typeclass_re).map({ do given $_ { when $typeclass_re { %{ "$/[0]" => "$/[1]" } } } }).flat); +$l = $l.grep(none $typeclass_re); $statements = $statements.map(*.subst(/^\(\*\s+/, '').subst(/\s+\*\)$/, '')); $l = $l.cache.map(*.subst: /^type\s+/, "\nand "); # TODO: find a better way to write [\*] (anything but a star), the Raku form I found <-[\*]> is very verbose. @@ -50,424 +60,452 @@ $l = $l.map: { "kind" => $kind , "ctorsOrFields" => $ctorsOrFields } - # $_[0].subst: , '' } }; -# $l.perl.say; -# exit; - -# ($cf, $isBuiltin, $type) - # { - # name => $cf , - # newName => "$cf'" , - # isBuiltin => $isBuiltin , - # type => $type , - # newType => $isBuiltin ?? $type !! "$type'" - # } - - - -# my @adts_raw = [ -# # typename, kind, fields_or_ctors -# ["root", $variant, [ -# # ctor, builtin?, type -# ["A", False, "rootA"], -# ["B", False, "rootB"], -# ["C", True, "string"], -# ]], -# ["a", $record, [ -# # field, builtin?, type -# ["a1", False, "ta1"], -# ["a2", False, "ta2"], -# ]], -# ["ta1", $variant, [ -# ["X", False, "root"], -# ["Y", False, "ta2"], -# ]], -# ["ta2", $variant, [ -# ["Z", False, "ta2"], -# ["W", True, "unit"], -# ]], -# # polymorphic type -# ["rootA", poly("list"), -# [ -# # Position (0..n-1), builtin?, type argument -# [0, False, "a"], -# ], -# ], -# ["rootB", poly("list"), -# [ -# # Position (0..n-1), builtin?, type argument -# [0, True, "int"], -# ], -# ], -# ]; - -# # say $adts_raw.perl; -# my $adts = (map -> ($name , $kind, @ctorsOrFields) { -# { -# "name" => $name , -# "newName" => "$name'" , -# "kind" => $kind , -# "ctorsOrFields" => @(map -> ($cf, $isBuiltin, $type) { -# { -# name => $cf , -# newName => "$cf'" , -# isBuiltin => $isBuiltin , -# type => $type , -# newType => $isBuiltin ?? $type !! "$type'" -# } -# }, @ctorsOrFields), -# } -# }, @adts_raw).list; my $adts = (map -> (:$name , :$kind, :@ctorsOrFields) { { "name" => $name , - "newName" => "{$name}__'" , + "oNewName" => "O.{$name}", # ($kind ne $record && $kind ne $variant) ?? "$name" !! "O.{$name}", + "newName" => $name , "kind" => $kind , "ctorsOrFields" => @(map -> ($cf, $type) { - my $isBuiltin = (! $type) || (! $l.cache.first({ $_ eq $type })); + my $resolvedType = $type && $l.cache.first({ $_ eq $type }); + my $isBuiltin = (! $type) || (! $resolvedType); + # my $isPoly = $resolvedType && $resolvedType ne $record && $resolvedType ne $variant; { name => $cf , - newName => "{$cf}__'" , + oNewName => "O.{$cf}" , + newName => $cf , isBuiltin => $isBuiltin , type => $type , - newType => $isBuiltin ?? "$type" !! "{$type}__'" + oNewType => $isBuiltin ?? "$type" !! "O.{$type}" , + newType => $type , } }, @ctorsOrFields), } }, @$l.cache).list; -# say $adts.perl; -# say $adts.perl ; - -say "(* This is an auto-generated file. Do not edit. *)"; - -say ""; -for $statements -> $statement { - say "$statement" -} -say "open Adt_generator.Common;;"; -say "open $moduleName;;"; - -say ""; -say "(* must be provided by one of the open or include statements: *)"; -for $adts.grep({$_ ne $record && $_ ne $variant}).map({$_}).unique -> $poly -{ say "let fold_map__$poly : type a new_a state . (state -> a -> (state * new_a, _) monad) -> state -> a $poly -> (state * new_a $poly , _) monad = fold_map__$poly;;"; } - -say ""; -for $adts.kv -> $index, $t { - my $typeOrAnd = $index == 0 ?? "type" !! "and"; - say "$typeOrAnd $t ="; - if ($t eq $variant) { - for $t.list -> $c { - given $c { - when '' { say " | $c" } - default { say " | $c of $c" } - } - } - say ""; - } elsif ($t eq $record) { - say ' {'; - for $t.list -> $f - { say " $f : $f ;"; } - say ' }'; - } else { - print " "; - for $t.list -> $a - { print "$a "; } - print "$t"; - say ""; - } -} -say ";;"; - -say ""; -for $adts.list -> $t { - say "type ('state, 'err) _continue_fold_map__$t = \{"; - say " node__$t : 'state -> $t -> ('state * $t , 'err) monad ;"; - for $t.list -> $c - { say " $t__$c : 'state -> {$c || 'unit'} -> ('state * {$c || 'unit'} , 'err) monad ;" } - say ' };;'; -} - -say "type ('state , 'err) _continue_fold_map__$moduleName = \{"; -for $adts.list -> $t { - say " $t : ('state , 'err) _continue_fold_map__$t ;"; -} -say ' };;'; - -say ""; -for $adts.list -> $t -{ say "type ('state, 'err) fold_map_config__$t = \{"; - say " node__$t : 'state -> $t -> ('state, 'err) _continue_fold_map__$moduleName -> ('state * $t , 'err) monad ;"; # (*Adt_info.node_instance_info ->*) - say " node__$t__pre_state : 'state -> $t -> ('state, 'err) monad ;"; # (*Adt_info.node_instance_info ->*) - say " node__$t__post_state : 'state -> $t -> $t -> ('state, 'err) monad ;"; # (*Adt_info.node_instance_info ->*) - for $t.list -> $c - { say " $t__$c : 'state -> {$c || 'unit'} -> ('state, 'err) _continue_fold_map__$moduleName -> ('state * {$c || 'unit'} , 'err) monad ;"; # (*Adt_info.ctor_or_field_instance_info ->*) - } - say '};;' } - -say "type ('state, 'err) fold_map_config__$moduleName ="; -say ' {'; -for $adts.list -> $t -{ say " $t : ('state, 'err) fold_map_config__$t;" } -say ' };;'; - -say "include Adt_generator.Generic.BlahBluh"; -say "type ('state , 'adt_info_node_instance_info) _fold_config ="; -say ' {'; -say " generic : 'state -> 'adt_info_node_instance_info -> 'state;"; -# look for builtins, filtering out the "implicit unit-like fake argument of emtpy constructors" (represented by '') -for $adts.map({ $_ })[*;*].grep({$_ && $_ ne ''}).map({$_}).unique -> $builtin -{ say " $builtin : ('state , 'adt_info_node_instance_info) _fold_config -> 'state -> $builtin -> 'state;"; } -# look for built-in polymorphic types -for $adts.grep({$_ ne $record && $_ ne $variant}).map({$_}).unique -> $poly -{ say " $poly : 'a . ('state , 'adt_info_node_instance_info) _fold_config -> ('state -> 'a -> 'state) -> 'state -> 'a $poly -> 'state;"; } -say ' };;'; -say "module Arg = struct"; -say " type nonrec ('state , 'adt_info_node_instance_info) fold_config = ('state , 'adt_info_node_instance_info) _fold_config;;"; -say "end;;"; -say "module Adt_info = Adt_generator.Generic.Adt_info (Arg);;"; -say "include Adt_info;;"; -say "type 'state fold_config = ('state , 'state Adt_info.node_instance_info) _fold_config;;"; - -say ""; -say 'type blahblah = {'; -for $adts.list -> $t -{ say " fold__$t : 'state . blahblah -> 'state fold_config -> 'state -> $t -> 'state;"; - for $t.list -> $c - { say " fold__$t__$c : 'state . blahblah -> 'state fold_config -> 'state -> { $c || 'unit' } -> 'state;"; } } -say '};;'; - -# generic programming info about the nodes and fields -say ""; -for $adts.list -> $t -{ for $t.list -> $c - { say "(* info for field or ctor $t.$c *)"; - say "let info__$t__$c : Adt_info.ctor_or_field = \{"; - say " name = \"$c\";"; - say " is_builtin = {$c ?? 'true' !! 'false'};"; - say " type_ = \"$c\";"; - say '}'; - say ""; - say "let continue_info__$t__$c : type qstate . blahblah -> qstate fold_config -> {$c || 'unit'} -> qstate Adt_info.ctor_or_field_instance = fun blahblah visitor x -> \{"; - say " cf = info__$t__$c;"; - say " cf_continue = (fun state -> blahblah.fold__$t__$c blahblah visitor state x);"; - say " cf_new_fold = (fun visitor state -> blahblah.fold__$t__$c blahblah visitor state x);"; - say '};;'; - say ""; } - say "(* info for node $t *)"; - say "let info__$t : Adt_info.node = \{"; - my $kind = do given $t { - when $record { "Record" } - when $variant { "Variant" } - default { "Poly \"$_\"" } - }; - say " kind = $kind;"; - say " declaration_name = \"$t\";"; - print " ctors_or_fields = [ "; - for $t.list -> $c { print "info__$t__$c ; "; } - say "];"; - say '};;'; - say ""; - # TODO: factor out some of the common bits here. - say "let continue_info__$t : type qstate . blahblah -> qstate fold_config -> $t -> qstate Adt_info.instance = fun blahblah visitor x ->"; - say '{'; - say " instance_declaration_name = \"$t\";"; - do given $t { - when $record { - say ' instance_kind = RecordInstance {'; - print " fields = [ "; - for $t.list -> $c { print "continue_info__$t__$c blahblah visitor x.$c ; "; } - say " ];"; - say '};'; - } - when $variant { - say ' instance_kind = VariantInstance {'; - say " constructor = (match x with"; - for $t.list -> $c { say " | $c { $c ?? 'v ' !! '' }-> continue_info__$t__$c blahblah visitor { $c ?? 'v' !! '()' }"; } - say " );"; - print " variant = [ "; - for $t.list -> $c { print "info__$t__$c ; "; } - say "];"; - say '};'; - } - default { - say ' instance_kind = PolyInstance {'; - say " poly = \"$_\";"; - print " arguments = ["; - # TODO: sort by c (currently we only have one-argument - # polymorphic types so it happens to work but should be fixed. - for $t.list -> $c { print "\"$c\""; } - say "];"; - print " poly_continue = (fun state -> visitor.$_ visitor ("; - print $t - .map(-> $c { "(fun state x -> (continue_info__$t__$c blahblah visitor x).cf_continue state)" }) - .join(", "); - say ") state x);"; - say '};'; - } - }; - say '};;'; - say ""; } - -say ""; -say "(* info for adt $moduleName *)"; -print "let whole_adt_info : unit -> Adt_info.adt = fun () -> [ "; -for $adts.list -> $t -{ print "info__$t ; "; } -say "];;"; - -# fold functions -say ""; -for $adts.list -> $t -{ say "let fold__$t : type qstate . blahblah -> qstate fold_config -> qstate -> $t -> qstate = fun blahblah visitor state x ->"; - # TODO: add a non-generic continue_fold. - say ' let node_instance_info : qstate Adt_info.node_instance_info = {'; - say " adt = whole_adt_info () ;"; - say " node_instance = continue_info__$t blahblah visitor x"; - say ' } in'; - # say " let (state, new_x) = visitor.$t.node__$t x (fun () -> whole_adt_info, info__$t) state continue_fold in"; - say " visitor.generic state node_instance_info;;"; - say ""; - for $t.list -> $c - { say "let fold__$t__$c : type qstate . blahblah -> qstate fold_config -> qstate -> { $c || 'unit' } -> qstate = fun blahblah { $c ?? 'visitor' !! '_visitor' } state { $c ?? 'x' !! '()' } ->"; - # say " let ctor_or_field_instance_info : qstate Adt_info.ctor_or_field_instance_info = whole_adt_info (), info__$t, continue_info__$t__$c visitor x in"; - if ($c eq '') { - # nothing to do, this constructor has no arguments. - say " ignore blahblah; state;;"; - } elsif ($c) { - say " ignore blahblah; visitor.$c visitor state x;;"; # (*visitor.generic_ctor_or_field ctor_or_field_instance_info*) - } else { - say " blahblah.fold__$c blahblah visitor state x;;"; # (*visitor.generic_ctor_or_field ctor_or_field_instance_info*) - } - # say " visitor.$t.$t__$c x (fun () -> whole_adt_info, info__$t, info__$t__$c) state continue_fold"; - say ""; } -} - -say ""; -say 'let blahblah : blahblah = {'; -for $adts.list -> $t -{ say " fold__$t;"; - for $t.list -> $c - { say " fold__$t__$c;" } } -say '};;'; - -# Tying the knot -say ""; -for $adts.list -> $t -{ say "let fold__$t : type qstate . qstate fold_config -> qstate -> $t -> qstate = fun visitor state x -> fold__$t blahblah visitor state x;;"; - for $t.list -> $c - { say "let fold__$t__$c : type qstate . qstate fold_config -> qstate -> { $c || 'unit' } -> qstate = fun visitor state x -> fold__$t__$c blahblah visitor state x;;" } } - - -say ""; -say "type ('state, 'err) mk_continue_fold_map = \{"; -say " fn : ('state, 'err) mk_continue_fold_map -> ('state, 'err) fold_map_config__$moduleName -> ('state, 'err) _continue_fold_map__$moduleName"; -say '};;'; - - -# fold_map functions -say ""; -for $adts.list -> $t -{ say "let _fold_map__$t : type qstate err . (qstate,err) mk_continue_fold_map -> (qstate,err) fold_map_config__$moduleName -> qstate -> $t -> (qstate * $t, err) monad = fun mk_continue_fold_map visitor state x ->"; - say " let continue_fold_map : (qstate,err) _continue_fold_map__$moduleName = mk_continue_fold_map.fn mk_continue_fold_map visitor in"; - say " visitor.$t.node__$t__pre_state state x >>? fun state ->"; # (*(fun () -> whole_adt_info, info__$t)*) - say " visitor.$t.node__$t state x continue_fold_map >>? fun (state, new_x) ->"; # (*(fun () -> whole_adt_info, info__$t)*) - say " visitor.$t.node__$t__post_state state x new_x >>? fun state ->"; # (*(fun () -> whole_adt_info, info__$t)*) - say " return (state, new_x);;"; - say ""; - for $t.list -> $c - { say "let _fold_map__$t__$c : type qstate err . (qstate,err) mk_continue_fold_map -> (qstate,err) fold_map_config__$moduleName -> qstate -> { $c || 'unit' } -> (qstate * { $c || 'unit' }, err) monad = fun mk_continue_fold_map visitor state x ->"; - say " let continue_fold_map : (qstate,err) _continue_fold_map__$moduleName = mk_continue_fold_map.fn mk_continue_fold_map visitor in"; - say " visitor.$t.$t__$c state x continue_fold_map;;"; # (*(fun () -> whole_adt_info, info__$t, info__$t__$c)*) - say ""; } } - -# make the "continue" object -say ""; -say '(* Curries the "visitor" argument to the folds (non-customizable traversal functions). *)'; -say "let mk_continue_fold_map : 'state 'err . ('state,'err) mk_continue_fold_map = \{ fn = fun self visitor ->"; -say ' {'; -for $adts.list -> $t -{ say " $t = \{"; - say " node__$t = (fun state x -> _fold_map__$t self visitor state x) ;"; - for $t.list -> $c - { say " $t__$c = (fun state x -> _fold_map__$t__$c self visitor state x) ;"; } - say ' };' } -say ' }'; -say '};;'; -say ""; - -# fold_map functions : tying the knot -say ""; -for $adts.list -> $t -{ say "let fold_map__$t : type qstate err . (qstate,err) fold_map_config__$moduleName -> qstate -> $t -> (qstate * $t,err) monad ="; - say " fun visitor state x -> _fold_map__$t mk_continue_fold_map visitor state x;;"; - for $t.list -> $c - { say "let fold_map__$t__$c : type qstate err . (qstate,err) fold_map_config__$moduleName -> qstate -> { $c || 'unit' } -> (qstate * { $c || 'unit' },err) monad ="; - say " fun visitor state x -> _fold_map__$t__$c mk_continue_fold_map visitor state x;;"; } } - - -for $adts.list -> $t +# Auto-generated fold functions +$*OUT = open $folder_filename, :w; { - say "let no_op_node__$t : type state . state -> $t -> (state,_) _continue_fold_map__$moduleName -> (state * $t,_) monad ="; - say " fun state v continue ->"; # (*_info*) - say " match v with"; - if ($t eq $variant) { - for $t.list -> $c - { given $c { - when '' { say " | $c -> continue.$t.$t__$c state () >>? fun (state , ()) -> return (state , $c)"; } - default { say " | $c v -> continue.$t.$t__$c state v >>? fun (state , v) -> return (state , $c v)"; } } } - } elsif ($t eq $record) { - print ' { '; - for $t.list -> $f - { print "$f; "; } - say "} ->"; - for $t.list -> $f - { say " continue.$t.$t__$f state $f >>? fun (state , $f) ->"; } - print ' return (state , ({ '; - for $t.list -> $f - { print "$f; "; } - say "\} : $t))"; - } else { - print " v -> fold_map__$t ( "; - print ( "continue.$t.$t__$_" for $t.list ).join(", "); - say " ) state v;;"; - } + say "(* This is an auto-generated file. Do not edit. *)"; + say ""; + for $statements -> $statement { say "$statement" } + say "open $moduleName;;"; + + say ""; + say " include Adt_generator.Generic.BlahBluh"; + say " type ('in_state, 'out_state , 'adt_info_node_instance_info) _fold_config = \{"; + say " generic : 'in_state -> 'adt_info_node_instance_info -> 'out_state;"; + say " generic_empty_ctor : 'in_state -> 'out_state;"; + # look for builtins, filtering out the "implicit unit-like fake argument of emtpy constructors" (represented by '') + for $adts.map({ $_ })[*;*].grep({$_ && $_ ne ''}).map({$_}).unique -> $builtin + { say " $builtin : ('in_state , 'out_state , 'adt_info_node_instance_info) _fold_config -> 'in_state -> $builtin -> 'out_state;"; } + # look for built-in polymorphic types + for $adts.grep({$_ ne $record && $_ ne $variant}).map({$_}).unique -> $poly + { say " $poly : 'a . ('in_state , 'out_state , 'adt_info_node_instance_info) _fold_config -> ('in_state -> 'a -> 'out_state) -> 'in_state -> 'a $poly -> 'out_state;"; } + say ' };;'; + + say ""; + say " module Adt_info = Adt_generator.Generic.Adt_info (struct"; + say " type nonrec ('in_state , 'out_state , 'adt_info_node_instance_info) fold_config = ('in_state , 'out_state , 'adt_info_node_instance_info) _fold_config;;"; + say " end);;"; + say " include Adt_info;;"; + say " type ('in_state, 'out_state) fold_config = ('in_state , 'out_state , ('in_state , 'out_state) Adt_info.node_instance_info) _fold_config;;"; + + say ""; + say ' type the_folds = {'; + for $adts.list -> $t + { say " fold__$t : 'in_state 'out_state . the_folds -> ('in_state , 'out_state) fold_config -> 'in_state -> $t -> 'out_state;"; + for $t.list -> $c + { say " fold__$t__$c : 'in_state 'out_state . the_folds -> ('in_state , 'out_state) fold_config -> 'in_state -> { $c || 'unit' } -> 'out_state;"; } } + say ' };;'; + + # generic programming info about the nodes and fields + say ""; + for $adts.list -> $t + { for $t.list -> $c + { say " (* info for field or ctor $t.$c *)"; + say " let info__$t__$c : Adt_info.ctor_or_field = \{"; + say " name = \"$c\";"; + say " is_builtin = {$c ?? 'true' !! 'false'};"; + say " type_ = \"$c\";"; + say ' };;'; + # say ""; + say " let continue_info__$t__$c : type in_qstate out_qstate . the_folds -> (in_qstate , out_qstate) fold_config -> {$c || 'unit'} -> (in_qstate, out_qstate) Adt_info.ctor_or_field_instance = fun the_folds visitor x -> \{"; + say " cf = info__$t__$c;"; + say " cf_continue = (fun state -> the_folds.fold__$t__$c the_folds visitor state x);"; + say " cf_new_fold = (fun visitor state -> the_folds.fold__$t__$c the_folds visitor state x);"; + say ' };;'; + # say ""; + } + say " (* info for node $t *)"; + say " let info__$t : Adt_info.node = \{"; + my $kind = do given $t { + when $record { "Record" } + when $variant { "Variant" } + default { "Poly \"$_\"" } + }; + say " kind = $kind;"; + say " declaration_name = \"$t\";"; + print " ctors_or_fields = [ "; + for $t.list -> $c { print "info__$t__$c ; "; } + say "];"; + say ' };;'; + # say ""; + # TODO: factor out some of the common bits here. + say " let continue_info__$t : type in_qstate out_qstate . the_folds -> (in_qstate , out_qstate) fold_config -> $t -> (in_qstate , out_qstate) Adt_info.instance = fun the_folds visitor x ->"; + say ' {'; + say " instance_declaration_name = \"$t\";"; + do given $t { + when $record { + say ' instance_kind = RecordInstance {'; + print " fields = [ "; + for $t.list -> $c { print "continue_info__$t__$c the_folds visitor x.$c ; "; } + say " ];"; + say ' };'; + } + when $variant { + say " instance_kind ="; + say ' VariantInstance {'; + say " constructor ="; + say " (match x with"; + for $t.list -> $c { say " | $c { $c ?? 'v ' !! '' }-> continue_info__$t__$c the_folds visitor { $c ?? 'v' !! '()' }"; } + say " );"; + print " variant = [ "; + for $t.list -> $c { print "info__$t__$c ; "; } + say "];"; + say ' };'; + } + default { + say " instance_kind ="; + say ' PolyInstance {'; + say " poly = \"$_\";"; + print " arguments = ["; + # TODO: sort by c (currently we only have one-argument + # polymorphic types so it happens to work but should be fixed. + for $t.list -> $c { print "\"$c\""; } + say "];"; + print " poly_continue = (fun state -> visitor.$_ visitor ("; + print $t + .map(-> $c { "(fun state x -> (continue_info__$t__$c the_folds visitor x).cf_continue state)" }) + .join(", "); + say ") state x);"; + say ' };'; + } + }; + say ' };;'; + # say ""; + } + + say ""; + say " (* info for adt $moduleName *)"; + print " let whole_adt_info : unit -> Adt_info.adt = fun () -> [ "; + for $adts.list -> $t + { print "info__$t ; "; } + say "];;"; + + # fold functions + say ""; + for $adts.list -> $t + { say " let fold__$t : type in_qstate out_qstate . the_folds -> (in_qstate , out_qstate) fold_config -> in_qstate -> $t -> out_qstate = fun the_folds visitor state x ->"; + # TODO: add a non-generic continue_fold. + say ' let node_instance_info : (in_qstate , out_qstate) Adt_info.node_instance_info = {'; + say " adt = whole_adt_info () ;"; + say " node_instance = continue_info__$t the_folds visitor x"; + say ' } in'; + # say " let (state, new_x) = visitor.$t.node__$t x (fun () -> whole_adt_info, info__$t) state continue_fold in"; + say " visitor.generic state node_instance_info;;"; + # say ""; + for $t.list -> $c + { say " let fold__$t__$c : type in_qstate out_qstate . the_folds -> (in_qstate , out_qstate) fold_config -> in_qstate -> { $c || 'unit' } -> out_qstate = fun the_folds visitor state { $c ?? 'x' !! '()' } ->"; + # say " let ctor_or_field_instance_info : (in_qstate , out_qstate) Adt_info.ctor_or_field_instance_info = whole_adt_info (), info__$t, continue_info__$t__$c visitor x in"; + if ($c eq '') { + # nothing to do, this constructor has no arguments. + say " ignore the_folds; visitor.generic_empty_ctor state;;"; + } elsif ($c) { + say " ignore the_folds; visitor.$c visitor state x;;"; # (*visitor.generic_ctor_or_field ctor_or_field_instance_info*) + } else { + say " the_folds.fold__$c the_folds visitor state x;;"; # (*visitor.generic_ctor_or_field ctor_or_field_instance_info*) + } + # say " visitor.$t.$t__$c x (fun () -> whole_adt_info, info__$t, info__$t__$c) state continue_fold"; + # say ""; + } + } + # look for builtins, filtering out the "implicit unit-like fake argument of emtpy constructors" (represented by '') + for $adts.map({ $_ })[*;*].grep({$_ && $_ ne ''}).map({$_}).unique -> $builtin + { say " let fold__$builtin : type in_qstate out_qstate . the_folds -> (in_qstate , out_qstate) fold_config -> in_qstate -> $builtin -> out_qstate = fun the_folds visitor state x ->"; + say " ignore the_folds; visitor.$builtin visitor state x;;"; } # (*visitor.generic_ctor_or_field ctor_or_field_instance_info*) + + say ""; + say ' let the_folds : the_folds = {'; + for $adts.list -> $t + { say " fold__$t;"; + for $t.list -> $c + { say " fold__$t__$c;" } } + say ' };;'; + + # Tying the knot + say ""; + for $adts.list -> $t + { say " let fold__$t : type in_qstate out_qstate . (in_qstate , out_qstate) fold_config -> in_qstate -> $t -> out_qstate = fun visitor state x -> fold__$t the_folds visitor state x;;"; + for $t.list -> $c + { say " let fold__$t__$c : type in_qstate out_qstate . (in_qstate , out_qstate) fold_config -> in_qstate -> { $c || 'unit' } -> out_qstate = fun visitor state x -> fold__$t__$c the_folds visitor state x;;" } } + # look for builtins, filtering out the "implicit unit-like fake argument of emtpy constructors" (represented by '') + for $adts.map({ $_ })[*;*].grep({$_ && $_ ne ''}).map({$_}).unique -> $builtin + { say " let fold__$builtin : type in_qstate out_qstate . (in_qstate , out_qstate) fold_config -> in_qstate -> $builtin -> out_qstate = fun visitor state x -> fold__$builtin the_folds visitor state x;;"; } + + say ""; + say " module Folds (M : sig type in_state type out_state type 'a t val f : ((in_state , out_state) fold_config -> in_state -> 'a -> out_state) -> 'a t end) = struct"; + for $adts.list -> $t + { say " let $t = M.f fold__$t;;"; } + # look for builtins, filtering out the "implicit unit-like fake argument of emtpy constructors" (represented by '') + for $adts.map({ $_ })[*;*].grep({$_ && $_ ne ''}).map({$_}).unique -> $builtin + { say " let $builtin = M.f fold__$builtin"; } + say " end"; } -for $adts.list -> $t -{ say "let no_op__$t : type state . (state,_) fold_map_config__$t = \{"; - say " node__$t = no_op_node__$t;"; - say " node__$t__pre_state = (fun state v -> ignore v; return state) ;"; # (*_info*) - say " node__$t__post_state = (fun state v new_v -> ignore (v, new_v); return state) ;"; # (*_info*) - for $t.list -> $c - { print " $t__$c = (fun state v continue -> "; # (*_info*) - if ($c) { - print "ignore continue; return (state , v)"; - } else { - print "continue.$c.node__$c state v"; +# auto-generated fold_map functions +$*OUT = open $mapper_filename, :w; +{ + say "(* This is an auto-generated file. Do not edit. *)"; + say ""; + for $statements -> $statement { say "$statement" } + say "open Adt_generator.Common;;"; + say "open $moduleName;;"; + + say ""; + say "module type OSig = sig"; + for $adts.list -> $t { + say " type $t;;"; } - say ") ;"; } - say ' }' } -say "let no_op : type state . (state,_) fold_map_config__$moduleName = \{"; -for $adts.list -> $t -{ say " $t = no_op__$t;" } -say '};;'; + for $adts.list -> $t { + if ($t eq $variant) { + for $t.list -> $c { + say " val make__$t__$c : {$c ne '' ?? "$c " !! 'unit'} -> $t;;"; + } + } elsif ($t eq $record) { + print " val make__$t"; + say ' :'; + for $t.list -> $f + { say " {$f}:{$f} ->"; } + say " $t;;"; + } else { + print " val make__$t : ("; + print $t.map({$_}).join(" , "); + say ") $t -> $t;;"; + } + } -say ""; -for $adts.list -> $t -{ say "let with__$t : _ -> _ fold_map_config__$moduleName -> _ fold_map_config__$moduleName = (fun node__$t op -> \{ op with $t = \{ op.$t with node__$t \} \});;"; - say "let with__$t__pre_state : _ -> _ fold_map_config__$moduleName -> _ fold_map_config__$moduleName = (fun node__$t__pre_state op -> \{ op with $t = \{ op.$t with node__$t__pre_state \} \});;"; - say "let with__$t__post_state : _ -> _ fold_map_config__$moduleName -> _ fold_map_config__$moduleName = (fun node__$t__post_state op -> \{ op with $t = \{ op.$t with node__$t__post_state \} \});;"; - for $t.list -> $c - { say "let with__$t__$c : _ -> _ fold_map_config__$moduleName -> _ fold_map_config__$moduleName = (fun $t__$c op -> \{ op with $t = \{ op.$t with $t__$c \} \});;"; } } + say ""; + for $adts.grep({$_ ne $record && $_ ne $variant && $typeclasses{$_}}).unique(:as({$_, $_})) -> $t + { my $ty = $t[0]; + my $typeclass = $typeclasses{$t}; + say " val extra_info__{$ty}__$typeclass : $ty extra_info__$typeclass;;"; } + say "end"; -say ""; -say "module Folds (M : sig type state type 'a t val f : (state fold_config -> state -> 'a -> state) -> 'a t end) = struct"; -for $adts.list -> $t -{ say "let $t = M.f fold__$t;;"; } -say "end"; + say ""; + say "module Mapper (* O : OSig Functors are too slow and consume a lot of memory when compiling large files with OCaml. We're hardcoding the O module below for now. *) = struct"; + say " module O : OSig = $oModuleName"; + say ""; + say " (* must be provided by one of the open or include statements: *)"; + say " module CheckInputSignature = struct"; + for $adts.grep({$_ ne $record && $_ ne $variant}).map({$_}).unique -> $poly + { say " let fold_map__$poly : type a new_a state err .{ $typeclasses{$poly} ?? " new_a extra_info__{$typeclasses{$poly}} ->" !! "" } (state -> a -> (state * new_a, err) monad) -> state -> a $poly -> (state * new_a $poly , err) monad = fold_map__$poly;;"; } + say " end"; + + say ""; + for $adts.list -> $t { + say " type ('state, 'err) _continue_fold_map__$t = \{"; + say " node__$t : 'state -> $t -> ('state * $t , 'err) monad ;"; + for $t.list -> $c + { say " $t__$c : 'state -> {$c || 'unit'} -> ('state * {$c || 'unit'} , 'err) monad ;" } + say ' };;'; + } + + say " type ('state , 'err) _continue_fold_map__$moduleName = \{"; + for $adts.list -> $t { + say " $t : ('state , 'err) _continue_fold_map__$t ;"; + } + say ' };;'; + + say ""; + for $adts.list -> $t + { say " type ('state, 'err) fold_map_config__$t = \{"; + say " node__$t : 'state -> $t -> ('state, 'err) _continue_fold_map__$moduleName -> ('state * $t , 'err) monad ;"; # (*Adt_info.node_instance_info ->*) + say " node__$t__pre_state : 'state -> $t -> ('state, 'err) monad ;"; # (*Adt_info.node_instance_info ->*) + say " node__$t__post_state : 'state -> $t -> $t -> ('state, 'err) monad ;"; # (*Adt_info.node_instance_info ->*) + for $t.list -> $c + { say " $t__$c : 'state -> {$c || 'unit'} -> ('state, 'err) _continue_fold_map__$moduleName -> ('state * {$c || 'unit'} , 'err) monad ;"; # (*Adt_info.ctor_or_field_instance_info ->*) + } + say ' };;' } + + say " type ('state, 'err) fold_map_config__$moduleName = \{"; + for $adts.list -> $t + { say " $t : ('state, 'err) fold_map_config__$t;" } + say ' };;'; + + say ""; + say " type ('state, 'err) mk_continue_fold_map = \{"; + say " fn : ('state, 'err) mk_continue_fold_map -> ('state, 'err) fold_map_config__$moduleName -> ('state, 'err) _continue_fold_map__$moduleName"; + say ' };;'; + + + # fold_map functions + say ""; + for $adts.list -> $t + { say " let _fold_map__$t : type qstate err . (qstate,err) mk_continue_fold_map -> (qstate,err) fold_map_config__$moduleName -> qstate -> $t -> (qstate * $t, err) monad = fun mk_continue_fold_map visitor state x ->"; + say " let continue_fold_map : (qstate,err) _continue_fold_map__$moduleName = mk_continue_fold_map.fn mk_continue_fold_map visitor in"; + say " visitor.$t.node__$t__pre_state state x >>? fun state ->"; # (*(fun () -> whole_adt_info, info__$t)*) + say " visitor.$t.node__$t state x continue_fold_map >>? fun (state, new_x) ->"; # (*(fun () -> whole_adt_info, info__$t)*) + say " visitor.$t.node__$t__post_state state x new_x >>? fun state ->"; # (*(fun () -> whole_adt_info, info__$t)*) + say " return (state, new_x);;"; + # say ""; + for $t.list -> $c + { say " let _fold_map__$t__$c : type qstate err . (qstate,err) mk_continue_fold_map -> (qstate,err) fold_map_config__$moduleName -> qstate -> { $c || 'unit' } -> (qstate * { $c || 'unit' }, err) monad = fun mk_continue_fold_map visitor state x ->"; + say " let continue_fold_map : (qstate,err) _continue_fold_map__$moduleName = mk_continue_fold_map.fn mk_continue_fold_map visitor in"; + say " visitor.$t.$t__$c state x continue_fold_map;;"; # (*(fun () -> whole_adt_info, info__$t, info__$t__$c)*) + # say ""; + } + } + + # make the "continue" object + say ""; + say ' (* Curries the "visitor" argument to the folds (non-customizable traversal functions). *)'; + say " let mk_continue_fold_map : 'state 'err . ('state,'err) mk_continue_fold_map = \{"; + say " fn ="; + say " fun self visitor ->"; + say ' {'; + for $adts.list -> $t + { say " $t = \{"; + say " node__$t = (fun state x -> _fold_map__$t self visitor state x) ;"; + for $t.list -> $c + { say " $t__$c = (fun state x -> _fold_map__$t__$c self visitor state x) ;"; } + say ' };' } + say ' }'; + say ' };;'; + say ""; + + # fold_map functions : tying the knot + say ""; + for $adts.list -> $t + { say " let fold_map__$t : type qstate err . (qstate,err) fold_map_config__$moduleName -> qstate -> $t -> (qstate * $t,err) monad ="; + say " fun visitor state x -> _fold_map__$t mk_continue_fold_map visitor state x;;"; + for $t.list -> $c + { say " let fold_map__$t__$c : type qstate err . (qstate,err) fold_map_config__$moduleName -> qstate -> { $c || 'unit' } -> (qstate * { $c || 'unit' },err) monad ="; + say " fun visitor state x -> _fold_map__$t__$c mk_continue_fold_map visitor state x;;"; } } + + say ""; + for $adts.list -> $t + { + say " let no_op_node__$t : type state . state -> $t -> (state,_) _continue_fold_map__$moduleName -> (state * $t,_) monad ="; + say " fun state v continue ->"; # (*_info*) + say " match v with"; + if ($t eq $variant) { + for $t.list -> $c + { given $c { + when '' { say " | $c -> continue.$t.$t__$c state () >>? fun (state , ()) -> return (state , O.make__$t__$c ())"; } + default { say " | $c v -> continue.$t.$t__$c state v >>? fun (state , v) -> return (state , O.make__$t__$c v)"; } } } + } elsif ($t eq $record) { + print ' { '; + for $t.list -> $f + { print "$f; "; } + say "} ->"; + for $t.list -> $f + { say " continue.$t.$t__$f state $f >>? fun (state , $f) ->"; } + print " return (state , (O.make__$t"; + for $t.list -> $f + { print " ~$f"; } + say " : $t))"; + } else { + print " v -> (fold_map__$t"; + if ($t ne $record && $t ne $variant && $typeclasses{$t}) { + for $t.list -> $a + { print " O.extra_info__$a__{$typeclasses{$t}}"; } + } + print " ( "; + print ( "continue.$t.$t__$_" for $t.list ).join(", "); + say " ) state v)"; + say " >>? fun (state, x) -> return (state, O.make__$t x);;"; + } + } + + for $adts.list -> $t + { say " let no_op__$t : type state . (state,_) fold_map_config__$t = \{"; + say " node__$t = no_op_node__$t;"; + say " node__$t__pre_state = (fun state v -> ignore v; return state) ;"; # (*_info*) + say " node__$t__post_state = (fun state v new_v -> ignore (v, new_v); return state) ;"; # (*_info*) + for $t.list -> $c + { print " $t__$c = (fun state v continue -> "; # (*_info*) + if ($c) { + print "ignore continue; return (state , v)"; + } else { + print "continue.$c.node__$c state v"; + } + say ") ;"; } + say ' }' } + + say " let no_op : type state . (state,_) fold_map_config__$moduleName = \{"; + for $adts.list -> $t + { say " $t = no_op__$t;" } + say ' };;'; + + say ""; + for $adts.list -> $t + { say " let with__$t : _ -> _ fold_map_config__$moduleName -> _ fold_map_config__$moduleName = (fun node__$t op -> \{ op with $t = \{ op.$t with node__$t \} \});;"; + say " let with__$t__pre_state : _ -> _ fold_map_config__$moduleName -> _ fold_map_config__$moduleName = (fun node__$t__pre_state op -> \{ op with $t = \{ op.$t with node__$t__pre_state \} \});;"; + say " let with__$t__post_state : _ -> _ fold_map_config__$moduleName -> _ fold_map_config__$moduleName = (fun node__$t__post_state op -> \{ op with $t = \{ op.$t with node__$t__post_state \} \});;"; + for $t.list -> $c + { say " let with__$t__$c : _ -> _ fold_map_config__$moduleName -> _ fold_map_config__$moduleName = (fun $t__$c op -> \{ op with $t = \{ op.$t with $t__$c \} \});;"; } } + say "end"; +} + +$*OUT = open $combinators_filename, :w; +{ + say "(* This is an auto-generated file. Do not edit. *)"; + say ""; + for $statements -> $statement { say "$statement" } + say "open $moduleName;;"; + say ""; + for $adts.list -> $t { + say "type nonrec $t = $t;;"; + } + + for $adts.list -> $t { + if ($t eq $variant) { + for $t.list -> $c { + say "let make__$t__$c : {$c ne '' ?? "$c " !! 'unit'} -> $t = fun {$c ne '' ?? 'v' !! '()'} -> $c {$c ne '' ?? 'v ' !! ''};;"; + } + } elsif ($t eq $record) { + print "let make__$t"; + print ' :'; + for $t.list -> $f + { print " {$f}:{$f} ->"; } + print " $t = fun"; + for $t.list -> $f + { print " ~{$f}"; } + print " -> \{"; + for $t.list -> $f + { print " {$f} ;"; } + say " \};;"; + } else { + print "let make__$t : ("; + print $t.map({$_}).join(" , "); + print ") $t -> $t = "; + print "fun x -> x"; + say ";;"; + } + } + + say ""; + for $adts.grep({$_ ne $record && $_ ne $variant && $typeclasses{$_}}).unique(:as({$_, $_})) -> $t + { my $ty = $t[0]; + my $typeclass = $typeclasses{$t}; + say "let extra_info__{$ty}__$typeclass : $ty extra_info__$typeclass = {tc $typeclass}.$ty;;"; + } + # Check that we won't have a cyclic module dependency when using the Folder to auto-generate the compare: + say "(* Check that we won't have a cyclic module dependency when using the Folder to auto-generate the compare: *)"; + say "module DummyTest_ = Generated_fold;;"; +} diff --git a/src/stages/adt_generator/generic.ml b/src/stages/adt_generator/generic.ml index c48ca1ac1..f1ad0fcb8 100644 --- a/src/stages/adt_generator/generic.ml +++ b/src/stages/adt_generator/generic.ml @@ -1,44 +1,44 @@ module BlahBluh = struct -module StringMap = Map.Make(String);; -(* generic folds for nodes *) -type 'state generic_continue_fold_node = { - continue : 'state -> 'state ; - (* generic folds for each field *) - continue_ctors_or_fields : ('state -> 'state) StringMap.t ; -};; -(* map from node names to their generic folds *) -type 'state generic_continue_fold = ('state generic_continue_fold_node) StringMap.t;; + module StringMap = Map.Make(String);; + (* generic folds for nodes *) + type 'state generic_continue_fold_node = { + continue : 'state -> 'state ; + (* generic folds for each field *) + continue_ctors_or_fields : ('state -> 'state) StringMap.t ; + };; + (* map from node names to their generic folds *) + type 'state generic_continue_fold = ('state generic_continue_fold_node) StringMap.t;; end -module Adt_info (M : sig type ('state , 'adt_info_node_instance_info) fold_config end) = struct +module Adt_info (M : sig type ('in_state , 'out_state , 'adt_info_node_instance_info) fold_config end) = struct type kind = | Record | Variant | Poly of string - type 'state record_instance = { - fields : 'state ctor_or_field_instance list; + type ('in_state , 'out_state) record_instance = { + fields : ('in_state , 'out_state) ctor_or_field_instance list; } - and 'state constructor_instance = { - constructor : 'state ctor_or_field_instance ; + and ('in_state , 'out_state) constructor_instance = { + constructor : ('in_state , 'out_state) ctor_or_field_instance ; variant : ctor_or_field list } - and 'state poly_instance = { + and ('in_state , 'out_state) poly_instance = { poly : string; arguments : string list; - poly_continue : 'state -> 'state + poly_continue : 'in_state -> 'out_state } - and 'state kind_instance = - | RecordInstance of 'state record_instance - | VariantInstance of 'state constructor_instance - | PolyInstance of 'state poly_instance + and ('in_state , 'out_state) kind_instance = + | RecordInstance of ('in_state , 'out_state) record_instance + | VariantInstance of ('in_state , 'out_state) constructor_instance + | PolyInstance of ('in_state , 'out_state) poly_instance - and 'state instance = { + and ('in_state , 'out_state) instance = { instance_declaration_name : string; - instance_kind : 'state kind_instance; + instance_kind : ('in_state , 'out_state) kind_instance; } and ctor_or_field = @@ -48,11 +48,11 @@ module Adt_info (M : sig type ('state , 'adt_info_node_instance_info) fold_confi type_ : string; } - and 'state ctor_or_field_instance = + and ('in_state , 'out_state) ctor_or_field_instance = { cf : ctor_or_field; - cf_continue : 'state -> 'state; - cf_new_fold : 'state . ('state, ('state node_instance_info)) M.fold_config -> 'state -> 'state; + cf_continue : 'in_state -> 'out_state; + cf_new_fold : 'in_state 'out_state . ('in_state , 'out_state , (('in_state , 'out_state) node_instance_info)) M.fold_config -> 'in_state -> 'out_state; } and node = @@ -64,9 +64,9 @@ module Adt_info (M : sig type ('state , 'adt_info_node_instance_info) fold_confi (* TODO: rename things a bit in this file. *) and adt = node list - and 'state node_instance_info = { + and ('in_state , 'out_state) node_instance_info = { adt : adt ; - node_instance : 'state instance ; + node_instance : ('in_state , 'out_state) instance ; } - and 'state ctor_or_field_instance_info = adt * node * 'state ctor_or_field_instance + and ('in_state , 'out_state) ctor_or_field_instance_info = adt * node * ('in_state , 'out_state) ctor_or_field_instance end diff --git a/src/stages/typesystem/misc.ml b/src/stages/typesystem/misc.ml index d7662698a..c42040854 100644 --- a/src/stages/typesystem/misc.ml +++ b/src/stages/typesystem/misc.ml @@ -29,7 +29,6 @@ module Substitution = struct ok @@ T.{expr_var=variable ; env_elt={ type_value; source_environment; definition }}) env and s_type_environment : T.type_environment w = fun ~substs tenv -> bind_map_list (fun T.{type_variable ; type_} -> - let%bind type_variable = s_type_variable ~substs type_variable in let%bind type_ = s_type_expression ~substs type_ in ok @@ T.{type_variable ; type_}) tenv and s_environment : T.environment w = fun ~substs T.{expression_environment ; type_environment} -> @@ -45,14 +44,6 @@ module Substitution = struct let () = ignore @@ substs in ok var - and s_type_variable : T.type_variable w = fun ~substs tvar -> - let _TODO = ignore @@ substs in - Printf.printf "TODO: subst: unimplemented case s_type_variable"; - ok @@ tvar - (* if String.equal tvar v then - * expr - * else - * ok tvar *) and s_label : T.label w = fun ~substs l -> let () = ignore @@ substs in ok l @@ -71,7 +62,12 @@ module Substitution = struct ok @@ type_name and s_type_content : T.type_content w = fun ~substs -> function - | T.T_sum _ -> failwith "TODO: T_sum" + | T.T_sum s -> + let aux T.{ ctor_type; michelson_annotation ; ctor_decl_pos } = + let%bind ctor_type = s_type_expression ~substs ctor_type in + ok @@ T.{ ctor_type; michelson_annotation; ctor_decl_pos } in + let%bind s = Ast_typed.Helpers.bind_map_cmap aux s in + ok @@ T.T_sum s | T.T_record _ -> failwith "TODO: T_record" | T.T_constant type_name -> let%bind type_name = s_type_name_constant ~substs type_name in @@ -195,20 +191,19 @@ module Substitution = struct let%bind cases = s_matching_expr ~substs cases in ok @@ T.E_matching {matchee;cases} - and s_expression : T.expression w = fun ~(substs:substs) { expression_content; type_expression; environment; location } -> + and s_expression : T.expression w = fun ~(substs:substs) { expression_content; type_expression; location } -> let%bind expression_content = s_expression_content ~substs expression_content in let%bind type_expr = s_type_expression ~substs type_expression in - let%bind environment = s_environment ~substs environment in let location = location in - ok T.{ expression_content;type_expression=type_expr; environment; location } + ok T.{ expression_content;type_expression=type_expr; location } and s_declaration : T.declaration w = fun ~substs -> function - Ast_typed.Declaration_constant {binder ; expr ; inline ; post_env} -> - let%bind binder = s_variable ~substs binder in - let%bind expr = s_expression ~substs expr in - let%bind post_env = s_environment ~substs post_env in - ok @@ Ast_typed.Declaration_constant {binder; expr; inline; post_env} + | Ast_typed.Declaration_constant {binder ; expr ; inline} -> + let%bind binder = s_variable ~substs binder in + let%bind expr = s_expression ~substs expr in + ok @@ Ast_typed.Declaration_constant {binder; expr; inline} + | Declaration_type t -> ok (Ast_typed.Declaration_type t) and s_declaration_wrap :T.declaration Location.wrap w = fun ~substs d -> Trace.bind_map_location (s_declaration ~substs) d @@ -224,24 +219,24 @@ module Substitution = struct and type_value ~tv ~substs = let self tv = type_value ~tv ~substs in let (v, expr) = substs in - match (tv : type_value) with + match (tv : type_value).t with | P_variable v' when Var.equal v' v -> expr | P_variable _ -> tv | P_constant {p_ctor_tag=x ; p_ctor_args=lst} -> ( let lst' = List.map self lst in - P_constant {p_ctor_tag=x ; p_ctor_args=lst'} + { tsrc = "?TODO1?" ; t = P_constant {p_ctor_tag=x ; p_ctor_args=lst'} } ) | P_apply { tf; targ } -> ( - P_apply { tf = self tf ; targ = self targ } + { tsrc = "?TODO2?" ; t = P_apply { tf = self tf ; targ = self targ } } ) | P_forall p -> ( let aux c = constraint_ ~c ~substs in let constraints = List.map aux p.constraints in if (p.binder = v) then ( - P_forall { p with constraints } + { tsrc = "?TODO3?" ; t = P_forall { p with constraints } } ) else ( let body = self p.body in - P_forall { p with constraints ; body } + { tsrc = "?TODO4?" ; t = P_forall { p with constraints ; body } } ) ) @@ -271,9 +266,10 @@ module Substitution = struct (* Performs beta-reduction at the root of the type *) let eval_beta_root ~(tv : type_value) = - match tv with - P_apply {tf = P_forall { binder; constraints; body }; targ} -> + match tv.t with + P_apply {tf = { tsrc = _ ; t = P_forall { binder; constraints; body } }; targ} -> let constraints = List.map (fun c -> constraint_ ~c ~substs:(mk_substs ~v:binder ~expr:targ)) constraints in + (* TODO: indicate in the result's tsrc that it was obtained via beta-reduction of the original type *) (type_value ~tv:body ~substs:(mk_substs ~v:binder ~expr:targ) , constraints) | _ -> (tv , []) end diff --git a/src/stages/typesystem/shorthands.ml b/src/stages/typesystem/shorthands.ml index 2e431b93c..dc82b2d09 100644 --- a/src/stages/typesystem/shorthands.ml +++ b/src/stages/typesystem/shorthands.ml @@ -2,19 +2,24 @@ open Ast_typed.Types open Core open Ast_typed.Misc -let tc type_vars allowed_list : type_constraint = - { c = C_typeclass {tc_args = type_vars ; typeclass = allowed_list} ; reason = "shorthands: typeclass" } +let tc description type_vars allowed_list : type_constraint = { + c = C_typeclass {tc_args = type_vars ;typeclass = allowed_list} ; + reason = "typeclass for operator: " ^ description + } let forall binder f = let () = ignore binder in let freshvar = fresh_type_variable () in - P_forall { binder = freshvar ; constraints = [] ; body = f (P_variable freshvar) } + let body = f { tsrc = "shorthands.ml/forall" ; t = P_variable freshvar } in + { tsrc = "shorthands.ml/forall" ; + t = P_forall { binder = freshvar ; constraints = [] ; body } } let forall_tc binder f = let () = ignore binder in let freshvar = fresh_type_variable () in - let (tc, ty) = f (P_variable freshvar) in - P_forall { binder = freshvar ; constraints = tc ; body = ty } + let (tc, ty) = f { tsrc = "shorthands.ml/forall_tc" ; t = P_variable freshvar } in + { tsrc = "shorthands.ml/forall_tc" ; + t = P_forall { binder = freshvar ; constraints = tc ; body = ty } } (* chained forall *) let forall2 a b f = @@ -55,7 +60,7 @@ let map k v = p_constant C_map [k; v] let unit = p_constant C_unit [] let list t = p_constant C_list [t] let set t = p_constant C_set [t] -let bool = P_variable Stage_common.Constant.t_bool +let bool = { tsrc = "built-in type" ; t = P_variable Stage_common.Constant.t_bool } let string = p_constant C_string [] let nat = p_constant C_nat [] let mutez = p_constant C_mutez [] diff --git a/src/test/adt_generator/.gitignore b/src/test/adt_generator/.gitignore index c1c657206..189a4ee60 100644 --- a/src/test/adt_generator/.gitignore +++ b/src/test/adt_generator/.gitignore @@ -1 +1,3 @@ /generated_fold.ml +/generated_map.ml +/generated_o.ml diff --git a/src/test/adt_generator/amodule.ml b/src/test/adt_generator/amodule.ml index ad8035380..abd5490ae 100644 --- a/src/test/adt_generator/amodule.ml +++ b/src/test/adt_generator/amodule.ml @@ -1,3 +1,4 @@ +[@@@warning "-33"] (* open Amodule_utils *) type root = diff --git a/src/test/adt_generator/dune b/src/test/adt_generator/dune index 1f82e7ad0..16af71a00 100644 --- a/src/test/adt_generator/dune +++ b/src/test/adt_generator/dune @@ -1,7 +1,7 @@ (rule - (target generated_fold.ml) + (targets generated_fold.ml generated_map.ml generated_o.ml) (deps ../../../src/stages/adt_generator/generator.raku amodule.ml) - (action (with-stdout-to generated_fold.ml (run perl6 ../../../src/stages/adt_generator/generator.raku amodule.ml))) + (action (run perl6 ../../../src/stages/adt_generator/generator.raku amodule.ml Generated_o generated_o.ml generated_fold.ml generated_map.ml)) (mode (promote (until-clean) (only *))) ) diff --git a/src/test/adt_generator/fold.ml b/src/test/adt_generator/fold.ml index 271974820..fd817b4a3 100644 --- a/src/test/adt_generator/fold.ml +++ b/src/test/adt_generator/fold.ml @@ -1 +1,2 @@ include Generated_fold +include Generated_map.Mapper diff --git a/src/test/adt_generator/use_a_fold.ml b/src/test/adt_generator/use_a_fold.ml index 484940341..e6277f76e 100644 --- a/src/test/adt_generator/use_a_fold.ml +++ b/src/test/adt_generator/use_a_fold.ml @@ -2,6 +2,8 @@ open Amodule open Fold open Simple_utils.Trace +module O = Fold.O + let (|>) v f = f v module Errors = struct @@ -22,9 +24,9 @@ let () = let op = no_op |> with__a (fun state the_a (*_info*) continue_fold -> - let%bind state, a1__' = continue_fold.ta1.node__ta1 state the_a.a1 in - let%bind state, a2__' = continue_fold.ta2.node__ta2 state the_a.a2 in - ok (state + 1, { a1__' ; a2__' })) + let%bind state, a1 = continue_fold.ta1.node__ta1 state the_a.a1 in + let%bind state, a2 = continue_fold.ta2.node__ta2 state the_a.a2 in + ok (state + 1, (O.make__a ~a1 ~a2 : O.a))) in let state = 0 in let%bind (state , _) = fold_map__root op state some_root in @@ -61,35 +63,33 @@ let () = let _noi : (int, [> error]) fold_map_config__Amodule = no_op (* (fun _ -> ()) *) let _nob : (bool, [> error]) fold_map_config__Amodule = no_op (* (fun _ -> ()) *) +type no_state = NoState let () = let some_root : root = A [ { a1 = X (A [ { a1 = X (B [ 1 ; 2 ; 3 ]) ; a2 = W () } ]) ; a2 = Z (W ()) } ] in - let assert_nostate (needs_parens, state) = assert (not needs_parens && String.equal state "") in - let nostate = false, "" in - let op = { - generic = (fun state info -> - assert_nostate state; + let op : ('i, 'o) Generated_fold.fold_config = { + generic = (fun NoState info -> match info.node_instance.instance_kind with | RecordInstance { fields } -> - false, "{ " ^ String.concat " ; " (List.map (fun (fld : 'x Adt_info.ctor_or_field_instance) -> fld.cf.name ^ " = " ^ snd (fld.cf_continue nostate)) fields) ^ " }" + false, "{ " ^ String.concat " ; " (List.map (fun (fld : ('xi , 'xo) Adt_info.ctor_or_field_instance) -> fld.cf.name ^ " = " ^ snd (fld.cf_continue NoState)) fields) ^ " }" | VariantInstance { constructor={ cf = { name; is_builtin=_; type_=_ }; cf_continue; cf_new_fold=_ }; variant=_ } -> - (match cf_continue nostate with + (match cf_continue NoState with | true, arg -> true, name ^ " (" ^ arg ^ ")" | false, arg -> true, name ^ " " ^ arg) | PolyInstance { poly=_; arguments=_; poly_continue } -> - (poly_continue nostate) + (poly_continue NoState) ) ; - string = (fun _visitor state str -> assert_nostate state; false , "\"" ^ str ^ "\"") ; - unit = (fun _visitor state () -> assert_nostate state; false , "()") ; - int = (fun _visitor state i -> assert_nostate state; false , string_of_int i) ; - list = (fun _visitor continue state lst -> - assert_nostate state; - false , "[ " ^ String.concat " ; " (List.map snd @@ List.map (continue nostate) lst) ^ " ]") ; + generic_empty_ctor = (fun NoState -> false, "") ; + string = (fun _visitor NoState str -> false , "\"" ^ str ^ "\"") ; + unit = (fun _visitor NoState () -> false , "()") ; + int = (fun _visitor NoState i -> false , string_of_int i) ; + list = (fun _visitor continue NoState lst -> + false , "[ " ^ String.concat " ; " (List.map snd @@ List.map (continue NoState) lst) ^ " ]") ; (* generic_ctor_or_field = (fun _info state -> * match _info () with * (_, _, { name=_; isBuiltin=_; type_=_; continue }) -> state ^ "ctor_or_field [" ^ (continue "") ^ "]" * ); *) } in - let (_ , state) = fold__root op nostate some_root in + let (_ , state) = Generated_fold.fold__root op NoState some_root in let expected = "A [ { a1 = X (A [ { a1 = X (B [ 1 ; 2 ; 3 ]) ; a2 = W () } ]) ; a2 = Z (W ()) } ]" in if String.equal state expected; then () diff --git a/src/test/coase_tests.ml b/src/test/coase_tests.ml index f5d7819fd..c1cc1d680 100644 --- a/src/test/coase_tests.ml +++ b/src/test/coase_tests.ml @@ -13,15 +13,15 @@ let get_program = | Some s -> ok s | None -> ( let%bind (program , state) = type_file "./contracts/coase.ligo" in - let () = Typer.Solver.discard_state state in - s := Some program ; - ok program + s := Some (program , state) ; + ok (program , state) ) let compile_main () = - let%bind typed_prg = get_program () in - let%bind mini_c_prg = Ligo.Compile.Of_typed.compile typed_prg in - let%bind michelson_prg = Ligo.Compile.Of_mini_c.aggregate_and_compile_contract mini_c_prg "main" in + let%bind (typed_prg, state) = get_program () in + let () = Typer.Solver.discard_state state in + let%bind mini_c_prg = Ligo.Compile.Of_typed.compile typed_prg in + let%bind michelson_prg = Ligo.Compile.Of_mini_c.aggregate_and_compile_contract mini_c_prg "main" in let%bind (_contract: Tezos_utils.Michelson.michelson) = (* fails if the given entry point is not a valid contract *) Ligo.Compile.Of_michelson.build_contract michelson_prg in diff --git a/src/test/contracts/double_fold_converter.religo b/src/test/contracts/double_fold_converter.religo new file mode 100644 index 000000000..01245222b --- /dev/null +++ b/src/test/contracts/double_fold_converter.religo @@ -0,0 +1,72 @@ +type tokenId = nat; +type tokenOwner = address; +type tokenAmount = nat; +type transferContents = { + to_: tokenOwner, + token_id: tokenId, + amount: tokenAmount +}; +type transfer = { + from_: tokenOwner, + txs: list(transferContents) +}; +type transferContentsMichelson = michelson_pair_right_comb(transferContents); +type transferAuxiliary = { + from_: tokenOwner, + txs: list(transferContentsMichelson) +}; +type transferMichelson = michelson_pair_right_comb(transferAuxiliary); +type transferParameter = list(transferMichelson); +type parameter = +| Transfer(transferParameter) +type storage = big_map(tokenId, tokenOwner); +type entrypointParameter = (parameter, storage); +type entrypointReturn = (list(operation), storage); +let errorTokenUndefined = "TOKEN_UNDEFINED"; +let errorNotOwner = "NOT_OWNER"; +let errorInsufficientBalance = "INSUFFICIENT_BALANCE"; +type transferContentsIteratorAccumulator = (storage, tokenOwner); +let transferContentsIterator = ((accumulator, transferContentsMichelson): (transferContentsIteratorAccumulator, transferContentsMichelson)): transferContentsIteratorAccumulator => { + let (storage, from_) = accumulator; + let transferContents: transferContents = Layout.convert_from_right_comb(transferContentsMichelson); + let tokenOwner: option(tokenOwner) = Map.find_opt(transferContents.token_id, storage); + let tokenOwner = switch (tokenOwner) { + | None => (failwith(errorTokenUndefined): tokenOwner) + | Some(tokenOwner) => if (tokenOwner == from_) { + tokenOwner + } else { + (failwith(errorInsufficientBalance): tokenOwner); + } + }; + let storage = Map.update( + transferContents.token_id, + Some(transferContents.to_), + storage + ); + (storage, from_) +}; +let allowOnlyOwnTransfer = (from: tokenOwner): unit => { + if (from != Tezos.sender) { + failwith(errorNotOwner) + } else { (); } +} +let transferIterator = ((storage, transferMichelson): (storage, transferMichelson)): storage => { + let transferAuxiliary2: transferAuxiliary = Layout.convert_from_right_comb(transferMichelson); + let from_: tokenOwner = transferAuxiliary2.from_; + allowOnlyOwnTransfer(from_); + let (storage, _) = List.fold( + transferContentsIterator, + transferAuxiliary2.txs, + (storage, from_) + ); + storage +}; +let transfer = ((transferParameter, storage): (transferParameter, storage)): entrypointReturn => { + let storage = List.fold(transferIterator, transferParameter, storage); + (([]: list(operation)), storage); +}; +let main = ((parameter, storage): entrypointParameter): entrypointReturn => { + switch (parameter) { + | Transfer(transferParameter) => transfer((transferParameter, storage)) + } +} \ No newline at end of file diff --git a/src/test/contracts/id.ligo b/src/test/contracts/id.ligo new file mode 100644 index 000000000..f4302dbfc --- /dev/null +++ b/src/test/contracts/id.ligo @@ -0,0 +1,159 @@ +type id is int + +type id_details is + record [ + owner: address; + controller: address; + profile: bytes; + ] + +type buy is + record [ + profile: bytes; + initial_controller: option(address); + ] + +type update_owner is + record [ + id: id; + new_owner: address; + ] + +type update_details is + record [ + id: id; + new_profile: option(bytes); + new_controller: option(address); + ] + +type action is + | Buy of buy + | Update_owner of update_owner + | Update_details of update_details + | Skip of unit + +(* The prices kept in storage can be changed by bakers, though they should only be + adjusted down over time, not up. *) +type storage is + record [ + identities: big_map (id, id_details); + next_id: int; + name_price: tez; + skip_price: tez; + ] + +(** Preliminary thoughts on ids: + +I very much like the simplicity of http://gurno.com/adam/mne/. +5 three letter words means you have a 15 character identity, not actually more +annoying than an IP address and a lot more memorable than the raw digits. This +can be stored as a single integer which is then translated into the corresponding +series of 5 words. + +I in general like the idea of having a 'skip' mechanism, but it does need to cost +something so people don't eat up the address space. 256 ^ 5 means you have a lot +of address space, but if people troll by skipping a lot that could be eaten up. +Should probably do some napkin calculations for how expensive skipping needs to +be to deter people from doing it just to chew up address space. +*) + +function buy (const parameter : buy; const storage : storage) : list(operation) * storage is + begin + if amount = storage.name_price + then skip + else failwith("Incorrect amount paid."); + const profile : bytes = parameter.profile; + const initial_controller : option(address) = parameter.initial_controller; + var identities : big_map (id, id_details) := storage.identities; + const new_id : int = storage.next_id; + const controller : address = + case initial_controller of + Some(addr) -> addr + | None -> sender + end; + const new_id_details: id_details = + record [ + owner = sender ; + controller = controller ; + profile = profile ; + ]; + identities[new_id] := new_id_details; + end with ((nil : list(operation)), storage with record [ + identities = identities; + next_id = new_id + 1; + ]) + +function update_owner (const parameter : update_owner; const storage : storage) : + list(operation) * storage is + begin + if (amount =/= 0mutez) + then + begin + failwith("Updating owner doesn't cost anything."); + end + else skip; + const id : int = parameter.id; + const new_owner : address = parameter.new_owner; + var identities : big_map (id, id_details) := storage.identities; + const id_details : id_details = + case identities[id] of + Some(id_details) -> id_details + | None -> (failwith("This ID does not exist."): id_details) + end; + if sender = id_details.owner + then skip; + else failwith("You are not the owner of this ID."); + id_details.owner := new_owner; + identities[id] := id_details; + end with ((nil: list(operation)), storage with record [ identities = identities; ]) + +function update_details (const parameter : update_details; const storage : storage ) : + list(operation) * storage is + begin + if (amount =/= 0mutez) + then failwith("Updating details doesn't cost anything.") + else skip; + const id : int = parameter.id; + const new_profile : option(bytes) = parameter.new_profile; + const new_controller : option(address) = parameter.new_controller; + const identities : big_map (id, id_details) = storage.identities; + const id_details: id_details = + case identities[id] of + Some(id_details) -> id_details + | None -> (failwith("This ID does not exist."): id_details) + end; + if (sender = id_details.controller) or (sender = id_details.owner) + then skip; + else failwith("You are not the owner or controller of this ID."); + const owner: address = id_details.owner; + const profile: bytes = + case new_profile of + None -> (* Default *) id_details.profile + | Some(new_profile) -> new_profile + end; + const controller: address = + case new_controller of + None -> (* Default *) id_details.controller + | Some(new_controller) -> new_controller + end; + id_details.owner := owner; + id_details.controller := controller; + id_details.profile := profile; + identities[id] := id_details; + end with ((nil: list(operation)), storage with record [ identities = identities; ]) + +(* Let someone skip the next identity so nobody has to take one that's undesirable *) +function skip_ (const p: unit; const storage: storage) : list(operation) * storage is + begin + if amount = storage.skip_price + then skip + else failwith("Incorrect amount paid."); + end with ((nil: list(operation)), storage with record [ next_id = storage.next_id + 1; ]) + +function main (const action : action; const storage : storage) : list(operation) * storage is + case action of + | Buy(b) -> buy (b, storage) + | Update_owner(uo) -> update_owner (uo, storage) + | Update_details(ud) -> update_details (ud, storage) + | Skip(s) -> skip_ (unit, storage) + end; diff --git a/src/test/contracts/id.mligo b/src/test/contracts/id.mligo index e23f8d841..88cb8d3dc 100644 --- a/src/test/contracts/id.mligo +++ b/src/test/contracts/id.mligo @@ -6,9 +6,21 @@ type id_details = { profile: bytes } -type buy = bytes * address option -type update_owner = id * address -type update_details = id * bytes option * address option +type buy = { + profile: bytes; + initial_controller: address option; +} + +type update_owner = { + id: id; + new_owner: address; +} + +type update_details = { + id: id; + new_profile: bytes option; + new_controller: address option; +} type action = | Buy of buy @@ -19,7 +31,14 @@ type action = (* The prices kept in storage can be changed by bakers, though they should only be adjusted down over time, not up. *) -type storage = (id, id_details) big_map * int * (tez * tez) +(* The prices kept in storage can be changed by bakers, though they should only be + adjusted down over time, not up. *) +type storage = { + identities: (id, id_details) big_map; + next_id: int; + name_price: tez; + skip_price: tez; +} type return = operation list * storage @@ -38,13 +57,17 @@ a lot that could be eaten up. Should probably do some napkin calculations for how expensive skipping needs to be to deter people from doing it just to chew up address space. *) -let buy (parameter, storage: (bytes * address option) * storage) = - let void : unit = - if Tezos.amount <> storage.2.0 - then (failwith "Incorrect amount paid.": unit) in - let profile, initial_controller = parameter in - let identities, new_id, prices = storage in - let controller : address = +let buy (parameter, storage: buy * storage) = + let void: unit = + if amount = storage.name_price + then () + else (failwith "Incorrect amount paid.": unit) + in + let profile = parameter.profile in + let initial_controller = parameter.initial_controller in + let identities = storage.identities in + let new_id = storage.next_id in + let controller: address = match initial_controller with | Some addr -> addr | None -> sender in @@ -54,74 +77,84 @@ let buy (parameter, storage: (bytes * address option) * storage) = profile = profile} in let updated_identities : (id, id_details) big_map = Big_map.update new_id (Some new_id_details) identities - in ([]: operation list), (updated_identities, new_id + 1, prices) + in + ([]: operation list), {storage with identities = updated_identities; + next_id = new_id + 1; + } -let update_owner (parameter, storage : (id * address) * storage) = - if amount <> 0tez - then (failwith "Updating owner doesn't cost anything.": return) +let update_owner (parameter, storage: update_owner * storage) = + if (amount <> 0mutez) + then (failwith "Updating owner doesn't cost anything.": (operation list) * storage) else - let id, new_owner = parameter in - let identities, last_id, prices = storage in - let current_id_details : id_details = - match Big_map.find_opt id identities with - | Some id_details -> id_details - | None -> (failwith "This ID does not exist." : id_details) in - let is_allowed : bool = - if Tezos.sender = current_id_details.owner - then true - else (failwith "You are not the owner of this ID." : bool) in - let updated_id_details : id_details = { + let id = parameter.id in + let new_owner = parameter.new_owner in + let identities = storage.identities in + let current_id_details: id_details = + match Big_map.find_opt id identities with + | Some id_details -> id_details + | None -> (failwith "This ID does not exist.": id_details) + in + let u : unit = + if sender = current_id_details.owner + then () + else failwith "You are not the owner of this ID." + in + let updated_id_details: id_details = { owner = new_owner; controller = current_id_details.controller; - profile = current_id_details.profile} in - let updated_identities = - Big_map.update id (Some updated_id_details) identities - in ([]: operation list), (updated_identities, last_id, prices) + profile = current_id_details.profile; + } + in + let updated_identities = Big_map.update id (Some updated_id_details) identities in + ([]: operation list), {storage with identities = updated_identities} -let update_details (parameter, storage: (id * bytes option * address option) * storage) = - if Tezos.amount <> 0tez - then - (failwith "Updating details doesn't cost anything." : return) +let update_details (parameter, storage: update_details * storage) = + if (amount <> 0mutez) + then (failwith "Updating details doesn't cost anything.": (operation list) * storage) else - let id, new_profile, new_controller = parameter in - let identities, last_id, prices = storage in - let current_id_details: id_details = - match Big_map.find_opt id identities with - | Some id_details -> id_details - | None -> (failwith "This ID does not exist.": id_details) in - let is_allowed : bool = - if Tezos.sender = current_id_details.controller - || Tezos.sender = current_id_details.owner - then true - else - (failwith ("You are not the owner or controller of this ID.") - : bool) in - let owner : address = current_id_details.owner in - let profile : bytes = - match new_profile with - | None -> (* Default *) current_id_details.profile - | Some new_profile -> new_profile in - let controller : address = - match new_controller with - | None -> (* Default *) current_id_details.controller - | Some new_controller -> new_controller in - let updated_id_details: id_details = { - owner = owner; - controller = controller; - profile = profile} in + let id = parameter.id in + let new_profile = parameter.new_profile in + let new_controller = parameter.new_controller in + let identities = storage.identities in + let current_id_details: id_details = + match Big_map.find_opt id identities with + | Some id_details -> id_details + | None -> (failwith "This ID does not exist.": id_details) + in + let u : unit = + if (sender = current_id_details.controller) || (sender = current_id_details.owner) + then () + else failwith ("You are not the owner or controller of this ID.") + in + let owner: address = current_id_details.owner in + let profile: bytes = + match new_profile with + | None -> (* Default *) current_id_details.profile + | Some new_profile -> new_profile + in + let controller: address = + match new_controller with + | None -> (* Default *) current_id_details.controller + | Some new_controller -> new_controller + in + let updated_id_details: id_details = { + owner = owner; + controller = controller; + profile = profile; + } + in let updated_identities: (id, id_details) big_map = - Big_map.update id (Some updated_id_details) identities - in ([]: operation list), (updated_identities, last_id, prices) + Big_map.update id (Some updated_id_details) identities in + ([]: operation list), {storage with identities = updated_identities} -(* Let someone skip the next identity so nobody has to take one that's -undesirable *) - -let skip (p, storage: unit * storage) = - let void : unit = - if Tezos.amount <> storage.2.1 - then (failwith "Incorrect amount paid." : unit) in - let identities, last_id, prices = storage in - ([]: operation list), (identities, last_id + 1, prices) +(* Let someone skip the next identity so nobody has to take one that's undesirable *) +let skip (p,storage: unit * storage) = + let void: unit = + if amount = storage.skip_price + then () + else failwith "Incorrect amount paid." + in + ([]: operation list), {storage with next_id = storage.next_id + 1} let main (action, storage : action * storage) : return = match action with diff --git a/src/test/contracts/id.religo b/src/test/contracts/id.religo new file mode 100644 index 000000000..661d544a0 --- /dev/null +++ b/src/test/contracts/id.religo @@ -0,0 +1,167 @@ +type id = int + +type id_details = { + owner: address, + controller: address, + profile: bytes, +} + +type buy = { + profile: bytes, + initial_controller: option(address), +} + +type update_owner = { + id: id, + new_owner: address, +} + +type update_details = { + id: id, + new_profile: option(bytes), + new_controller: option(address), +} + +type action = +| Buy(buy) +| Update_owner(update_owner) +| Update_details(update_details) +| Skip(unit) + +/* The prices kept in storage can be changed by bakers, though they should only be + adjusted down over time, not up. */ +type storage = { + identities: big_map (id, id_details), + next_id: int, + name_price: tez, + skip_price: tez, +} + +/** Preliminary thoughts on ids: + +I very much like the simplicity of http://gurno.com/adam/mne/. +5 three letter words means you have a 15 character identity, not actually more +annoying than an IP address and a lot more memorable than the raw digits. This +can be stored as a single integer which is then translated into the corresponding +series of 5 words. + +I in general like the idea of having a 'skip' mechanism, but it does need to cost +something so people don't eat up the address space. 256 ^ 5 means you have a lot +of address space, but if people troll by skipping a lot that could be eaten up. +Should probably do some napkin calculations for how expensive skipping needs to +be to deter people from doing it just to chew up address space. +*/ + +let buy = ((parameter, storage): (buy, storage)) : (list(operation), storage) => { + let void: unit = + if (amount == storage.name_price) { (); } + else { failwith("Incorrect amount paid."); }; + let profile = parameter.profile; + let initial_controller = parameter.initial_controller; + let identities = storage.identities; + let new_id = storage.next_id; + let controller: address = + switch (initial_controller) { + | Some(addr) => addr + | None => sender + }; + let new_id_details: id_details = { + owner : sender, + controller : controller, + profile : profile, + }; + let updated_identities: big_map (id, id_details) = + Big_map.update(new_id, Some(new_id_details), identities); + (([]: list(operation)), { ...storage, + identities : updated_identities, + next_id : new_id + 1, + }); + }; + +let update_owner = ((parameter, storage): (update_owner, storage)) : (list(operation), storage) => { + let void: unit = + if (amount != 0mutez) { + failwith("Updating owner doesn't cost anything."); + } + else { (); }; + let id : int = parameter.id; + let new_owner = parameter.new_owner; + let identities = storage.identities; + let current_id_details: id_details = + switch (Big_map.find_opt(id, identities)) { + | Some(id_details) => id_details + | None => (failwith("This ID does not exist."): id_details) + }; + let u: unit = + if (sender == current_id_details.owner) { (); } + else { failwith("You are not the owner of this ID."); }; + let updated_id_details: id_details = { + owner : new_owner, + controller : current_id_details.controller, + profile : current_id_details.profile, + }; + let updated_identities = Big_map.update(id, (Some updated_id_details), identities); + (([]: list(operation)), { ...storage, identities : updated_identities }); + }; + +let update_details = ((parameter, storage): (update_details, storage)) : + (list(operation), storage) => { + let void : unit = + if (amount != 0mutez) { + failwith("Updating details doesn't cost anything."); + } + else { (); }; + let id = parameter.id; + let new_profile = parameter.new_profile; + let new_controller = parameter.new_controller; + let identities = storage.identities; + let current_id_details: id_details = + switch (Big_map.find_opt(id, identities)) { + | Some(id_details) => id_details + | None => (failwith("This ID does not exist."): id_details) + }; + let u: unit = + if ((sender != current_id_details.controller) && + (sender != current_id_details.owner)) { + failwith ("You are not the owner or controller of this ID.") + } + else { (); }; + let owner: address = current_id_details.owner; + let profile: bytes = + switch (new_profile) { + | None => /* Default */ current_id_details.profile + | Some(new_profile) => new_profile + }; + let controller: address = + switch (new_controller) { + | None => /* Default */ current_id_details.controller + | Some new_controller => new_controller + }; + let updated_id_details: id_details = { + owner : owner, + controller : controller, + profile : profile, + }; + let updated_identities: big_map (id, id_details) = + Big_map.update(id, (Some updated_id_details), identities); + (([]: list(operation)), { ...storage, identities : updated_identities }); + }; + +/* Let someone skip the next identity so nobody has to take one that's undesirable */ +let skip = ((p,storage): (unit, storage)) => { + let void : unit = + if (amount != storage.skip_price) { + failwith("Incorrect amount paid."); + } + else { (); }; + (([]: list(operation)), { ...storage, next_id : storage.next_id + 1 }); + }; + +let main = ((action, storage): (action, storage)) : (list(operation), storage) => { + switch (action) { + | Buy(b) => buy((b, storage)) + | Update_owner(uo) => update_owner((uo, storage)) + | Update_details ud => update_details((ud, storage)) + | Skip s => skip(((), storage)) + }; +}; diff --git a/src/test/examples/cameligo/arithmetic-contract.ligo b/src/test/examples/cameligo/arithmetic-contract.ligo index 3bcd5660c..c0ac61c52 100644 --- a/src/test/examples/cameligo/arithmetic-contract.ligo +++ b/src/test/examples/cameligo/arithmetic-contract.ligo @@ -15,6 +15,9 @@ evaluateFunction: entrypoint: add parameters: 5, 6 + generateDeployScript: + entrypoint: main + storage: 0 *_*) type storage = int diff --git a/src/test/examples/cameligo/id.mligo b/src/test/examples/cameligo/id.mligo new file mode 100644 index 000000000..9f9fabac9 --- /dev/null +++ b/src/test/examples/cameligo/id.mligo @@ -0,0 +1,243 @@ +(*_* + name: ID Contract (CameLIGO) + language: cameligo + compile: + entrypoint: main + dryRun: + entrypoint: main + parameters: | + Buy ( + { + profile=0x0501000000026869; + initial_controller=Some(("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx": address)) + } + ) + storage: | + { + identities=Big_map.literal[ + (1, + {owner=("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx" : address); + controller=("tz1gjaF81ZRRvdzjobyfVNsAeSC6PScjfQwN" : address); + profile=0x0501000000026869} + ); + ]; + next_id=2; + name_price=0tez; + skip_price=333mutez + } + deploy: + entrypoint: main + storage: | + { + identities=Big_map.literal[ + (1, + {owner=("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx" : address); + controller=("tz1gjaF81ZRRvdzjobyfVNsAeSC6PScjfQwN" : address); + profile=0x0501000000026869} + ); + ]; + next_id=2; + name_price=10tez; + skip_price=333mutez + } + evaluateValue: + entrypoint: "" + evaluateFunction: + entrypoint: buy + parameters: | + { + profile=0x0501000000026869; + initial_controller=Some(("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx": address)) + }, + + { + identities=Big_map.literal[ + (1, + {owner=("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx" : address); + controller=("tz1gjaF81ZRRvdzjobyfVNsAeSC6PScjfQwN" : address); + profile=0x0501000000026869} + ); + ]; + next_id=2; + name_price=0tez; + skip_price=333mutez + } +*_*) + +type id = int + +type id_details = { + owner: address; + controller: address; + profile: bytes; +} + +type buy = { + profile: bytes; + initial_controller: address option; +} + +type update_owner = { + id: id; + new_owner: address; +} + +type update_details = { + id: id; + new_profile: bytes option; + new_controller: address option; +} + +type action = +| Buy of buy +| Update_owner of update_owner +| Update_details of update_details +| Skip of unit + +(* The prices kept in storage can be changed by bakers, though they should only be + adjusted down over time, not up. *) +type storage = { + identities: (id, id_details) big_map; + next_id: int; + name_price: tez; + skip_price: tez; +} + +(** Preliminary thoughts on ids: + +I very much like the simplicity of http://gurno.com/adam/mne/ + +Five three letter words means you have a 15 character identity, not actually more +annoying than an IP address and a lot more memorable than the raw digits. This +can be stored as a single integer which is then translated into the corresponding +series of 5 words. + +I, in general like the idea of having a 'skip' mechanism, but it does need to cost +something so people don't eat up the address space. 256 ^ 5 means you have a lot +of address space, but if people troll by skipping a lot that could be eaten up. +Should probably do some napkin calculations for how expensive skipping needs to +be to deter people from doing it just to chew up address space. +*) + +let buy (parameter, storage: buy * storage) = + let void: unit = + if amount = storage.name_price + then () + else (failwith "Incorrect amount paid.": unit) + in + let profile = parameter.profile in + let initial_controller = parameter.initial_controller in + let identities = storage.identities in + let new_id = storage.next_id in + let controller: address = + match initial_controller with + | Some addr -> addr + | None -> sender + in + let new_id_details: id_details = { + owner = sender ; + controller = controller ; + profile = profile ; + } + in + let updated_identities: (id, id_details) big_map = + Big_map.update new_id (Some new_id_details) identities + in + ([]: operation list), {identities = updated_identities; + next_id = new_id + 1; + name_price = storage.name_price; + skip_price = storage.skip_price; + } + +let update_owner (parameter, storage: update_owner * storage) = + if (amount <> 0mutez) + then (failwith "Updating owner doesn't cost anything.": (operation list) * storage) + else + let id = parameter.id in + let new_owner = parameter.new_owner in + let identities = storage.identities in + let current_id_details: id_details = + match Big_map.find_opt id identities with + | Some id_details -> id_details + | None -> (failwith "This ID does not exist.": id_details) + in + let is_allowed: bool = + if sender = current_id_details.owner + then true + else (failwith "You are not the owner of this ID.": bool) + in + let updated_id_details: id_details = { + owner = new_owner; + controller = current_id_details.controller; + profile = current_id_details.profile; + } + in + let updated_identities = Big_map.update id (Some updated_id_details) identities in + ([]: operation list), {identities = updated_identities; + next_id = storage.next_id; + name_price = storage.name_price; + skip_price = storage.skip_price; + } + +let update_details (parameter, storage: update_details * storage) = + if (amount <> 0mutez) + then (failwith "Updating details doesn't cost anything.": (operation list) * storage) + else + let id = parameter.id in + let new_profile = parameter.new_profile in + let new_controller = parameter.new_controller in + let identities = storage.identities in + let current_id_details: id_details = + match Big_map.find_opt id identities with + | Some id_details -> id_details + | None -> (failwith "This ID does not exist.": id_details) + in + let is_allowed: bool = + if (sender = current_id_details.controller) || (sender = current_id_details.owner) + then true + else (failwith ("You are not the owner or controller of this ID."): bool) + in + let owner: address = current_id_details.owner in + let profile: bytes = + match new_profile with + | None -> (* Default *) current_id_details.profile + | Some new_profile -> new_profile + in + let controller: address = + match new_controller with + | None -> (* Default *) current_id_details.controller + | Some new_controller -> new_controller + in + let updated_id_details: id_details = { + owner = owner; + controller = controller; + profile = profile; + } + in + let updated_identities: (id, id_details) big_map = + Big_map.update id (Some updated_id_details) identities in + ([]: operation list), {identities = updated_identities; + next_id = storage.next_id; + name_price = storage.name_price; + skip_price = storage.skip_price; + } + +(* Let someone skip the next identity so nobody has to take one that's undesirable *) +let skip (p,storage: unit * storage) = + let void: unit = + if amount = storage.skip_price + then () + else (failwith "Incorrect amount paid.": unit) + in + ([]: operation list), {identities = storage.identities; + next_id = storage.next_id + 1; + name_price = storage.name_price; + skip_price = storage.skip_price; + } + +let main (action, storage: action * storage) : operation list * storage = + match action with + | Buy b -> buy (b, storage) + | Update_owner uo -> update_owner (uo, storage) + | Update_details ud -> update_details (ud, storage) + | Skip s -> skip ((), storage) diff --git a/src/test/examples/pascaligo/arithmetic-contract.ligo b/src/test/examples/pascaligo/arithmetic-contract.ligo index 3eb38c48b..4d916311b 100644 --- a/src/test/examples/pascaligo/arithmetic-contract.ligo +++ b/src/test/examples/pascaligo/arithmetic-contract.ligo @@ -15,6 +15,9 @@ evaluateFunction: entrypoint: add parameters: (5, 6) + generateDeployScript: + entrypoint: main + storage: 0 *_*) // variant defining pseudo multi-entrypoint actions type action is diff --git a/src/test/examples/pascaligo/id.ligo b/src/test/examples/pascaligo/id.ligo new file mode 100644 index 000000000..a0023e201 --- /dev/null +++ b/src/test/examples/pascaligo/id.ligo @@ -0,0 +1,242 @@ +(*_* + name: ID Contract (PascaLIGO) + language: pascaligo + compile: + entrypoint: main + dryRun: + entrypoint: main + parameters: | + Buy ( + record [ + profile=0x0501000000026869; + initial_controller=Some(("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx": address)) + ] + ) + storage: | + record [ + identities=big_map[ + 1->record + [owner=("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx" : address); + controller=("tz1gjaF81ZRRvdzjobyfVNsAeSC6PScjfQwN" : address); + profile=0x0501000000026869] + ]; + next_id=2; + name_price=0tez; + skip_price=50mutez; + ] + deploy: + entrypoint: main + storage: | + record [ + identities=big_map[ + 1->record + [owner=("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx" : address); + controller=("tz1gjaF81ZRRvdzjobyfVNsAeSC6PScjfQwN" : address); + profile=0x0501000000026869] + ]; + next_id=2; + name_price=0tez; + skip_price=50mutez; + ] + evaluateValue: + entrypoint: "" + evaluateFunction: + entrypoint: buy + parameters: | + ( + record [ + profile=0x0501000000026869; + initial_controller=Some(("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx": address)) + ], + + record [ identities=big_map[ + 1->record + [owner=("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx" : address); + controller=("tz1gjaF81ZRRvdzjobyfVNsAeSC6PScjfQwN" : address); + profile=0x0501000000026869] + ]; + next_id=2; + name_price=0tez; + skip_price=333mutez; + ] + ) +*_*) + +type id is int + +type id_details is + record [ + owner: address; + controller: address; + profile: bytes; + ] + +type buy is + record [ + profile: bytes; + initial_controller: option(address); + ] + +type update_owner is + record [ + id: id; + new_owner: address; + ] + +type update_details is + record [ + id: id; + new_profile: option(bytes); + new_controller: option(address); + ] + +type action is + | Buy of buy + | Update_owner of update_owner + | Update_details of update_details + | Skip of unit + +(* The prices kept in storage can be changed by bakers, though they should only be + adjusted down over time, not up. *) +type storage is + record [ + identities: big_map (id, id_details); + next_id: int; + name_price: tez; + skip_price: tez; + ] + +(** Preliminary thoughts on ids: + +I very much like the simplicity of http://gurno.com/adam/mne/. +5 three letter words means you have a 15 character identity, not actually more +annoying than an IP address and a lot more memorable than the raw digits. This +can be stored as a single integer which is then translated into the corresponding +series of 5 words. + +I in general like the idea of having a 'skip' mechanism, but it does need to cost +something so people don't eat up the address space. 256 ^ 5 means you have a lot +of address space, but if people troll by skipping a lot that could be eaten up. +Should probably do some napkin calculations for how expensive skipping needs to +be to deter people from doing it just to chew up address space. +*) + +function buy (const parameter : buy; const storage : storage) : list(operation) * storage is + begin + if amount = storage.name_price + then skip + else failwith("Incorrect amount paid."); + const profile : bytes = parameter.profile; + const initial_controller : option(address) = parameter.initial_controller; + var identities : big_map (id, id_details) := storage.identities; + const new_id : int = storage.next_id; + const controller : address = + case initial_controller of + Some(addr) -> addr + | None -> sender + end; + const new_id_details: id_details = + record [ + owner = sender ; + controller = controller ; + profile = profile ; + ]; + identities[new_id] := new_id_details; + end with ((nil : list(operation)), record [ + identities = identities; + next_id = new_id + 1; + name_price = storage.name_price; + skip_price = storage.skip_price; + ]) + +function update_owner (const parameter : update_owner; const storage : storage) : + list(operation) * storage is + begin + if (amount =/= 0mutez) + then + begin + failwith("Updating owner doesn't cost anything."); + end + else skip; + const id : int = parameter.id; + const new_owner : address = parameter.new_owner; + var identities : big_map (id, id_details) := storage.identities; + const id_details : id_details = + case identities[id] of + Some(id_details) -> id_details + | None -> (failwith("This ID does not exist."): id_details) + end; + var is_allowed : bool := False; + if sender = id_details.owner + then is_allowed := True + else failwith("You are not the owner of this ID."); + id_details.owner := new_owner; + identities[id] := id_details; + end with ((nil: list(operation)), record [ + identities = identities; + next_id = storage.next_id; + name_price = storage.name_price; + skip_price = storage.skip_price; + ]) + +function update_details (const parameter : update_details; const storage : storage ) : + list(operation) * storage is + begin + if (amount =/= 0mutez) + then failwith("Updating details doesn't cost anything.") + else skip; + const id : int = parameter.id; + const new_profile : option(bytes) = parameter.new_profile; + const new_controller : option(address) = parameter.new_controller; + const identities : big_map (id, id_details) = storage.identities; + const id_details: id_details = + case identities[id] of + Some(id_details) -> id_details + | None -> (failwith("This ID does not exist."): id_details) + end; + var is_allowed : bool := False; + if (sender = id_details.controller) or (sender = id_details.owner) + then is_allowed := True + else failwith("You are not the owner or controller of this ID."); + const owner: address = id_details.owner; + const profile: bytes = + case new_profile of + None -> (* Default *) id_details.profile + | Some(new_profile) -> new_profile + end; + const controller: address = + case new_controller of + None -> (* Default *) id_details.controller + | Some(new_controller) -> new_controller + end; + id_details.owner := owner; + id_details.controller := controller; + id_details.profile := profile; + identities[id] := id_details; + end with ((nil: list(operation)), record [ + identities = identities; + next_id = storage.next_id; + name_price = storage.name_price; + skip_price = storage.skip_price; + ]) + +(* Let someone skip the next identity so nobody has to take one that's undesirable *) +function skip_ (const p: unit; const storage: storage) : list(operation) * storage is + begin + if amount = storage.skip_price + then skip + else failwith("Incorrect amount paid."); + end with ((nil: list(operation)), record [ + identities = storage.identities; + next_id = storage.next_id + 1; + name_price = storage.name_price; + skip_price = storage.skip_price; + ]) + +function main (const action : action; const storage : storage) : list(operation) * storage is + case action of + | Buy(b) -> buy (b, storage) + | Update_owner(uo) -> update_owner (uo, storage) + | Update_details(ud) -> update_details (ud, storage) + | Skip(s) -> skip_ (unit, storage) + end; diff --git a/src/test/examples/reasonligo/arithmetic-contract.ligo b/src/test/examples/reasonligo/arithmetic-contract.ligo index ecb06a569..142d737aa 100644 --- a/src/test/examples/reasonligo/arithmetic-contract.ligo +++ b/src/test/examples/reasonligo/arithmetic-contract.ligo @@ -15,6 +15,9 @@ evaluateFunction: entrypoint: add parameters: (5, 6) + generateDeployScript: + entrypoint: main + storage: 0 *_*) type storage = int; diff --git a/src/test/examples/reasonligo/id.religo b/src/test/examples/reasonligo/id.religo new file mode 100644 index 000000000..9131a9080 --- /dev/null +++ b/src/test/examples/reasonligo/id.religo @@ -0,0 +1,248 @@ +/* (*_* + name: ID Contract (ReasonLIGO) + language: reasonligo + compile: + entrypoint: main + dryRun: + entrypoint: main + parameters: | + Buy ( + { + profile: 0x0501000000026869, + initial_controller: Some(("tz1gjaF81ZRRvdzjobyfVNsAeSC6PScjfQwN" : address)) + } + ) + storage: | + { + identities:Big_map.literal([ + (1, + {owner:("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx" : address), + controller:("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx": address), profile:0x0501000000026869} + ) + ]), + next_id:2, + name_price:0tez, + skip_price:333mutez + } + deploy: + entrypoint: main + storage: | + { + identities:Big_map.literal([ + (1, + {owner:("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx" : address), controller:("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx": address), profile:0x0501000000026869} + ) + ]), + next_id:2, + name_price:10tez, + skip_price:333mutez + } + evaluateValue: + entrypoint: "" + evaluateFunction: + entrypoint: buy + parameters: | + ( + { + profile: 0x0501000000026869, + initial_controller: Some(("tz1gjaF81ZRRvdzjobyfVNsAeSC6PScjfQwN" : address)) + }, + { + identities:Big_map.literal([ + (1, + {owner:("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx" : address), + controller:("tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx": address), + profile:0x0501000000026869} + ) + ]), + next_id:2, + name_price:0tez, + skip_price:333mutez + } + ) +*_*) */ + +type id = int + +type id_details = { + owner: address, + controller: address, + profile: bytes, +} + +type buy = { + profile: bytes, + initial_controller: option(address), +} + +type update_owner = { + id: id, + new_owner: address, +} + +type update_details = { + id: id, + new_profile: option(bytes), + new_controller: option(address), +} + +type action = +| Buy(buy) +| Update_owner(update_owner) +| Update_details(update_details) +| Skip(unit) + +/* The prices kept in storage can be changed by bakers, though they should only be + adjusted down over time, not up. */ +type storage = { + identities: big_map (id, id_details), + next_id: int, + name_price: tez, + skip_price: tez, +} + +/** Preliminary thoughts on ids: + +I very much like the simplicity of http://gurno.com/adam/mne/. +5 three letter words means you have a 15 character identity, not actually more +annoying than an IP address and a lot more memorable than the raw digits. This +can be stored as a single integer which is then translated into the corresponding +series of 5 words. + +I in general like the idea of having a 'skip' mechanism, but it does need to cost +something so people don't eat up the address space. 256 ^ 5 means you have a lot +of address space, but if people troll by skipping a lot that could be eaten up. +Should probably do some napkin calculations for how expensive skipping needs to +be to deter people from doing it just to chew up address space. +*/ + +let buy = ((parameter, storage): (buy, storage)) : (list(operation), storage) => { + let void: unit = + if (amount == storage.name_price) { (); } + else { failwith("Incorrect amount paid."); }; + let profile = parameter.profile; + let initial_controller = parameter.initial_controller; + let identities = storage.identities; + let new_id = storage.next_id; + let controller: address = + switch (initial_controller) { + | Some(addr) => addr + | None => sender + }; + let new_id_details: id_details = { + owner : sender, + controller : controller, + profile : profile, + }; + let updated_identities: big_map (id, id_details) = + Big_map.update(new_id, Some(new_id_details), identities); + (([]: list(operation)), { + identities : updated_identities, + next_id : new_id + 1, + name_price : storage.name_price, + skip_price : storage.skip_price, + }); + }; + +let update_owner = ((parameter, storage): (update_owner, storage)) : (list(operation), storage) => { + let void: unit = + if (amount != 0mutez) { + failwith("Updating owner doesn't cost anything."); + } + else { (); }; + let id : int = parameter.id; + let new_owner = parameter.new_owner; + let identities = storage.identities; + let current_id_details: id_details = + switch (Big_map.find_opt(id, identities)) { + | Some(id_details) => id_details + | None => (failwith("This ID does not exist."): id_details) + }; + let is_allowed: bool = + if (sender == current_id_details.owner) { true; } + else { (failwith("You are not the owner of this ID."): bool); }; + let updated_id_details: id_details = { + owner : new_owner, + controller : current_id_details.controller, + profile : current_id_details.profile, + }; + let updated_identities = Big_map.update(id, (Some updated_id_details), identities); + (([]: list(operation)), { + identities : updated_identities, + next_id : storage.next_id, + name_price : storage.name_price, + skip_price : storage.skip_price, + }); + }; + +let update_details = ((parameter, storage): (update_details, storage)) : + (list(operation), storage) => { + let void : unit = + if (amount != 0mutez) { + failwith("Updating details doesn't cost anything."); + } + else { (); }; + let id = parameter.id; + let new_profile = parameter.new_profile; + let new_controller = parameter.new_controller; + let identities = storage.identities; + let current_id_details: id_details = + switch (Big_map.find_opt(id, identities)) { + | Some(id_details) => id_details + | None => (failwith("This ID does not exist."): id_details) + }; + let is_allowed: bool = + if ((sender != current_id_details.controller) && + (sender != current_id_details.owner)) { + (failwith ("You are not the owner or controller of this ID."): bool) + } + else { true; }; + let owner: address = current_id_details.owner; + let profile: bytes = + switch (new_profile) { + | None => /* Default */ current_id_details.profile + | Some(new_profile) => new_profile + }; + let controller: address = + switch (new_controller) { + | None => /* Default */ current_id_details.controller + | Some new_controller => new_controller + }; + let updated_id_details: id_details = { + owner : owner, + controller : controller, + profile : profile, + }; + let updated_identities: big_map (id, id_details) = + Big_map.update(id, (Some updated_id_details), identities); + (([]: list(operation)), { + identities : updated_identities, + next_id : storage.next_id, + name_price : storage.name_price, + skip_price : storage.skip_price, + }); + }; + +/* Let someone skip the next identity so nobody has to take one that's undesirable */ +let skip = ((p,storage): (unit, storage)) => { + let void : unit = + if (amount != storage.skip_price) { + failwith("Incorrect amount paid."); + } + else { (); }; + (([]: list(operation)), { + identities : storage.identities, + next_id : storage.next_id + 1, + name_price : storage.name_price, + skip_price : storage.skip_price, + }); + }; + +let main = ((action, storage): (action, storage)) : (list(operation), storage) => { + switch (action) { + | Buy(b) => buy((b, storage)) + | Update_owner(uo) => update_owner((uo, storage)) + | Update_details ud => update_details((ud, storage)) + | Skip s => skip(((), storage)) + }; +}; diff --git a/src/test/hash_lock_tests.ml b/src/test/hash_lock_tests.ml index 3f9e79c79..b7bbe7bf1 100644 --- a/src/test/hash_lock_tests.ml +++ b/src/test/hash_lock_tests.ml @@ -50,7 +50,7 @@ let empty_message = e_lambda (Var.of_name "arguments") let commit () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let%bind predecessor_timestamp = mk_time "2000-01-01T00:10:10Z" in let%bind lock_time = mk_time "2000-01-02T00:10:11Z" in let test_hash_raw = sha_256_hash (Bytes.of_string "hello world") in @@ -79,12 +79,12 @@ let commit () = ~sender:first_contract () in - expect_eq ~options program "commit" + expect_eq ~options (program, state) "commit" (e_pair salted_hash init_storage) (e_pair empty_op_list post_storage) (* Test that the contract fails if we haven't committed before revealing the answer *) let reveal_no_commit () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let empty_message = empty_message in let reveal = e_record_ez [("hashable", e_bytes_string "hello world"); ("message", empty_message)] @@ -95,13 +95,13 @@ let reveal_no_commit () = ("salted_hash", (t_bytes ()))]) in let init_storage = storage test_hash true pre_commits in - expect_string_failwith program "reveal" + expect_string_failwith (program, state) "reveal" (e_pair reveal init_storage) "You have not made a commitment to hash against yet." (* Test that the contract fails if our commit isn't 24 hours old yet *) let reveal_young_commit () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let empty_message = empty_message in let reveal = e_record_ez [("hashable", e_bytes_string "hello world"); ("message", empty_message)] @@ -128,13 +128,13 @@ let reveal_young_commit () = ~sender:first_contract () in - expect_string_failwith ~options program "reveal" + expect_string_failwith ~options (program, state) "reveal" (e_pair reveal init_storage) "It has not been 24 hours since your commit yet." (* Test that the contract fails if our reveal doesn't meet our commitment *) let reveal_breaks_commit () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let empty_message = empty_message in let reveal = e_record_ez [("hashable", e_bytes_string "hello world"); ("message", empty_message)] @@ -160,13 +160,13 @@ let reveal_breaks_commit () = ~sender:first_contract () in - expect_string_failwith ~options program "reveal" + expect_string_failwith ~options (program, state) "reveal" (e_pair reveal init_storage) "This reveal does not match your commitment." (* Test that the contract fails if we reveal the wrong bytes for the stored hash *) let reveal_wrong_commit () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let empty_message = empty_message in let reveal = e_record_ez [("hashable", e_bytes_string "hello"); ("message", empty_message)] @@ -192,13 +192,13 @@ let reveal_wrong_commit () = ~sender:first_contract () in - expect_string_failwith ~options program "reveal" + expect_string_failwith ~options (program, state) "reveal" (e_pair reveal init_storage) "Your commitment did not match the storage hash." (* Test that the contract fails if we try to reuse it after unused flag changed *) let reveal_no_reuse () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let empty_message = empty_message in let reveal = e_record_ez [("hashable", e_bytes_string "hello"); ("message", empty_message)] @@ -224,13 +224,13 @@ let reveal_no_reuse () = ~sender:first_contract () in - expect_string_failwith ~options program "reveal" + expect_string_failwith ~options (program, state) "reveal" (e_pair reveal init_storage) "This contract has already been used." (* Test that the contract executes successfully with valid commit-reveal *) let reveal () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let empty_message = empty_message in let reveal = e_record_ez [("hashable", e_bytes_string "hello world"); ("message", empty_message)] @@ -257,7 +257,7 @@ let reveal () = ~sender:first_contract () in - expect_eq ~options program "reveal" + expect_eq ~options (program, state) "reveal" (e_pair reveal init_storage) (e_pair empty_op_list post_storage) let main = test_suite "Hashlock" [ diff --git a/src/test/id_tests.ml b/src/test/id_tests.ml index f5839dd5b..9c86aecc5 100644 --- a/src/test/id_tests.ml +++ b/src/test/id_tests.ml @@ -33,16 +33,17 @@ let (first_owner , first_contract) = Protocol.Alpha_context.Contract.to_b58check kt , kt let buy_id () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let owner_addr = addr 5 in let owner_website = e_bytes_string "ligolang.org" in let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; ("controller", e_address owner_addr) ; ("profile", owner_website)] in - let storage = e_tuple [(e_big_map [(e_int 0, id_details_1)]) ; - e_int 1; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let storage = e_record_ez [("identities", (e_big_map [(e_int 0, id_details_1)])) ; + ("next_id", e_int 1) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in let new_addr = first_owner in let options = Proto_alpha_utils.Memory_proto_alpha.make_options @@ -54,28 +55,33 @@ let buy_id () = ("controller", e_address new_addr) ; ("profile", new_website)] in - let param = e_pair owner_website (e_some (e_address new_addr)) in - let new_storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let param = e_record_ez [("profile", owner_website) ; + ("initial_controller", (e_some (e_address new_addr))) ; + ] in + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in - let%bind () = expect_eq ~options program "buy" + let%bind () = expect_eq ~options (program, state) "buy" (e_pair param storage) (e_pair (e_list []) new_storage) in ok () let buy_id_sender_addr () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let owner_addr = addr 5 in let owner_website = e_bytes_string "ligolang.org" in let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; ("controller", e_address owner_addr) ; ("profile", owner_website)] in - let storage = e_tuple [(e_big_map [(e_int 0, id_details_1)]) ; - e_int 1; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let storage = e_record_ez [("identities", (e_big_map [(e_int 0, id_details_1)])) ; + ("next_id", e_int 1) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in let new_addr = first_owner in let options = Proto_alpha_utils.Memory_proto_alpha.make_options @@ -87,43 +93,48 @@ let buy_id_sender_addr () = ("controller", e_address new_addr) ; ("profile", new_website)] in - let param = e_pair owner_website (e_typed_none (t_address ())) in - let new_storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let param = e_record_ez [("profile", owner_website) ; + ("initial_controller", (e_typed_none (t_address ())))] in + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in - let%bind () = expect_eq ~options program "buy" + let%bind () = expect_eq ~options (program, state) "buy" (e_pair param storage) (e_pair (e_list []) new_storage) in ok () (* Test that contract fails if we attempt to buy an ID for the wrong amount *) let buy_id_wrong_amount () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let owner_addr = addr 5 in let owner_website = e_bytes_string "ligolang.org" in let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; ("controller", e_address owner_addr) ; ("profile", owner_website)] in - let storage = e_tuple [(e_big_map [(e_int 0, id_details_1)]) ; - e_int 1; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let storage = e_record_ez [("identities", (e_big_map [(e_int 0, id_details_1)])) ; + ("next_id", e_int 1) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in let new_addr = first_owner in let options = Proto_alpha_utils.Memory_proto_alpha.make_options ~sender:first_contract ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.fifty_cents) () in - let param = e_pair owner_website (e_some (e_address new_addr)) in - let%bind () = expect_string_failwith ~options program "buy" - (e_pair param storage) + let param = e_record_ez [("profile", owner_website) ; + ("initial_controller", (e_some (e_address new_addr)))] in + let%bind () = expect_string_failwith ~options (program, state) "buy" + (e_pair param storage) "Incorrect amount paid." in ok () let update_details_owner () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let owner_addr = addr 5 in let owner_website = e_bytes_string "ligolang.org" in let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; @@ -133,7 +144,7 @@ let update_details_owner () = let new_addr = first_owner in let options = Proto_alpha_utils.Memory_proto_alpha.make_options ~sender:first_contract - ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) () in let new_website = e_bytes_string "ligolang.org" in @@ -144,27 +155,31 @@ let update_details_owner () = let id_details_2_diff = e_record_ez [("owner", e_address new_addr) ; ("controller", e_address new_addr) ; ("profile", new_website)] in - let storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in - let new_storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2_diff)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2_diff)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in let details = e_bytes_string "ligolang.org" in - let param = e_tuple [e_int 1 ; - e_some details ; - e_some (e_address new_addr)] in - let%bind () = expect_eq ~options program "update_details" + let param = e_record_ez [("id", e_int 1) ; + ("new_profile", e_some details) ; + ("new_controller", e_some (e_address new_addr))] in + let%bind () = expect_eq ~options (program, state) "update_details" (e_pair param storage) (e_pair (e_list []) new_storage) in ok () let update_details_controller () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let owner_addr = addr 5 in let owner_website = e_bytes_string "ligolang.org" in let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; @@ -185,28 +200,32 @@ let update_details_controller () = let id_details_2_diff = e_record_ez [("owner", e_address owner_addr) ; ("controller", e_address owner_addr) ; ("profile", new_website)] in - let storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in - let new_storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2_diff)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2_diff)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in let details = e_bytes_string "ligolang.org" in - let param = e_tuple [e_int 1 ; - e_some details ; - e_some (e_address owner_addr)] in - let%bind () = expect_eq ~options program "update_details" + let param = e_record_ez [("id", e_int 1) ; + ("new_profile", e_some details) ; + ("new_controller", e_some (e_address owner_addr))] in + let%bind () = expect_eq ~options (program, state) "update_details" (e_pair param storage) (e_pair (e_list []) new_storage) in ok () (* Test that contract fails when we attempt to update details of nonexistent ID *) let update_details_nonexistent () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let owner_addr = addr 5 in let owner_website = e_bytes_string "ligolang.org" in let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; @@ -224,23 +243,25 @@ let update_details_nonexistent () = ("controller", e_address new_addr) ; ("profile", new_website)] in - let storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in let details = e_bytes_string "ligolang.org" in - let param = e_tuple [e_int 2 ; - e_some details ; - e_some (e_address owner_addr)] in - let%bind () = expect_string_failwith ~options program "update_details" + let param = e_record_ez [("id", e_int 2) ; + ("new_profile", e_some details) ; + ("new_controller", e_some (e_address owner_addr))] in + let%bind () = expect_string_failwith ~options (program, state) "update_details" (e_pair param storage) "This ID does not exist." in ok () (* Test that contract fails when we attempt to update details from wrong addr *) let update_details_wrong_addr () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let owner_addr = addr 5 in let owner_website = e_bytes_string "ligolang.org" in let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; @@ -257,23 +278,25 @@ let update_details_wrong_addr () = ("controller", e_address new_addr) ; ("profile", new_website)] in - let storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in let details = e_bytes_string "ligolang.org" in - let param = e_tuple [e_int 0 ; - e_some details ; - e_some (e_address owner_addr)] in - let%bind () = expect_string_failwith ~options program "update_details" + let param = e_record_ez [("id", e_int 0) ; + ("new_profile", e_some details) ; + ("new_controller", e_some (e_address owner_addr))] in + let%bind () = expect_string_failwith ~options (program, state) "update_details" (e_pair param storage) "You are not the owner or controller of this ID." in ok () (* Test that giving none on both profile and controller address is a no-op *) let update_details_unchanged () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let owner_addr = addr 5 in let owner_website = e_bytes_string "ligolang.org" in let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; @@ -291,21 +314,23 @@ let update_details_unchanged () = ("controller", e_address new_addr) ; ("profile", new_website)] in - let storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in - let param = e_tuple [e_int 1 ; - e_typed_none (t_bytes ()) ; - e_typed_none (t_address ())] in - let%bind () = expect_eq ~options program "update_details" + let param = e_record_ez [("id", e_int 1) ; + ("new_profile", e_typed_none (t_bytes ())) ; + ("new_controller", e_typed_none (t_address ()))] in + let%bind () = expect_eq ~options (program, state) "update_details" (e_pair param storage) (e_pair (e_list []) storage) in ok () let update_owner () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let owner_addr = addr 5 in let owner_website = e_bytes_string "ligolang.org" in let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; @@ -326,25 +351,30 @@ let update_owner () = let id_details_2_diff = e_record_ez [("owner", e_address owner_addr) ; ("controller", e_address new_addr) ; ("profile", new_website)] in - let storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in - let new_storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2_diff)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2_diff)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in - let param = e_pair (e_int 1) (e_address owner_addr) in - let%bind () = expect_eq ~options program "update_owner" + let param = e_record_ez [("id", e_int 1) ; + ("new_owner", e_address owner_addr)] in + let%bind () = expect_eq ~options (program, state) "update_owner" (e_pair param storage) (e_pair (e_list []) new_storage) in ok () (* Test that contract fails when we attempt to update owner of nonexistent ID *) let update_owner_nonexistent () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let owner_addr = addr 5 in let owner_website = e_bytes_string "ligolang.org" in let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; @@ -362,20 +392,23 @@ let update_owner_nonexistent () = ("controller", e_address new_addr) ; ("profile", new_website)] in - let storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in - let param = e_pair (e_int 2) (e_address new_addr) in - let%bind () = expect_string_failwith ~options program "update_owner" + let param = e_record_ez [("id", e_int 2); + ("new_owner", e_address new_addr)] in + let%bind () = expect_string_failwith ~options (program, state) "update_owner" (e_pair param storage) "This ID does not exist." in ok () (* Test that contract fails when we attempt to update owner from non-owner addr *) let update_owner_wrong_addr () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let owner_addr = addr 5 in let owner_website = e_bytes_string "ligolang.org" in let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; @@ -393,19 +426,22 @@ let update_owner_wrong_addr () = ("controller", e_address new_addr) ; ("profile", new_website)] in - let storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in - let param = e_pair (e_int 0) (e_address new_addr) in - let%bind () = expect_string_failwith ~options program "update_owner" + let param = e_record_ez [("id", e_int 0); + ("new_owner", e_address new_addr)] in + let%bind () = expect_string_failwith ~options (program, state) "update_owner" (e_pair param storage) "You are not the owner of this ID." in ok () let skip () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let owner_addr = addr 5 in let owner_website = e_bytes_string "ligolang.org" in let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; @@ -422,24 +458,28 @@ let skip () = ("controller", e_address new_addr) ; ("profile", new_website)] in - let storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in - let new_storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2)]) ; - e_int 3; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 3) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in - let%bind () = expect_eq ~options program "skip" + let%bind () = expect_eq ~options (program, state) "skip" (e_pair (e_unit ()) storage) (e_pair (e_list []) new_storage) in ok () (* Test that contract fails if we try to skip without paying the right amount *) let skip_wrong_amount () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let owner_addr = addr 5 in let owner_website = e_bytes_string "ligolang.org" in let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; @@ -456,17 +496,19 @@ let skip_wrong_amount () = ("controller", e_address new_addr) ; ("profile", new_website)] in - let storage = e_tuple [(e_big_map [(e_int 0, id_details_1) ; - (e_int 1, id_details_2)]) ; - e_int 2; - e_tuple [e_mutez 1000000 ; e_mutez 1000000]] + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] in - let%bind () = expect_string_failwith ~options program "skip" + let%bind () = expect_string_failwith ~options (program, state) "skip" (e_pair (e_unit ()) storage) "Incorrect amount paid." in ok () -let main = test_suite "ID Layer" [ +let main = test_suite "ID Layer (CameLIGO)" [ test "buy" buy_id ; test "buy (sender addr)" buy_id_sender_addr ; test "buy (wrong amount)" buy_id_wrong_amount ; diff --git a/src/test/id_tests_p.ml b/src/test/id_tests_p.ml new file mode 100644 index 000000000..714af1c39 --- /dev/null +++ b/src/test/id_tests_p.ml @@ -0,0 +1,522 @@ +open Trace +open Test_helpers +open Ast_imperative + + +let type_file f = + let%bind typed,state = Ligo.Compile.Utils.type_file f "pascaligo" (Contract "main") in + ok (typed,state) + +let get_program = + let s = ref None in + fun () -> match !s with + | Some s -> ok s + | None -> ( + let%bind program = type_file "./contracts/id.ligo" in + s := Some program ; + ok program + ) + +let compile_main () = + let%bind typed_prg,_ = get_program () in + let%bind mini_c_prg = Ligo.Compile.Of_typed.compile typed_prg in + let%bind michelson_prg = Ligo.Compile.Of_mini_c.aggregate_and_compile_contract mini_c_prg "main" in + let%bind (_contract: Tezos_utils.Michelson.michelson) = + (* fails if the given entry point is not a valid contract *) + Ligo.Compile.Of_michelson.build_contract michelson_prg in + ok () + +let (first_owner , first_contract) = + let open Proto_alpha_utils.Memory_proto_alpha in + let id = List.nth dummy_environment.identities 0 in + let kt = id.implicit_contract in + Protocol.Alpha_context.Contract.to_b58check kt , kt + +let buy_id () = + let%bind program, state = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let storage = e_record_ez [("identities", (e_big_map [(e_int 0, id_details_1)])) ; + ("next_id", e_int 1) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.one) () + in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", owner_website)] + in + let param = e_record_ez [("profile", owner_website) ; + ("initial_controller", (e_some (e_address new_addr))) ; + ] in + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let%bind () = expect_eq ~options (program, state) "buy" + (e_pair param storage) + (e_pair (e_list []) new_storage) + in ok () + +let buy_id_sender_addr () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let storage = e_record_ez [("identities", (e_big_map [(e_int 0, id_details_1)])) ; + ("next_id", e_int 1) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.one) () + in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", owner_website)] + in + let param = e_record_ez [("profile", owner_website) ; + ("initial_controller", (e_typed_none (t_address ())))] in + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let%bind () = expect_eq ~options program "buy" + (e_pair param storage) + (e_pair (e_list []) new_storage) + in ok () + +(* Test that contract fails if we attempt to buy an ID for the wrong amount *) +let buy_id_wrong_amount () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let storage = e_record_ez [("identities", (e_big_map [(e_int 0, id_details_1)])) ; + ("next_id", e_int 1) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.fifty_cents) () + in + let param = e_record_ez [("profile", owner_website) ; + ("initial_controller", (e_some (e_address new_addr)))] in + let%bind () = expect_string_failwith ~options program "buy" + (e_pair param storage) + "Incorrect amount paid." + in ok () + +let update_details_owner () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let id_details_2_diff = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", owner_website)] in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2_diff)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let details = owner_website in + let param = e_record_ez [("id", e_int 1) ; + ("new_profile", e_some details) ; + ("new_controller", e_some (e_address new_addr))] in + let%bind () = expect_eq ~options program "update_details" + (e_pair param storage) + (e_pair (e_list []) new_storage) + in ok () + +let update_details_controller () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = owner_website in + let id_details_2 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let id_details_2_diff = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", new_website)] in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2_diff)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let details = e_bytes_string "ligolang.org" in + let param = e_record_ez [("id", e_int 1) ; + ("new_profile", e_some details) ; + ("new_controller", e_some (e_address owner_addr))] in + let%bind () = expect_eq ~options program "update_details" + (e_pair param storage) + (e_pair (e_list []) new_storage) + in ok () + +(* Test that contract fails when we attempt to update details of nonexistent ID *) +let update_details_nonexistent () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let details = e_bytes_string "ligolang.org" in + let param = e_record_ez [("id", e_int 2) ; + ("new_profile", e_some details) ; + ("new_controller", e_some (e_address owner_addr))] in + let%bind () = expect_string_failwith ~options program "update_details" + (e_pair param storage) + "This ID does not exist." + in ok () + +(* Test that contract fails when we attempt to update details from wrong addr *) +let update_details_wrong_addr () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let details = e_bytes_string "ligolang.org" in + let param = e_record_ez [("id", e_int 0) ; + ("new_profile", e_some details) ; + ("new_controller", e_some (e_address owner_addr))] in + let%bind () = expect_string_failwith ~options program "update_details" + (e_pair param storage) + "You are not the owner or controller of this ID." + in ok () + +(* Test that giving none on both profile and controller address is a no-op *) +let update_details_unchanged () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let param = e_record_ez [("id", e_int 1) ; + ("new_profile", e_typed_none (t_bytes ())) ; + ("new_controller", e_typed_none (t_address ()))] in + let%bind () = expect_eq ~options program "update_details" + (e_pair param storage) + (e_pair (e_list []) storage) + in ok () + +let update_owner () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let id_details_2_diff = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2_diff)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let param = e_record_ez [("id", e_int 1) ; + ("new_owner", e_address owner_addr)] in + let%bind () = expect_eq ~options program "update_owner" + (e_pair param storage) + (e_pair (e_list []) new_storage) + in ok () + +(* Test that contract fails when we attempt to update owner of nonexistent ID *) +let update_owner_nonexistent () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let param = e_record_ez [("id", e_int 2); + ("new_owner", e_address new_addr)] in + let%bind () = expect_string_failwith ~options program "update_owner" + (e_pair param storage) + "This ID does not exist." + in ok () + +(* Test that contract fails when we attempt to update owner from non-owner addr *) +let update_owner_wrong_addr () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let param = e_record_ez [("id", e_int 0); + ("new_owner", e_address new_addr)] in + let%bind () = expect_string_failwith ~options program "update_owner" + (e_pair param storage) + "You are not the owner of this ID." + in ok () + +let skip () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.one) () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 3) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let%bind () = expect_eq ~options program "skip_" + (e_pair (e_unit ()) storage) + (e_pair (e_list []) new_storage) + in ok () + +(* Test that contract fails if we try to skip without paying the right amount *) +let skip_wrong_amount () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.fifty_cents) () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let%bind () = expect_string_failwith ~options program "skip_" + (e_pair (e_unit ()) storage) + "Incorrect amount paid." + in ok () + +let main = test_suite "ID Layer (PascaLIGO)" [ + test "buy" buy_id ; + test "buy (sender addr)" buy_id_sender_addr ; + test "buy (wrong amount)" buy_id_wrong_amount ; + test "update_details (owner)" update_details_owner ; + test "update_details (controller)" update_details_controller ; + test "update_details_nonexistent" update_details_nonexistent ; + test "update_details_wrong_addr" update_details_wrong_addr ; + test "update_details_unchanged" update_details_unchanged ; + test "update_owner" update_owner ; + test "update_owner_nonexistent" update_owner_nonexistent ; + test "update_owner_wrong_addr" update_owner_wrong_addr ; + test "skip" skip ; + test "skip (wrong amount)" skip_wrong_amount ; +] diff --git a/src/test/id_tests_r.ml b/src/test/id_tests_r.ml new file mode 100644 index 000000000..d36c84929 --- /dev/null +++ b/src/test/id_tests_r.ml @@ -0,0 +1,525 @@ +open Trace +open Test_helpers +open Ast_imperative + + +let retype_file f = + let%bind typed,state = Ligo.Compile.Utils.type_file f "reasonligo" (Contract "main") in + ok (typed,state) + +let get_program = + let s = ref None in + fun () -> match !s with + | Some s -> ok s + | None -> ( + let%bind program = retype_file "./contracts/id.religo" in + s := Some program ; + ok program + ) + +let compile_main () = + let%bind typed_prg,_ = get_program () in + let%bind mini_c_prg = Ligo.Compile.Of_typed.compile typed_prg in + let%bind michelson_prg = Ligo.Compile.Of_mini_c.aggregate_and_compile_contract mini_c_prg "main" in + let%bind (_contract: Tezos_utils.Michelson.michelson) = + (* fails if the given entry point is not a valid contract *) + Ligo.Compile.Of_michelson.build_contract michelson_prg in + ok () + +let (first_owner , first_contract) = + let open Proto_alpha_utils.Memory_proto_alpha in + let id = List.nth dummy_environment.identities 0 in + let kt = id.implicit_contract in + Protocol.Alpha_context.Contract.to_b58check kt , kt + +let buy_id () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let storage = e_record_ez [("identities", (e_big_map [(e_int 0, id_details_1)])) ; + ("next_id", e_int 1) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.one) () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let param = e_record_ez [("profile", owner_website) ; + ("initial_controller", (e_some (e_address new_addr))) ; + ] in + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let%bind () = expect_eq ~options program "buy" + (e_pair param storage) + (e_pair (e_list []) new_storage) + in ok () + +let buy_id_sender_addr () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let storage = e_record_ez [("identities", (e_big_map [(e_int 0, id_details_1)])) ; + ("next_id", e_int 1) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.one) () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let param = e_record_ez [("profile", owner_website) ; + ("initial_controller", (e_typed_none (t_address ())))] in + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let%bind () = expect_eq ~options program "buy" + (e_pair param storage) + (e_pair (e_list []) new_storage) + in ok () + +(* Test that contract fails if we attempt to buy an ID for the wrong amount *) +let buy_id_wrong_amount () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let storage = e_record_ez [("identities", (e_big_map [(e_int 0, id_details_1)])) ; + ("next_id", e_int 1) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.fifty_cents) () + in + let param = e_record_ez [("profile", owner_website) ; + ("initial_controller", (e_some (e_address new_addr)))] in + let%bind () = expect_string_failwith ~options program "buy" + (e_pair param storage) + "Incorrect amount paid." + in ok () + +let update_details_owner () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address owner_addr) ; + ("profile", new_website)] + in + let id_details_2_diff = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2_diff)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let details = e_bytes_string "ligolang.org" in + let param = e_record_ez [("id", e_int 1) ; + ("new_profile", e_some details) ; + ("new_controller", e_some (e_address new_addr))] in + let%bind () = expect_eq ~options program "update_details" + (e_pair param storage) + (e_pair (e_list []) new_storage) + in ok () + +let update_details_controller () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let id_details_2_diff = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", new_website)] in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2_diff)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let details = e_bytes_string "ligolang.org" in + let param = e_record_ez [("id", e_int 1) ; + ("new_profile", e_some details) ; + ("new_controller", e_some (e_address owner_addr))] in + let%bind () = expect_eq ~options program "update_details" + (e_pair param storage) + (e_pair (e_list []) new_storage) + in ok () + +(* Test that contract fails when we attempt to update details of nonexistent ID *) +let update_details_nonexistent () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let details = e_bytes_string "ligolang.org" in + let param = e_record_ez [("id", e_int 2) ; + ("new_profile", e_some details) ; + ("new_controller", e_some (e_address owner_addr))] in + let%bind () = expect_string_failwith ~options program "update_details" + (e_pair param storage) + "This ID does not exist." + in ok () + +(* Test that contract fails when we attempt to update details from wrong addr *) +let update_details_wrong_addr () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let details = e_bytes_string "ligolang.org" in + let param = e_record_ez [("id", e_int 0) ; + ("new_profile", e_some details) ; + ("new_controller", e_some (e_address owner_addr))] in + let%bind () = expect_string_failwith ~options program "update_details" + (e_pair param storage) + "You are not the owner or controller of this ID." + in ok () + +(* Test that giving none on both profile and controller address is a no-op *) +let update_details_unchanged () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let param = e_record_ez [("id", e_int 1) ; + ("new_profile", e_typed_none (t_bytes ())) ; + ("new_controller", e_typed_none (t_address ()))] in + let%bind () = expect_eq ~options program "update_details" + (e_pair param storage) + (e_pair (e_list []) storage) + in ok () + +let update_owner () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let id_details_2_diff = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2_diff)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let param = e_record_ez [("id", e_int 1) ; + ("new_owner", e_address owner_addr)] in + let%bind () = expect_eq ~options program "update_owner" + (e_pair param storage) + (e_pair (e_list []) new_storage) + in ok () + +(* Test that contract fails when we attempt to update owner of nonexistent ID *) +let update_owner_nonexistent () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let param = e_record_ez [("id", e_int 2); + ("new_owner", e_address new_addr)] in + let%bind () = expect_string_failwith ~options program "update_owner" + (e_pair param storage) + "This ID does not exist." + in ok () + +(* Test that contract fails when we attempt to update owner from non-owner addr *) +let update_owner_wrong_addr () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.zero) + () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let param = e_record_ez [("id", e_int 0); + ("new_owner", e_address new_addr)] in + let%bind () = expect_string_failwith ~options program "update_owner" + (e_pair param storage) + "You are not the owner of this ID." + in ok () + +let skip () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.one) () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let new_storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 3) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let%bind () = expect_eq ~options program "skip" + (e_pair (e_unit ()) storage) + (e_pair (e_list []) new_storage) + in ok () + +(* Test that contract fails if we try to skip without paying the right amount *) +let skip_wrong_amount () = + let%bind program = get_program () in + let owner_addr = addr 5 in + let owner_website = e_bytes_string "ligolang.org" in + let id_details_1 = e_record_ez [("owner", e_address owner_addr) ; + ("controller", e_address owner_addr) ; + ("profile", owner_website)] + in + let new_addr = first_owner in + let options = Proto_alpha_utils.Memory_proto_alpha.make_options + ~sender:first_contract + ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.fifty_cents) () + in + let new_website = e_bytes_string "ligolang.org" in + let id_details_2 = e_record_ez [("owner", e_address new_addr) ; + ("controller", e_address new_addr) ; + ("profile", new_website)] + in + let storage = e_record_ez [("identities", (e_big_map + [(e_int 0, id_details_1) ; + (e_int 1, id_details_2)])) ; + ("next_id", e_int 2) ; + ("name_price", e_mutez 1000000) ; + ("skip_price", e_mutez 1000000) ; ] + in + let%bind () = expect_string_failwith ~options program "skip" + (e_pair (e_unit ()) storage) + "Incorrect amount paid." + in ok () + +let main = test_suite "ID Layer (ReasonLIGO)" [ + test "buy" buy_id ; + test "buy (sender addr)" buy_id_sender_addr ; + test "buy (wrong amount)" buy_id_wrong_amount ; + test "update_details (owner)" update_details_owner ; + test "update_details (controller)" update_details_controller ; + test "update_details_nonexistent" update_details_nonexistent ; + test "update_details_wrong_addr" update_details_wrong_addr ; + test "update_details_unchanged" update_details_unchanged ; + test "update_owner" update_owner ; + test "update_owner_nonexistent" update_owner_nonexistent ; + test "update_owner_wrong_addr" update_owner_wrong_addr ; + test "skip" skip ; + test "skip (wrong amount)" skip_wrong_amount ; +] diff --git a/src/test/integration_tests.ml b/src/test/integration_tests.ml index 4ee2e841c..209e030d9 100644 --- a/src/test/integration_tests.ml +++ b/src/test/integration_tests.ml @@ -4,17 +4,11 @@ open Test_helpers open Ast_imperative.Combinators let retype_file f = - let%bind typed,state = Ligo.Compile.Utils.type_file f "reasonligo" Env in - let () = Typer.Solver.discard_state state in - ok typed + Ligo.Compile.Utils.type_file f "reasonligo" Env let mtype_file f = - let%bind typed,state = Ligo.Compile.Utils.type_file f "cameligo" Env in - let () = Typer.Solver.discard_state state in - ok typed + Ligo.Compile.Utils.type_file f "cameligo" Env let type_file f = - let%bind typed,state = Ligo.Compile.Utils.type_file f "pascaligo" Env in - let () = Typer.Solver.discard_state state in - ok typed + Ligo.Compile.Utils.type_file f "pascaligo" Env let type_alias () : unit result = let%bind program = type_file "./contracts/type-alias.ligo" in diff --git a/src/test/multisig_tests.ml b/src/test/multisig_tests.ml index b618dadd9..df3a42887 100644 --- a/src/test/multisig_tests.ml +++ b/src/test/multisig_tests.ml @@ -76,39 +76,39 @@ let params counter msg keys is_validl f s = (* Provide one valid signature when the threshold is two of two keys *) let not_enough_1_of_2 f s () = - let%bind program,_ = get_program f s () in + let%bind (program , state) = get_program f s () in let exp_failwith = "Not enough signatures passed the check" in let keys = gen_keys () in let%bind test_params = params 0 empty_message [keys] [true] f s in let%bind () = expect_string_failwith - program "main" (e_pair test_params (init_storage 2 0 [keys;gen_keys()])) exp_failwith in + (program, state) "main" (e_pair test_params (init_storage 2 0 [keys;gen_keys()])) exp_failwith in ok () let unmatching_counter f s () = - let%bind program,_ = get_program f s () in + let%bind (program , state) = get_program f s () in let exp_failwith = "Counters does not match" in let keys = gen_keys () in let%bind test_params = params 1 empty_message [keys] [true] f s in let%bind () = expect_string_failwith - program "main" (e_pair test_params (init_storage 1 0 [keys])) exp_failwith in + (program, state) "main" (e_pair test_params (init_storage 1 0 [keys])) exp_failwith in ok () (* Provide one invalid signature (correct key but incorrect signature) when the threshold is one of one key *) let invalid_1_of_1 f s () = - let%bind program,_ = get_program f s () in + let%bind (program , state) = get_program f s () in let exp_failwith = "Invalid signature" in let keys = [gen_keys ()] in let%bind test_params = params 0 empty_message keys [false] f s in let%bind () = expect_string_failwith - program "main" (e_pair test_params (init_storage 1 0 keys)) exp_failwith in + (program, state) "main" (e_pair test_params (init_storage 1 0 keys)) exp_failwith in ok () (* Provide one valid signature when the threshold is one of one key *) let valid_1_of_1 f s () = - let%bind program,_ = get_program f s () in + let%bind (program , state) = get_program f s () in let keys = gen_keys () in - let%bind () = expect_eq_n_trace_aux [0;1;2] program "main" + let%bind () = expect_eq_n_trace_aux [0;1;2] (program, state) "main" (fun n -> let%bind params = params n empty_message [keys] [true] f s in ok @@ e_pair params (init_storage 1 n [keys]) @@ -120,10 +120,10 @@ let valid_1_of_1 f s () = (* Provive two valid signatures when the threshold is two of three keys *) let valid_2_of_3 f s () = - let%bind program,_ = get_program f s () in + let%bind (program , state) = get_program f s () in let param_keys = [gen_keys (); gen_keys ()] in let st_keys = param_keys @ [gen_keys ()] in - let%bind () = expect_eq_n_trace_aux [0;1;2] program "main" + let%bind () = expect_eq_n_trace_aux [0;1;2] (program, state) "main" (fun n -> let%bind params = params n empty_message param_keys [true;true] f s in ok @@ e_pair params (init_storage 2 n st_keys) @@ -135,7 +135,7 @@ let valid_2_of_3 f s () = (* Provide one invalid signature and two valid signatures when the threshold is two of three keys *) let invalid_3_of_3 f s () = - let%bind program,_ = get_program f s () in + let%bind (program , state) = get_program f s () in let valid_keys = [gen_keys() ; gen_keys()] in let invalid_key = gen_keys () in let param_keys = valid_keys @ [invalid_key] in @@ -143,18 +143,18 @@ let invalid_3_of_3 f s () = let%bind test_params = params 0 empty_message param_keys [false;true;true] f s in let exp_failwith = "Invalid signature" in let%bind () = expect_string_failwith - program "main" (e_pair test_params (init_storage 2 0 st_keys)) exp_failwith in + (program, state) "main" (e_pair test_params (init_storage 2 0 st_keys)) exp_failwith in ok () (* Provide two valid signatures when the threshold is three of three keys *) let not_enough_2_of_3 f s () = - let%bind program,_ = get_program f s() in + let%bind (program , state) = get_program f s() in let valid_keys = [gen_keys() ; gen_keys()] in let st_keys = gen_keys () :: valid_keys in let%bind test_params = params 0 empty_message (valid_keys) [true;true] f s in let exp_failwith = "Not enough signatures passed the check" in let%bind () = expect_string_failwith - program "main" (e_pair test_params (init_storage 3 0 st_keys)) exp_failwith in + (program, state) "main" (e_pair test_params (init_storage 3 0 st_keys)) exp_failwith in ok () let main = test_suite "Multisig" [ diff --git a/src/test/multisig_v2_tests.ml b/src/test/multisig_v2_tests.ml index bf163195c..6c230881e 100644 --- a/src/test/multisig_v2_tests.ml +++ b/src/test/multisig_v2_tests.ml @@ -65,7 +65,7 @@ let storage {state_hash ; threshold ; max_proposal ; max_msg_size ; id_counter_l (* sender not stored in the authorized set *) let wrong_addr () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let init_storage = storage { threshold = 1 ; max_proposal = 1 ; max_msg_size = 1 ; state_hash = Bytes.empty ; id_counter_list = [1,0 ; 2,0] ; @@ -75,13 +75,13 @@ let wrong_addr () = let options = Proto_alpha_utils.Memory_proto_alpha.make_options ~sender () in let%bind () = let exp_failwith = "Unauthorized address" in - expect_string_failwith ~options program "main" + expect_string_failwith ~options (program, state) "main" (e_pair (send_param empty_message) init_storage) exp_failwith in ok () (* send a message which exceed the size limit *) let message_size_exceeded () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let init_storage = storage { threshold = 1 ; max_proposal = 1 ; max_msg_size = 1 ; state_hash = Bytes.empty ; id_counter_list = [1,0] ; @@ -91,13 +91,13 @@ let message_size_exceeded () = let options = Proto_alpha_utils.Memory_proto_alpha.make_options ~sender () in let%bind () = let exp_failwith = "Message size exceed maximum limit" in - expect_string_failwith ~options program "main" + expect_string_failwith ~options (program, state) "main" (e_pair (send_param empty_message) init_storage) exp_failwith in ok () (* sender has already has reached maximum number of proposal *) let maximum_number_of_proposal () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let%bind packed_payload1 = pack_payload program (send_param empty_message) in let bytes1 = e_bytes_raw packed_payload1 in let init_storage = storage { @@ -109,13 +109,13 @@ let maximum_number_of_proposal () = let options = Proto_alpha_utils.Memory_proto_alpha.make_options ~sender () in let%bind () = let exp_failwith = "Maximum number of proposal reached" in - expect_string_failwith ~options program "main" + expect_string_failwith ~options (program, state) "main" (e_pair (send_param empty_message2) init_storage) exp_failwith in ok () (* sender message is already stored in the message store *) let send_already_accounted () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let%bind packed_payload = pack_payload program empty_message in let bytes = e_bytes_raw packed_payload in let init_storage = storage { @@ -126,12 +126,12 @@ let send_already_accounted () = let options = let sender = contract 1 in Proto_alpha_utils.Memory_proto_alpha.make_options ~sender () in - expect_eq ~options program "main" + expect_eq ~options (program, state) "main" (e_pair (send_param empty_message) init_storage) (e_pair empty_op_list init_storage) (* sender message isn't stored in the message store *) let send_never_accounted () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let%bind packed_payload = pack_payload program empty_message in let bytes = e_bytes_raw packed_payload in let init_storage' = { @@ -147,12 +147,12 @@ let send_never_accounted () = let options = let sender = contract 1 in Proto_alpha_utils.Memory_proto_alpha.make_options ~sender () in - expect_eq ~options program "main" + expect_eq ~options (program, state) "main" (e_pair (send_param empty_message) init_storage) (e_pair empty_op_list final_storage) (* sender withdraw message is already binded to one address in the message store *) let withdraw_already_accounted_one () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let%bind packed_payload = pack_payload program empty_message in let bytes = e_bytes_raw packed_payload in let param = withdraw_param in @@ -168,12 +168,12 @@ let withdraw_already_accounted_one () = let options = let sender = contract 1 in Proto_alpha_utils.Memory_proto_alpha.make_options ~sender () in - expect_eq ~options program "main" + expect_eq ~options (program, state) "main" (e_pair param init_storage) (e_pair empty_op_list final_storage) (* sender withdraw message is already binded to two addresses in the message store *) let withdraw_already_accounted_two () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let%bind packed_payload = pack_payload program empty_message in let bytes = e_bytes_raw packed_payload in let param = withdraw_param in @@ -189,12 +189,12 @@ let withdraw_already_accounted_two () = let options = let sender = contract 1 in Proto_alpha_utils.Memory_proto_alpha.make_options ~sender () in - expect_eq ~options program "main" + expect_eq ~options (program, state) "main" (e_pair param init_storage) (e_pair empty_op_list final_storage) (* triggers the threshold and check that all the participants get their counters decremented *) let counters_reset () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let%bind packed_payload = pack_payload program empty_message in let bytes = e_bytes_raw packed_payload in let param = send_param empty_message in @@ -212,12 +212,12 @@ let counters_reset () = let options = let sender = contract 3 in Proto_alpha_utils.Memory_proto_alpha.make_options ~sender () in - expect_eq ~options program "main" + expect_eq ~options (program, state) "main" (e_pair param init_storage) (e_pair empty_op_list final_storage) (* sender withdraw message was never accounted *) let withdraw_never_accounted () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let param = withdraw_param in let init_storage = storage { threshold = 2 ; max_proposal = 1 ; max_msg_size = 1 ; state_hash = Bytes.empty ; @@ -227,12 +227,12 @@ let withdraw_never_accounted () = let options = let sender = contract 1 in Proto_alpha_utils.Memory_proto_alpha.make_options ~sender () in - expect_eq ~options program "main" + expect_eq ~options (program, state) "main" (e_pair param init_storage) (e_pair empty_op_list init_storage) (* successful storing in the message store *) let succeeded_storing () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let%bind packed_payload = pack_payload program empty_message in let bytes = e_bytes_raw packed_payload in let init_storage th = { @@ -243,7 +243,7 @@ let succeeded_storing () = let options = let sender = contract 1 in Proto_alpha_utils.Memory_proto_alpha.make_options ~sender () in - let%bind () = expect_eq_n_trace_aux ~options [1;2] program "main" + let%bind () = expect_eq_n_trace_aux ~options [1;2] (program, state) "main" (fun th -> let init_storage = storage (init_storage th) in ok @@ e_pair (send_param empty_message) init_storage diff --git a/src/test/pledge_tests.ml b/src/test/pledge_tests.ml index a10b17295..6f6b371ea 100644 --- a/src/test/pledge_tests.ml +++ b/src/test/pledge_tests.ml @@ -45,36 +45,36 @@ let empty_message = e_lambda (Var.of_name "arguments") let pledge () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let storage = e_address oracle_addr in let parameter = e_unit () in let options = Proto_alpha_utils.Memory_proto_alpha.make_options ~sender:oracle_contract ~amount:(Memory_proto_alpha.Protocol.Alpha_context.Tez.one) () in - expect_eq ~options program "donate" + expect_eq ~options (program, state) "donate" (e_pair parameter storage) (e_pair (e_list []) storage) let distribute () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let storage = e_address oracle_addr in let parameter = empty_message in let options = Proto_alpha_utils.Memory_proto_alpha.make_options ~sender:oracle_contract () in - expect_eq ~options program "distribute" + expect_eq ~options (program, state) "distribute" (e_pair parameter storage) (e_pair (e_list []) storage) let distribute_unauthorized () = - let%bind program, _ = get_program () in + let%bind (program , state) = get_program () in let storage = e_address oracle_addr in let parameter = empty_message in let options = Proto_alpha_utils.Memory_proto_alpha.make_options ~sender:stranger_contract () in - expect_string_failwith ~options program "distribute" + expect_string_failwith ~options (program, state) "distribute" (e_pair parameter storage) "You're not the oracle for this distribution." diff --git a/src/test/replaceable_id_tests.ml b/src/test/replaceable_id_tests.ml index 6de612bab..771b439a7 100644 --- a/src/test/replaceable_id_tests.ml +++ b/src/test/replaceable_id_tests.ml @@ -39,45 +39,45 @@ let entry_pass_message = e_constructor "Pass_message" @@ empty_message let change_addr_success () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let init_storage = storage 1 in let param = entry_change_addr 2 in let options = let sender = contract 1 in Proto_alpha_utils.Memory_proto_alpha.make_options ~sender () in - expect_eq ~options program "main" + expect_eq ~options (program, state) "main" (e_pair param init_storage) (e_pair empty_op_list (storage 2)) let change_addr_fail () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let init_storage = storage 1 in let param = entry_change_addr 2 in let options = let sender = contract 3 in Proto_alpha_utils.Memory_proto_alpha.make_options ~sender () in let exp_failwith = "Unauthorized sender" in - expect_string_failwith ~options program "main" + expect_string_failwith ~options (program, state) "main" (e_pair param init_storage) exp_failwith let pass_message_success () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let init_storage = storage 1 in let param = entry_pass_message in let options = let sender = contract 1 in Proto_alpha_utils.Memory_proto_alpha.make_options ~sender () in - expect_eq ~options program "main" + expect_eq ~options (program, state) "main" (e_pair param init_storage) (e_pair empty_op_list init_storage) let pass_message_fail () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let init_storage = storage 1 in let param = entry_pass_message in let options = let sender = contract 2 in Proto_alpha_utils.Memory_proto_alpha.make_options ~sender () in let exp_failwith = "Unauthorized sender" in - expect_string_failwith ~options program "main" + expect_string_failwith ~options (program, state) "main" (e_pair param init_storage) exp_failwith let main = test_suite "Replaceable ID" [ diff --git a/src/test/test.ml b/src/test/test.ml index 01d8a78f6..b6a9a9c41 100644 --- a/src/test/test.ml +++ b/src/test/test.ml @@ -11,6 +11,8 @@ let () = Coase_tests.main ; Vote_tests.main ; Id_tests.main ; + Id_tests_p.main ; + Id_tests_r.main ; Multisig_tests.main ; Multisig_v2_tests.main ; Replaceable_id_tests.main ; diff --git a/src/test/test_helpers.ml b/src/test/test_helpers.ml index ded88c33b..cc1e25afb 100644 --- a/src/test/test_helpers.ml +++ b/src/test/test_helpers.ml @@ -38,7 +38,7 @@ open Ast_imperative let pack_payload (program:Ast_typed.program) (payload:expression) : bytes result = let%bind code = - let env = Ast_typed.program_environment program in + let env = Ast_typed.program_environment Environment.default program in let%bind sugar = Compile.Of_imperative.compile_expression payload in let%bind core = Compile.Of_sugar.compile_expression sugar in @@ -86,11 +86,10 @@ let sha_256_hash pl = open Ast_imperative.Combinators let typed_program_with_imperative_input_to_michelson - (program: Ast_typed.program) (entry_point: string) + ((program , state): Ast_typed.program * Ast_typed.typer_state) (entry_point: string) (input: Ast_imperative.expression) : Compiler.compiled_expression result = Printexc.record_backtrace true; - let env = Ast_typed.program_environment program in - let state = Typer.Solver.initial_state in + let env = Ast_typed.program_environment Environment.default program in let%bind sugar = Compile.Of_imperative.compile_expression input in let%bind core = Compile.Of_sugar.compile_expression sugar in let%bind app = Compile.Of_core.apply entry_point core in @@ -100,9 +99,9 @@ let typed_program_with_imperative_input_to_michelson Compile.Of_mini_c.aggregate_and_compile_expression mini_c_prg compiled_applied let run_typed_program_with_imperative_input ?options - (program: Ast_typed.program) (entry_point: string) + ((program , state): Ast_typed.program * Ast_typed.typer_state) (entry_point: string) (input: Ast_imperative.expression) : Ast_core.expression result = - let%bind michelson_program = typed_program_with_imperative_input_to_michelson program entry_point input in + let%bind michelson_program = typed_program_with_imperative_input_to_michelson (program , state) entry_point input in let%bind michelson_output = Ligo.Run.Of_michelson.run_no_failwith ?options michelson_program.expr michelson_program.expr_ty in Uncompile.uncompile_typed_program_entry_function_result program entry_point michelson_output @@ -160,7 +159,7 @@ let expect_eq_core ?options program entry_point input expected = Ast_core.Misc.assert_value_eq (expected,result) in expect ?options program entry_point input expecter -let expect_evaluate program entry_point expecter = +let expect_evaluate (program, _state) entry_point expecter = let error = let title () = "expect evaluate" in let content () = Format.asprintf "Entry_point: %s" entry_point in @@ -173,11 +172,11 @@ let expect_evaluate program entry_point expecter = let%bind res_simpl = Uncompile.uncompile_typed_program_entry_expression_result program entry_point res_michelson in expecter res_simpl -let expect_eq_evaluate program entry_point expected = +let expect_eq_evaluate ((program , state) : Ast_typed.program * Ast_typed.typer_state) entry_point expected = let%bind expected = expression_to_core expected in let expecter = fun result -> Ast_core.Misc.assert_value_eq (expected , result) in - expect_evaluate program entry_point expecter + expect_evaluate (program, state) entry_point expecter let expect_n_aux ?options lst program entry_point make_input make_expecter = let aux n = diff --git a/src/test/time_lock_repeat_tests.ml b/src/test/time_lock_repeat_tests.ml index adfe66169..efadf31a2 100644 --- a/src/test/time_lock_repeat_tests.ml +++ b/src/test/time_lock_repeat_tests.ml @@ -43,21 +43,21 @@ let storage st interval execute = ("execute", execute)] let early_call () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let%bind predecessor_timestamp = mk_time "2000-01-01T00:10:10Z" in let%bind lock_time = mk_time "2000-01-01T10:10:10Z" in let init_storage = storage lock_time 86400 empty_message in let options = Proto_alpha_utils.Memory_proto_alpha.make_options ~predecessor_timestamp () in let exp_failwith = "You have to wait before you can execute this contract again." in - expect_string_failwith ~options program "main" + expect_string_failwith ~options (program, state) "main" (e_pair (e_unit ()) init_storage) exp_failwith let fake_uncompiled_empty_message = e_string "[lambda of type: (lambda unit (list operation)) ]" (* Test that when we use the contract the next use time advances by correct interval *) let interval_advance () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let%bind predecessor_timestamp = mk_time "2000-01-01T10:10:10Z" in let%bind lock_time = mk_time "2000-01-01T00:10:10Z" in let init_storage = storage lock_time 86400 empty_message in @@ -66,7 +66,7 @@ let interval_advance () = let new_storage_fake = storage new_timestamp 86400 fake_uncompiled_empty_message in let options = Proto_alpha_utils.Memory_proto_alpha.make_options ~predecessor_timestamp () in - expect_eq ~options program "main" + expect_eq ~options (program, state) "main" (e_pair (e_unit ()) init_storage) (e_pair empty_op_list new_storage_fake) let main = test_suite "Time Lock Repeating" [ diff --git a/src/test/time_lock_tests.ml b/src/test/time_lock_tests.ml index f345401c9..ee99d1542 100644 --- a/src/test/time_lock_tests.ml +++ b/src/test/time_lock_tests.ml @@ -41,24 +41,24 @@ let to_sec t = Tezos_utils.Time.Protocol.to_seconds t let storage st = e_timestamp (Int64.to_int @@ to_sec st) let early_call () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let%bind predecessor_timestamp = mk_time "2000-01-01T00:10:10Z" in let%bind lock_time = mk_time "2000-01-01T10:10:10Z" in let init_storage = storage lock_time in let options = Proto_alpha_utils.Memory_proto_alpha.make_options ~predecessor_timestamp () in let exp_failwith = "Contract is still time locked" in - expect_string_failwith ~options program "main" + expect_string_failwith ~options (program, state) "main" (e_pair (call empty_message) init_storage) exp_failwith let call_on_time () = - let%bind program,_ = get_program () in + let%bind (program , state) = get_program () in let%bind predecessor_timestamp = mk_time "2000-01-01T10:10:10Z" in let%bind lock_time = mk_time "2000-01-01T00:10:10Z" in let init_storage = storage lock_time in let options = Proto_alpha_utils.Memory_proto_alpha.make_options ~predecessor_timestamp () in - expect_eq ~options program "main" + expect_eq ~options (program, state) "main" (e_pair (call empty_message) init_storage) (e_pair empty_op_list init_storage) let main = test_suite "Time lock" [ diff --git a/src/test/typer_tests.ml b/src/test/typer_tests.ml index e4ea12df5..c26e690ba 100644 --- a/src/test/typer_tests.ml +++ b/src/test/typer_tests.ml @@ -34,7 +34,7 @@ module TestExpressions = struct module I = Simplified.Combinators module O = Typed.Combinators - module E = O + module E = Typed.Environment let unit () : unit result = test_expression I.(e_unit ()) O.(t_unit ()) let int () : unit result = test_expression I.(e_int (Z.of_int 32)) O.(t_int ()) @@ -59,7 +59,7 @@ module TestExpressions = struct (Typed.Constructor "foo", {ctor_type = Typed.t_int () ; michelson_annotation = None ; ctor_decl_pos = 0}); (Typed.Constructor "bar", {ctor_type = Typed.t_string () ; michelson_annotation = None ; ctor_decl_pos = 1}) ] in test_expression - ~env:(E.env_sum_type variant_foo_bar) + ~env:(E.add_ez_sum_type variant_foo_bar) I.(e_constructor "foo" (e_int (Z.of_int 32))) O.(make_t_ez_sum variant_foo_bar) diff --git a/src/test/tzip12_tests.ml b/src/test/tzip12_tests.ml index db5996c9e..af81b9672 100644 --- a/src/test/tzip12_tests.ml +++ b/src/test/tzip12_tests.ml @@ -49,7 +49,7 @@ let sender = e_address @@ sender let external_contract = e_annotation (e_constant C_IMPLICIT_ACCOUNT [e_key_hash external_contract]) (t_contract (t_nat ())) let transfer f s () = - let%bind program,_ = get_program f s () in + let%bind (program , state) = get_program f s () in let storage = e_record_ez [ ("tokens", e_big_map [(sender, e_nat 100); (from_, e_nat 100); (to_, e_nat 100)]); ("allowances", e_big_map [(e_pair sender from_, e_nat 100)]); @@ -64,10 +64,10 @@ let transfer f s () = let input = e_pair parameter storage in let expected = e_pair (e_typed_list [] (t_operation ())) new_storage in let options = Proto_alpha_utils.Memory_proto_alpha.make_options () in - expect_eq program ~options "transfer" input expected + expect_eq (program, state) ~options "transfer" input expected let transfer_not_e_allowance f s () = - let%bind program,_ = get_program f s () in + let%bind (program , state) = get_program f s () in let storage = e_record_ez [ ("tokens", e_big_map [(sender, e_nat 100); (from_, e_nat 100); (to_, e_nat 100)]); ("allowances", e_big_map [(e_pair sender from_, e_nat 0)]); @@ -76,11 +76,11 @@ let transfer_not_e_allowance f s () = let parameter = e_record_ez [("address_from", from_);("address_to",to_); ("value",e_nat 10)] in let input = e_pair parameter storage in let options = Proto_alpha_utils.Memory_proto_alpha.make_options () in - expect_string_failwith ~options program "transfer" input + expect_string_failwith ~options (program, state) "transfer" input "Not Enough Allowance" let transfer_not_e_balance f s () = - let%bind program,_ = get_program f s () in + let%bind (program , state) = get_program f s () in let storage = e_record_ez [ ("tokens", e_big_map [(sender, e_nat 100); (from_, e_nat 0); (to_, e_nat 100)]); ("allowances", e_big_map [(e_pair sender from_, e_nat 100)]); @@ -89,11 +89,11 @@ let transfer_not_e_balance f s () = let parameter = e_record_ez [("address_from", from_);("address_to",to_); ("value",e_nat 10)] in let input = e_pair parameter storage in let options = Proto_alpha_utils.Memory_proto_alpha.make_options () in - expect_string_failwith ~options program "transfer" input + expect_string_failwith ~options (program, state) "transfer" input "Not Enough Balance" let approve f s () = - let%bind program,_ = get_program f s () in + let%bind (program , state) = get_program f s () in let storage = e_record_ez [ ("tokens", e_big_map [(sender, e_nat 100); (from_, e_nat 100); (to_, e_nat 100)]); ("allowances", e_big_map [(e_pair from_ sender, e_nat 0)]); @@ -108,10 +108,10 @@ let approve f s () = let input = e_pair parameter storage in let expected = e_pair (e_typed_list [] (t_operation ())) new_storage in let options = Proto_alpha_utils.Memory_proto_alpha.make_options () in - expect_eq program ~options "approve" input expected + expect_eq (program, state) ~options "approve" input expected let approve_unsafe f s () = - let%bind program,_ = get_program f s () in + let%bind (program , state) = get_program f s () in let storage = e_record_ez [ ("tokens", e_big_map [(sender, e_nat 100); (from_, e_nat 100); (to_, e_nat 100)]); ("allowances", e_big_map [(e_pair from_ sender, e_nat 100)]); @@ -120,11 +120,11 @@ let approve_unsafe f s () = let parameter = e_record_ez [("spender", from_);("value",e_nat 100)] in let input = e_pair parameter storage in let options = Proto_alpha_utils.Memory_proto_alpha.make_options () in - expect_string_failwith ~options program "approve" input + expect_string_failwith ~options (program, state) "approve" input "Unsafe Allowance Change" let get_allowance f s () = - let%bind program,_ = get_program f s () in + let%bind (program , state) = get_program f s () in let storage = e_record_ez [ ("tokens", e_big_map [(sender, e_nat 100); (from_, e_nat 100); (to_, e_nat 100)]); ("allowances", e_big_map [(e_pair from_ sender, e_nat 100)]); @@ -134,10 +134,10 @@ let get_allowance f s () = let input = e_pair parameter storage in let expected = e_pair (e_typed_list [] (t_operation ())) storage in let options = Proto_alpha_utils.Memory_proto_alpha.make_options () in - expect_eq program ~options "getAllowance" input expected + expect_eq (program, state) ~options "getAllowance" input expected let get_balance f s () = - let%bind program,_ = get_program f s () in + let%bind (program , state) = get_program f s () in let storage = e_record_ez [ ("tokens", e_big_map [(sender, e_nat 100); (from_, e_nat 100); (to_, e_nat 100)]); ("allowances", e_big_map [(e_pair from_ sender, e_nat 100)]); @@ -147,10 +147,10 @@ let get_balance f s () = let input = e_pair parameter storage in let expected = e_pair (e_typed_list [] (t_operation ())) storage in let options = Proto_alpha_utils.Memory_proto_alpha.make_options () in - expect_eq program ~options "getBalance" input expected + expect_eq (program, state) ~options "getBalance" input expected let get_total_supply f s () = - let%bind program,_ = get_program f s () in + let%bind (program , state) = get_program f s () in let storage = e_record_ez [ ("tokens", e_big_map [(sender, e_nat 100); (from_, e_nat 100); (to_, e_nat 100)]); ("allowances", e_big_map [(e_pair from_ sender, e_nat 100)]); @@ -160,7 +160,7 @@ let get_total_supply f s () = let input = e_pair parameter storage in let expected = e_pair (e_typed_list [] (t_operation ())) storage in let options = Proto_alpha_utils.Memory_proto_alpha.make_options () in - expect_eq program ~options "getTotalSupply" input expected + expect_eq (program, state) ~options "getTotalSupply" input expected let main = test_suite "tzip-12" [ test "transfer" (transfer file_FA12 "pascaligo"); diff --git a/src/test/vote_tests.ml b/src/test/vote_tests.ml index 24cce7663..89f829a86 100644 --- a/src/test/vote_tests.ml +++ b/src/test/vote_tests.ml @@ -2,8 +2,7 @@ open Trace open Test_helpers let type_file f = - let%bind typed,state = Ligo.Compile.Utils.type_file f "cameligo" (Contract "main") in - ok @@ (typed,state) + Ligo.Compile.Utils.type_file f "cameligo" (Contract "main") let get_program = let s = ref None in @@ -36,10 +35,10 @@ let reset title start_time finish_time = let yea = e_constructor "Vote" (e_constructor "Yea" (e_unit ())) let init_vote () = - let%bind (program , _) = get_program () in + let%bind (program , state) = get_program () in let%bind result = Test_helpers.run_typed_program_with_imperative_input - program "main" (e_pair yea (init_storage "basic")) in + (program, state) "main" (e_pair yea (init_storage "basic")) in let%bind (_, storage) = Ast_core.extract_pair result in let%bind storage' = Ast_core.extract_record storage in (* let votes = List.assoc (Label "voters") storage' in diff --git a/tools/webide/packages/client/package-examples.js b/tools/webide/packages/client/package-examples.js index b6e2be960..2d7b7dbf4 100644 --- a/tools/webide/packages/client/package-examples.js +++ b/tools/webide/packages/client/package-examples.js @@ -4,12 +4,6 @@ const join = require('path').join; const fs = require('fs'); const YAML = require('yamljs'); -const CURATED_EXAMPLES = [ - 'cameligo/arithmetic-contract.ligo', - 'pascaligo/arithmetic-contract.ligo', - 'reasonligo/arithmetic-contract.ligo' -]; - function urlFriendlyHash(content) { const hash = createHash('md5'); hash.update(content); @@ -109,6 +103,15 @@ async function main() { // const EXAMPLES_GLOB = '**/*.ligo'; // const files = await findFiles(EXAMPLES_GLOB, EXAMPLES_DIR); + const CURATED_EXAMPLES = [ + 'pascaligo/arithmetic-contract.ligo', + 'cameligo/arithmetic-contract.ligo', + 'reasonligo/arithmetic-contract.ligo', + 'pascaligo/id.ligo', + 'cameligo/id.mligo', + 'reasonligo/id.religo', + ]; + const EXAMPLES_DEST_DIR = join(process.cwd(), 'build', 'static', 'examples'); fs.mkdirSync(EXAMPLES_DEST_DIR, { recursive: true }); diff --git a/tools/webide/packages/client/package-lock.json b/tools/webide/packages/client/package-lock.json index 62b1a6159..3d668120e 100644 --- a/tools/webide/packages/client/package-lock.json +++ b/tools/webide/packages/client/package-lock.json @@ -16168,6 +16168,11 @@ } } }, + "slugify": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/slugify/-/slugify-1.4.0.tgz", + "integrity": "sha512-FtLNsMGBSRB/0JOE2A0fxlqjI6fJsgHGS13iTuVT28kViI4JjUiNqp/vyis0ZXYcMnpR3fzGNkv+6vRlI2GwdQ==" + }, "snapdragon": { "version": "0.8.2", "resolved": "https://registry.npmjs.org/snapdragon/-/snapdragon-0.8.2.tgz", diff --git a/tools/webide/packages/client/src/components/configure/configure-tab.tsx b/tools/webide/packages/client/src/components/configure/configure-tab.tsx index 0023f3ffc..620e72356 100644 --- a/tools/webide/packages/client/src/components/configure/configure-tab.tsx +++ b/tools/webide/packages/client/src/components/configure/configure-tab.tsx @@ -7,7 +7,7 @@ import { DeployAction } from '../../redux/actions/deploy'; import { DryRunAction } from '../../redux/actions/dry-run'; import { EvaluateFunctionAction } from '../../redux/actions/evaluate-function'; import { EvaluateValueAction } from '../../redux/actions/evaluate-value'; -import { GenerateCommandAction } from '../../redux/actions/generate-command'; +import { GenerateDeployScriptAction } from '../../redux/actions/generate-deploy-script'; import { AppState } from '../../redux/app'; import { ChangeDispatchedAction, ChangeSelectedAction, CommandState } from '../../redux/command'; import { Command } from '../../redux/types'; @@ -17,7 +17,7 @@ import { DeployPaneComponent } from './deploy-pane'; import { DryRunPaneComponent } from './dry-run-pane'; import { EvaluateFunctionPaneComponent } from './evaluate-function-pane'; import { EvaluateValuePaneComponent } from './evaluate-value-pane'; -import { GenerateCommandPaneComponent } from './generate-command-pane'; +import { GenerateDeployScriptPane } from './generate-deploy-script-pane'; const Container = styled.div<{ visible?: boolean }>` position: absolute; @@ -76,8 +76,8 @@ function createAction(command: Command) { return new EvaluateValueAction(); case Command.EvaluateFunction: return new EvaluateFunctionAction(); - case Command.GenerateCommand: - return new GenerateCommandAction(); + case Command.GenerateDeployScript: + return new GenerateDeployScriptAction(); default: throw new Error('Unsupported command'); } @@ -113,7 +113,7 @@ export const ConfigureTabComponent = (props: { - + )) || - (command === Command.GenerateCommand && ( - + (command === Command.GenerateDeployScript && ( + ))} ); diff --git a/tools/webide/packages/client/src/components/configure/generate-command-pane.tsx b/tools/webide/packages/client/src/components/configure/generate-deploy-script-pane.tsx similarity index 74% rename from tools/webide/packages/client/src/components/configure/generate-command-pane.tsx rename to tools/webide/packages/client/src/components/configure/generate-deploy-script-pane.tsx index da56264af..a59ad8226 100644 --- a/tools/webide/packages/client/src/components/configure/generate-command-pane.tsx +++ b/tools/webide/packages/client/src/components/configure/generate-deploy-script-pane.tsx @@ -8,8 +8,8 @@ import { ChangeEntrypointAction, ChangeStorageAction, ChangeToolAction, - GenerateCommandState, -} from '../../redux/generate-command'; + GenerateDeployScriptState, +} from '../../redux/generate-deploy-script'; import { Tool, ToolCommand } from '../../redux/types'; import { AccessFunctionLabel, Group, Input, Label, Textarea } from '../form/inputs'; import { Option, Select } from '../form/select'; @@ -18,23 +18,23 @@ const Container = styled.div` overflow: auto; `; -export const GenerateCommandPaneComponent = () => { +export const GenerateDeployScriptPane = () => { const dispatch = useDispatch(); - const tool = useSelector( - state => state.generateCommand.tool + const tool = useSelector( + state => state.generateDeployScript.tool ); - const command = useSelector( - state => state.generateCommand.command + const command = useSelector( + state => state.generateDeployScript.command ); - const entrypoint = useSelector( - state => state.generateCommand.entrypoint + const entrypoint = useSelector( + state => state.generateDeployScript.entrypoint ); - const storage = useSelector( - state => state.generateCommand.storage + const storage = useSelector( + state => state.generateDeployScript.storage ); return ( diff --git a/tools/webide/packages/client/src/components/output/generate-command-output-pane.tsx b/tools/webide/packages/client/src/components/output/generate-deploy-script-output-pane.tsx similarity index 95% rename from tools/webide/packages/client/src/components/output/generate-command-output-pane.tsx rename to tools/webide/packages/client/src/components/output/generate-deploy-script-output-pane.tsx index 5dd714375..487ed5cb9 100644 --- a/tools/webide/packages/client/src/components/output/generate-command-output-pane.tsx +++ b/tools/webide/packages/client/src/components/output/generate-deploy-script-output-pane.tsx @@ -24,7 +24,7 @@ const Pre = styled.pre` margin: 0; `; -export const GenerateCommandOutputPane = () => { +export const GenerateDeployScriptOutputPane = () => { const output = useSelector( state => state.result.output ); diff --git a/tools/webide/packages/client/src/components/output/output-tab.tsx b/tools/webide/packages/client/src/components/output/output-tab.tsx index 5989b9f0e..1c7122d9c 100644 --- a/tools/webide/packages/client/src/components/output/output-tab.tsx +++ b/tools/webide/packages/client/src/components/output/output-tab.tsx @@ -8,7 +8,7 @@ import { ResultState } from '../../redux/result'; import { Command } from '../../redux/types'; import { CompileOutputPane } from './compile-output-pane'; import { DeployOutputPane } from './deploy-output-pane'; -import { GenerateCommandOutputPane } from './generate-command-output-pane'; +import { GenerateDeployScriptOutputPane } from './generate-deploy-script-output-pane'; import { Loading } from './loading'; import { OutputPane } from './output-pane'; @@ -55,8 +55,8 @@ export const OutputTab = (props: { return ; } else if (command === Command.Deploy) { return ; - } else if (command === Command.GenerateCommand) { - return ; + } else if (command === Command.GenerateDeployScript) { + return ; } return ; diff --git a/tools/webide/packages/client/src/redux/actions/generate-command.ts b/tools/webide/packages/client/src/redux/actions/generate-deploy-script.ts similarity index 83% rename from tools/webide/packages/client/src/redux/actions/generate-command.ts rename to tools/webide/packages/client/src/redux/actions/generate-deploy-script.ts index f5e2847e4..24a464b13 100644 --- a/tools/webide/packages/client/src/redux/actions/generate-command.ts +++ b/tools/webide/packages/client/src/redux/actions/generate-deploy-script.ts @@ -22,25 +22,25 @@ export async function fetchRandomPrivateKey(): Promise { return response.text(); } -export class GenerateCommandAction extends CancellableAction { +export class GenerateDeployScriptAction extends CancellableAction { getAction() { return async (dispatch: Dispatch, getState: () => AppState) => { dispatch({ ...new UpdateLoadingAction('Compiling contract...') }); try { - const { editor, generateCommand } = getState(); + const { editor, generateDeployScript } = getState(); const michelsonCodeJson = await compileContract( editor.language, editor.code, - generateCommand.entrypoint, + generateDeployScript.entrypoint, MichelsonFormat.Json ); const michelsonCode = await compileContract( editor.language, editor.code, - generateCommand.entrypoint + generateDeployScript.entrypoint ); if (this.isCancelled()) { @@ -51,16 +51,16 @@ export class GenerateCommandAction extends CancellableAction { const michelsonStorageJson = await compileStorage( editor.language, editor.code, - generateCommand.entrypoint, - generateCommand.storage, + generateDeployScript.entrypoint, + generateDeployScript.storage, MichelsonFormat.Json ); const michelsonStorage = await compileStorage( editor.language, editor.code, - generateCommand.entrypoint, - generateCommand.storage + generateDeployScript.entrypoint, + generateDeployScript.storage ); if (this.isCancelled()) { @@ -82,7 +82,7 @@ export class GenerateCommandAction extends CancellableAction { const title = slugify(editor.title).toLowerCase() || 'untitled'; const output = `tezos-client \\ - ${generateCommand.command} \\ + ${generateDeployScript.command} \\ contract \\ ${title} \\ transferring 0 \\ @@ -92,7 +92,7 @@ export class GenerateCommandAction extends CancellableAction { --burn-cap ${estimate.burnFeeMutez / 1000000}`; dispatch({ - ...new ChangeOutputAction(output, Command.GenerateCommand) + ...new ChangeOutputAction(output, Command.GenerateDeployScript) }); } catch (ex) { if (this.isCancelled()) { @@ -101,7 +101,7 @@ export class GenerateCommandAction extends CancellableAction { dispatch({ ...new ChangeOutputAction( `Error: ${getErrorMessage(ex)}`, - Command.GenerateCommand + Command.GenerateDeployScript ) }); } diff --git a/tools/webide/packages/client/src/redux/app.ts b/tools/webide/packages/client/src/redux/app.ts index 33ec56a65..920072c19 100644 --- a/tools/webide/packages/client/src/redux/app.ts +++ b/tools/webide/packages/client/src/redux/app.ts @@ -8,7 +8,7 @@ import editor, { EditorState } from './editor'; import evaluateFunction, { EvaluateFunctionState } from './evaluate-function'; import evaluateValue, { EvaluateValueState } from './evaluate-value'; import examples, { ExamplesState } from './examples'; -import generateCommand, { GenerateCommandState } from './generate-command'; +import generateDeployScript, { GenerateDeployScriptState } from './generate-deploy-script'; import loading, { LoadingState } from './loading'; import result, { ResultState } from './result'; import share, { ShareState } from './share'; @@ -23,7 +23,7 @@ export interface AppState { deploy: DeployState; evaluateFunction: EvaluateFunctionState; evaluateValue: EvaluateValueState; - generateCommand: GenerateCommandState; + generateDeployScript: GenerateDeployScriptState; result: ResultState; command: CommandState; examples: ExamplesState; @@ -38,7 +38,7 @@ export default combineReducers({ deploy, evaluateFunction, evaluateValue, - generateCommand, + generateDeployScript, result, command, examples, diff --git a/tools/webide/packages/client/src/redux/example.ts b/tools/webide/packages/client/src/redux/example.ts index 12a799555..4a49d829b 100644 --- a/tools/webide/packages/client/src/redux/example.ts +++ b/tools/webide/packages/client/src/redux/example.ts @@ -4,6 +4,8 @@ import { DryRunState } from './dry-run'; import { EditorState } from './editor'; import { EvaluateFunctionState } from './evaluate-function'; import { EvaluateValueState } from './evaluate-value'; +import { GenerateDeployScriptState } from './generate-deploy-script'; + export interface ExampleState { id: string; @@ -14,4 +16,5 @@ export interface ExampleState { deploy: DeployState; evaluateFunction: EvaluateFunctionState; evaluateValue: EvaluateValueState; + generateDeployScript: GenerateDeployScriptState; } diff --git a/tools/webide/packages/client/src/redux/examples.ts b/tools/webide/packages/client/src/redux/examples.ts index 7e631cbc9..43ec23f1a 100644 --- a/tools/webide/packages/client/src/redux/examples.ts +++ b/tools/webide/packages/client/src/redux/examples.ts @@ -17,7 +17,7 @@ export interface ExamplesState { export class ChangeSelectedAction { public readonly type = ActionType.ChangeSelected; - constructor(public payload: ExamplesState['selected']) {} + constructor(public payload: ExamplesState['selected']) { } } export class ClearSelectedAction { @@ -33,9 +33,12 @@ export const DEFAULT_STATE: ExamplesState = { if (process.env.NODE_ENV === 'development') { DEFAULT_STATE.list = [ - { id: 'MzkMQ1oiVHJqbcfUuVFKTw', name: 'CameLIGO Contract' }, - { id: 'FEb62HL7onjg1424eUsGSg', name: 'PascaLIGO Contract' }, - { id: 'JPhSOehj_2MFwRIlml0ymQ', name: 'ReasonLIGO Contract' } + { id: 'MzkMQ1oiVHJqbcfUuVFKTw', name: 'Increment Example CameLIGO ' }, + { id: 'FEb62HL7onjg1424eUsGSg', name: 'Increment Example PascaLIGO' }, + { id: 'JPhSOehj_2MFwRIlml0ymQ', name: 'Increment Example ReasonLIGO' }, + { id: 'ehDv-Xaf70mQoiPhQDTAUQ', name: 'ID Example CameLIGO' }, + { id: 'CpnK7TFuUjJiQTT8KiiGyQ', name: 'ID Example ReasonLIGO' }, + { id: 'yP-THvmURsaqHxpwCravWg', name: 'ID Example PascaLIGO' }, ]; } diff --git a/tools/webide/packages/client/src/redux/generate-command.ts b/tools/webide/packages/client/src/redux/generate-deploy-script.ts similarity index 57% rename from tools/webide/packages/client/src/redux/generate-command.ts rename to tools/webide/packages/client/src/redux/generate-deploy-script.ts index dadd00163..0d4adcb14 100644 --- a/tools/webide/packages/client/src/redux/generate-command.ts +++ b/tools/webide/packages/client/src/redux/generate-deploy-script.ts @@ -1,13 +1,14 @@ +import { ActionType as ExamplesActionType, ChangeSelectedAction as ChangeSelectedExampleAction } from './examples'; import { Tool, ToolCommand } from './types'; export enum ActionType { - ChangeTool = 'generate-command-change-tool', - ChangeCommand = 'generate-command-change-command', - ChangeEntrypoint = 'generate-command-change-entrypoint', - ChangeStorage = 'generate-command-change-storage' + ChangeTool = 'generate-deploy-script-change-tool', + ChangeCommand = 'generate-deploy-script-change-command', + ChangeEntrypoint = 'generate-deploy-script-change-entrypoint', + ChangeStorage = 'generate-deploy-script-change-storage' } -export interface GenerateCommandState { +export interface GenerateDeployScriptState { tool: Tool; command: ToolCommand; entrypoint: string; @@ -18,31 +19,32 @@ export interface GenerateCommandState { export class ChangeToolAction { public readonly type = ActionType.ChangeTool; - constructor(public payload: GenerateCommandState['tool']) {} + constructor(public payload: GenerateDeployScriptState['tool']) {} } export class ChangeCommandAction { public readonly type = ActionType.ChangeCommand; - constructor(public payload: GenerateCommandState['command']) {} + constructor(public payload: GenerateDeployScriptState['command']) {} } export class ChangeEntrypointAction { public readonly type = ActionType.ChangeEntrypoint; - constructor(public payload: GenerateCommandState['entrypoint']) {} + constructor(public payload: GenerateDeployScriptState['entrypoint']) {} } export class ChangeStorageAction { public readonly type = ActionType.ChangeStorage; - constructor(public payload: GenerateCommandState['storage']) {} + constructor(public payload: GenerateDeployScriptState['storage']) {} } type Action = | ChangeToolAction | ChangeCommandAction | ChangeEntrypointAction - | ChangeStorageAction; + | ChangeStorageAction + | ChangeSelectedExampleAction; -const DEFAULT_STATE: GenerateCommandState = { +const DEFAULT_STATE: GenerateDeployScriptState = { tool: Tool.TezosClient, command: ToolCommand.Originate, entrypoint: '', @@ -54,8 +56,13 @@ const DEFAULT_STATE: GenerateCommandState = { export default ( state = DEFAULT_STATE, action: Action -): GenerateCommandState => { +): GenerateDeployScriptState => { switch (action.type) { + case ExamplesActionType.ChangeSelected: + return { + ...state, + ...(!action.payload ? DEFAULT_STATE : action.payload.generateDeployScript) + }; case ActionType.ChangeTool: return { ...state, diff --git a/tools/webide/packages/client/src/redux/types.ts b/tools/webide/packages/client/src/redux/types.ts index 3aab55c08..90700cb15 100644 --- a/tools/webide/packages/client/src/redux/types.ts +++ b/tools/webide/packages/client/src/redux/types.ts @@ -10,7 +10,7 @@ export enum Command { EvaluateValue = 'evaluate-value', EvaluateFunction = 'evaluate-function', Deploy = 'deploy', - GenerateCommand = 'generate-command' + GenerateDeployScript = 'generate-deploy-script' } export enum Tool { diff --git a/tools/webide/packages/e2e/test/share.spec.js b/tools/webide/packages/e2e/test/share.spec.js index dd73d64db..2cece1c97 100644 --- a/tools/webide/packages/e2e/test/share.spec.js +++ b/tools/webide/packages/e2e/test/share.spec.js @@ -24,7 +24,7 @@ describe('Share', () => { await responseCallback; const actualShareLink = await page.evaluate(getInputValue, 'share-link'); - const expectedShareLink = `${API_HOST}/p/WxKPBq9-mkZ_kq4cMHXfCQ`; + const expectedShareLink = `${API_HOST}/p/2GnQR0cUYeO7feAw71SJYQ` expect(actualShareLink).toEqual(expectedShareLink); done(); diff --git a/tools/webide/packages/server/package-lock.json b/tools/webide/packages/server/package-lock.json index 903ceb2c2..9baa353e1 100644 --- a/tools/webide/packages/server/package-lock.json +++ b/tools/webide/packages/server/package-lock.json @@ -3317,8 +3317,7 @@ "gensync": { "version": "1.0.0-beta.1", "resolved": "https://registry.npmjs.org/gensync/-/gensync-1.0.0-beta.1.tgz", - "integrity": "sha512-r8EC6NO1sngH/zdD9fiRDLdcgnbayXah+mLgManTaIZJqEC1MZstmnox8KpnI2/fxQwrp5OpCOYWLp4rBl4Jcg==", - "dev": true + "integrity": "sha512-r8EC6NO1sngH/zdD9fiRDLdcgnbayXah+mLgManTaIZJqEC1MZstmnox8KpnI2/fxQwrp5OpCOYWLp4rBl4Jcg==" }, "get-caller-file": { "version": "2.0.5", diff --git a/tools/webide/packages/server/package.json b/tools/webide/packages/server/package.json index 2e6f5ab38..621ed7d05 100644 --- a/tools/webide/packages/server/package.json +++ b/tools/webide/packages/server/package.json @@ -11,16 +11,16 @@ }, "devDependencies": { "@ts-tools/node": "^1.0.0", + "@types/cors": "^2.8.6", "@types/express": "^4.17.1", "@types/express-winston": "^3.0.4", "@types/hapi__joi": "^16.0.1", "@types/jest": "^24.0.23", "@types/joi": "^14.3.3", "@types/node": "10", + "@types/node-fetch": "^2.5.4", "@types/tmp": "^0.1.0", "@types/winston": "^2.4.4", - "@types/cors": "^2.8.6", - "@types/node-fetch": "^2.5.4", "jest": "^24.9.0", "nodemon": "^1.19.3", "ts-jest": "^24.1.0", @@ -40,6 +40,7 @@ "express": "^4.17.1", "express-prometheus-middleware": "^0.8.5", "express-winston": "^4.0.1", + "gensync": "^1.0.0-beta.1", "node-fetch": "^2.6.0", "sanitize-html": "^1.20.1", "tmp": "^0.1.0", diff --git a/tools/webide/packages/server/src/handlers/compile-contract.ts b/tools/webide/packages/server/src/handlers/compile-contract.ts index aaed33150..a33c445f4 100644 --- a/tools/webide/packages/server/src/handlers/compile-contract.ts +++ b/tools/webide/packages/server/src/handlers/compile-contract.ts @@ -11,7 +11,7 @@ interface CompileBody { format?: string; } -const validateRequest = (body: any): { value: CompileBody; error: any } => { +const validateRequest = (body: any): { value: CompileBody; error?: any } => { return joi .object({ syntax: joi.string().required(), diff --git a/tools/webide/packages/server/src/handlers/compile-expression.ts b/tools/webide/packages/server/src/handlers/compile-expression.ts index ece19eccc..5c179755d 100644 --- a/tools/webide/packages/server/src/handlers/compile-expression.ts +++ b/tools/webide/packages/server/src/handlers/compile-expression.ts @@ -10,7 +10,7 @@ interface CompileBody { format?: string; } -const validateRequest = (body: any): { value: CompileBody; error: any } => { +const validateRequest = (body: any): { value: CompileBody; error?: any } => { return joi .object({ syntax: joi.string().required(), diff --git a/tools/webide/packages/server/src/handlers/compile-storage.ts b/tools/webide/packages/server/src/handlers/compile-storage.ts index f0cc1a12b..7fa88c75d 100644 --- a/tools/webide/packages/server/src/handlers/compile-storage.ts +++ b/tools/webide/packages/server/src/handlers/compile-storage.ts @@ -12,7 +12,7 @@ interface CompileBody { format?: string; } -const validateRequest = (body: any): { value: CompileBody; error: any } => { +const validateRequest = (body: any): { value: CompileBody; error?: any } => { return joi .object({ syntax: joi.string().required(), diff --git a/tools/webide/packages/server/src/handlers/deploy.ts b/tools/webide/packages/server/src/handlers/deploy.ts index 6409c0da6..95c2f6852 100644 --- a/tools/webide/packages/server/src/handlers/deploy.ts +++ b/tools/webide/packages/server/src/handlers/deploy.ts @@ -15,7 +15,7 @@ interface DeployBody { Tezos.setProvider({ rpc: 'https://api.tez.ie/rpc/carthagenet' }); -const validateRequest = (body: any): { value: DeployBody; error: any } => { +const validateRequest = (body: any): { value: DeployBody; error?: any } => { return joi .object({ syntax: joi.string().required(), diff --git a/tools/webide/packages/server/src/handlers/dry-run.ts b/tools/webide/packages/server/src/handlers/dry-run.ts index 815d0c286..0edd1a856 100644 --- a/tools/webide/packages/server/src/handlers/dry-run.ts +++ b/tools/webide/packages/server/src/handlers/dry-run.ts @@ -12,7 +12,7 @@ interface DryRunBody { storage: string; } -const validateRequest = (body: any): { value: DryRunBody; error: any } => { +const validateRequest = (body: any): { value: DryRunBody; error?: any } => { return joi .object({ syntax: joi.string().required(), diff --git a/tools/webide/packages/server/src/handlers/evaluate-value.ts b/tools/webide/packages/server/src/handlers/evaluate-value.ts index 80ca504bf..4805b5cfe 100644 --- a/tools/webide/packages/server/src/handlers/evaluate-value.ts +++ b/tools/webide/packages/server/src/handlers/evaluate-value.ts @@ -12,7 +12,7 @@ interface EvaluateValueBody { const validateRequest = ( body: any -): { value: EvaluateValueBody; error: any } => { +): { value: EvaluateValueBody; error?: any } => { return joi .object({ syntax: joi.string().required(), diff --git a/tools/webide/packages/server/src/handlers/run-function.ts b/tools/webide/packages/server/src/handlers/run-function.ts index 0fbf95d9e..da64c787b 100644 --- a/tools/webide/packages/server/src/handlers/run-function.ts +++ b/tools/webide/packages/server/src/handlers/run-function.ts @@ -11,7 +11,7 @@ interface RunFunctionBody { parameters: string; } -const validateRequest = (body: any): { value: RunFunctionBody; error: any } => { +const validateRequest = (body: any): { value: RunFunctionBody; error?: any } => { return joi .object({ syntax: joi.string().required(), diff --git a/tools/webide/packages/server/src/handlers/share.ts b/tools/webide/packages/server/src/handlers/share.ts index 18bc13627..d8b282b8d 100644 --- a/tools/webide/packages/server/src/handlers/share.ts +++ b/tools/webide/packages/server/src/handlers/share.ts @@ -35,7 +35,7 @@ interface ShareBody { }; } -const validateRequest = (body: any): { value: ShareBody; error: any } => { +const validateRequest = (body: any): { value: ShareBody; error?: any } => { return joi .object({ editor: joi diff --git a/tools/webide/packages/server/src/load-state.ts b/tools/webide/packages/server/src/load-state.ts index a1062e962..11da3a100 100644 --- a/tools/webide/packages/server/src/load-state.ts +++ b/tools/webide/packages/server/src/load-state.ts @@ -28,6 +28,7 @@ export async function loadDefaultState(appBundleDirectory: string) { deploy: {}, evaluateValue: {}, evaluateFunction: {}, + generateDeployScript: {}, editor: { title: '' }, @@ -63,6 +64,10 @@ export async function loadDefaultState(appBundleDirectory: string) { ...defaultState.evaluateFunction, ...defaultExample.evaluateFunction }; + defaultState.generateDeployScript = { + ...defaultState.generateDeployScript, + ...defaultExample.generateDeployScript + }; defaultState.editor = { ...defaultState.editor, ...defaultExample.editor, diff --git a/tools/webide/yarn.lock b/tools/webide/yarn.lock index 8c98907c0..95b4c22dc 100644 --- a/tools/webide/yarn.lock +++ b/tools/webide/yarn.lock @@ -2,13 +2,29 @@ # yarn lockfile v1 -"@babel/code-frame@7.5.5", "@babel/code-frame@^7.0.0", "@babel/code-frame@^7.5.5": +"@babel/code-frame@7.5.5": version "7.5.5" resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.5.5.tgz#bc0782f6d69f7b7d49531219699b988f669a8f9d" integrity sha512-27d4lZoomVyo51VegxI20xZPuSHusqbQag/ztrBC7wegWoQ1nLREPVSKSW8byhTlzTKyNE4ifaTA6lCp7JjpFw== dependencies: "@babel/highlight" "^7.0.0" +"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.5.5", "@babel/code-frame@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.8.3.tgz#33e25903d7481181534e12ec0a25f16b6fcf419e" + integrity sha512-a9gxpmdXtZEInkCSHUJDLHZVBgb1QS0jhss4cPP93EW7s+uC5bikET2twEF3KV+7rDblJcmNvTR7VJejqd2C2g== + dependencies: + "@babel/highlight" "^7.8.3" + +"@babel/compat-data@^7.9.0", "@babel/compat-data@^7.9.6": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/compat-data/-/compat-data-7.9.6.tgz#3f604c40e420131affe6f2c8052e9a275ae2049b" + integrity sha512-5QPTrNen2bm7RBc7dsOmcA5hbrS4O2Vhmk5XOL4zWW/zD/hV0iinpefDlkm+tBBy8kDtFaaeEvmAqt+nURAV2g== + dependencies: + browserslist "^4.11.1" + invariant "^2.2.4" + semver "^5.5.0" + "@babel/core@7.6.0": version "7.6.0" resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.6.0.tgz#9b00f73554edd67bebc86df8303ef678be3d7b48" @@ -29,878 +45,1012 @@ semver "^5.4.1" source-map "^0.5.0" -"@babel/core@^7.1.0", "@babel/core@^7.4.5": - version "7.6.4" - resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.6.4.tgz#6ebd9fe00925f6c3e177bb726a188b5f578088ff" - integrity sha512-Rm0HGw101GY8FTzpWSyRbki/jzq+/PkNQJ+nSulrdY6gFGOsNseCqD6KHRYe2E+EdzuBdr2pxCp6s4Uk6eJ+XQ== +"@babel/core@7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.9.0.tgz#ac977b538b77e132ff706f3b8a4dbad09c03c56e" + integrity sha512-kWc7L0fw1xwvI0zi8OKVBuxRVefwGOrKSQMvrQ3dW+bIIavBY3/NpXmpjMy7bQnLgwgzWQZ8TlM57YHpHNHz4w== dependencies: - "@babel/code-frame" "^7.5.5" - "@babel/generator" "^7.6.4" - "@babel/helpers" "^7.6.2" - "@babel/parser" "^7.6.4" - "@babel/template" "^7.6.0" - "@babel/traverse" "^7.6.3" - "@babel/types" "^7.6.3" - convert-source-map "^1.1.0" + "@babel/code-frame" "^7.8.3" + "@babel/generator" "^7.9.0" + "@babel/helper-module-transforms" "^7.9.0" + "@babel/helpers" "^7.9.0" + "@babel/parser" "^7.9.0" + "@babel/template" "^7.8.6" + "@babel/traverse" "^7.9.0" + "@babel/types" "^7.9.0" + convert-source-map "^1.7.0" debug "^4.1.0" - json5 "^2.1.0" + gensync "^1.0.0-beta.1" + json5 "^2.1.2" lodash "^4.17.13" resolve "^1.3.2" semver "^5.4.1" source-map "^0.5.0" -"@babel/generator@^7.4.0", "@babel/generator@^7.6.0", "@babel/generator@^7.6.3", "@babel/generator@^7.6.4": - version "7.6.4" - resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.6.4.tgz#a4f8437287bf9671b07f483b76e3bb731bc97671" - integrity sha512-jsBuXkFoZxk0yWLyGI9llT9oiQ2FeTASmRFE32U+aaDTfoE92t78eroO7PTpU/OrYq38hlcDM6vbfLDaOLy+7w== +"@babel/core@^7.1.0", "@babel/core@^7.4.5": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/core/-/core-7.9.6.tgz#d9aa1f580abf3b2286ef40b6904d390904c63376" + integrity sha512-nD3deLvbsApbHAHttzIssYqgb883yU/d9roe4RZymBCDaZryMJDbptVpEpeQuRh4BJ+SYI8le9YGxKvFEvl1Wg== dependencies: - "@babel/types" "^7.6.3" + "@babel/code-frame" "^7.8.3" + "@babel/generator" "^7.9.6" + "@babel/helper-module-transforms" "^7.9.0" + "@babel/helpers" "^7.9.6" + "@babel/parser" "^7.9.6" + "@babel/template" "^7.8.6" + "@babel/traverse" "^7.9.6" + "@babel/types" "^7.9.6" + convert-source-map "^1.7.0" + debug "^4.1.0" + gensync "^1.0.0-beta.1" + json5 "^2.1.2" + lodash "^4.17.13" + resolve "^1.3.2" + semver "^5.4.1" + source-map "^0.5.0" + +"@babel/generator@^7.4.0", "@babel/generator@^7.6.0", "@babel/generator@^7.9.0", "@babel/generator@^7.9.6": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/generator/-/generator-7.9.6.tgz#5408c82ac5de98cda0d77d8124e99fa1f2170a43" + integrity sha512-+htwWKJbH2bL72HRluF8zumBxzuX0ZZUFl3JLNyoUjM/Ho8wnVpPXM6aUz8cfKDqQ/h7zHqKt4xzJteUosckqQ== + dependencies: + "@babel/types" "^7.9.6" jsesc "^2.5.1" lodash "^4.17.13" source-map "^0.5.0" -"@babel/helper-annotate-as-pure@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.0.0.tgz#323d39dd0b50e10c7c06ca7d7638e6864d8c5c32" - integrity sha512-3UYcJUj9kvSLbLbUIfQTqzcy5VX7GRZ/CCDrnOaZorFFM01aXp1+GJwuFGV4NDDoAS+mOUyHcO6UD/RfqOks3Q== +"@babel/helper-annotate-as-pure@^7.0.0", "@babel/helper-annotate-as-pure@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.8.3.tgz#60bc0bc657f63a0924ff9a4b4a0b24a13cf4deee" + integrity sha512-6o+mJrZBxOoEX77Ezv9zwW7WV8DdluouRKNY/IR5u/YTMuKHgugHOzYWlYvYLpLA9nPsQCAAASpCIbjI9Mv+Uw== dependencies: - "@babel/types" "^7.0.0" + "@babel/types" "^7.8.3" -"@babel/helper-builder-binary-assignment-operator-visitor@^7.1.0": - version "7.1.0" - resolved "https://registry.yarnpkg.com/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.1.0.tgz#6b69628dfe4087798e0c4ed98e3d4a6b2fbd2f5f" - integrity sha512-qNSR4jrmJ8M1VMM9tibvyRAHXQs2PmaksQF7c1CGJNipfe3D8p+wgNwgso/P2A2r2mdgBWAXljNWR0QRZAMW8w== +"@babel/helper-builder-binary-assignment-operator-visitor@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-builder-binary-assignment-operator-visitor/-/helper-builder-binary-assignment-operator-visitor-7.8.3.tgz#c84097a427a061ac56a1c30ebf54b7b22d241503" + integrity sha512-5eFOm2SyFPK4Rh3XMMRDjN7lBH0orh3ss0g3rTYZnBQ+r6YPj7lgDyCvPphynHvUrobJmeMignBr6Acw9mAPlw== dependencies: - "@babel/helper-explode-assignable-expression" "^7.1.0" - "@babel/types" "^7.0.0" + "@babel/helper-explode-assignable-expression" "^7.8.3" + "@babel/types" "^7.8.3" -"@babel/helper-builder-react-jsx@^7.3.0": - version "7.3.0" - resolved "https://registry.yarnpkg.com/@babel/helper-builder-react-jsx/-/helper-builder-react-jsx-7.3.0.tgz#a1ac95a5d2b3e88ae5e54846bf462eeb81b318a4" - integrity sha512-MjA9KgwCuPEkQd9ncSXvSyJ5y+j2sICHyrI0M3L+6fnS4wMSNDc1ARXsbTfbb2cXHn17VisSnU/sHFTCxVxSMw== +"@babel/helper-builder-react-jsx-experimental@^7.9.0": + version "7.9.5" + resolved "https://registry.yarnpkg.com/@babel/helper-builder-react-jsx-experimental/-/helper-builder-react-jsx-experimental-7.9.5.tgz#0b4b3e04e6123f03b404ca4dfd6528fe6bb92fe3" + integrity sha512-HAagjAC93tk748jcXpZ7oYRZH485RCq/+yEv9SIWezHRPv9moZArTnkUNciUNzvwHUABmiWKlcxJvMcu59UwTg== dependencies: - "@babel/types" "^7.3.0" - esutils "^2.0.0" + "@babel/helper-annotate-as-pure" "^7.8.3" + "@babel/helper-module-imports" "^7.8.3" + "@babel/types" "^7.9.5" -"@babel/helper-call-delegate@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/helper-call-delegate/-/helper-call-delegate-7.4.4.tgz#87c1f8ca19ad552a736a7a27b1c1fcf8b1ff1f43" - integrity sha512-l79boDFJ8S1c5hvQvG+rc+wHw6IuH7YldmRKsYtpbawsxURu/paVy57FZMomGK22/JckepaikOkY0MoAmdyOlQ== +"@babel/helper-builder-react-jsx@^7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/helper-builder-react-jsx/-/helper-builder-react-jsx-7.9.0.tgz#16bf391990b57732700a3278d4d9a81231ea8d32" + integrity sha512-weiIo4gaoGgnhff54GQ3P5wsUQmnSwpkvU0r6ZHq6TzoSzKy4JxHEgnxNytaKbov2a9z/CVNyzliuCOUPEX3Jw== dependencies: - "@babel/helper-hoist-variables" "^7.4.4" - "@babel/traverse" "^7.4.4" - "@babel/types" "^7.4.4" + "@babel/helper-annotate-as-pure" "^7.8.3" + "@babel/types" "^7.9.0" -"@babel/helper-create-class-features-plugin@^7.5.5", "@babel/helper-create-class-features-plugin@^7.6.0": - version "7.6.0" - resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.6.0.tgz#769711acca889be371e9bc2eb68641d55218021f" - integrity sha512-O1QWBko4fzGju6VoVvrZg0RROCVifcLxiApnGP3OWfWzvxRZFCoBD81K5ur5e3bVY2Vf/5rIJm8cqPKn8HUJng== +"@babel/helper-compilation-targets@^7.8.7", "@babel/helper-compilation-targets@^7.9.6": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/helper-compilation-targets/-/helper-compilation-targets-7.9.6.tgz#1e05b7ccc9d38d2f8b40b458b380a04dcfadd38a" + integrity sha512-x2Nvu0igO0ejXzx09B/1fGBxY9NXQlBW2kZsSxCJft+KHN8t9XWzIvFxtPHnBOAXpVsdxZKZFbRUC8TsNKajMw== dependencies: - "@babel/helper-function-name" "^7.1.0" - "@babel/helper-member-expression-to-functions" "^7.5.5" - "@babel/helper-optimise-call-expression" "^7.0.0" - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-replace-supers" "^7.5.5" - "@babel/helper-split-export-declaration" "^7.4.4" + "@babel/compat-data" "^7.9.6" + browserslist "^4.11.1" + invariant "^2.2.4" + levenary "^1.1.1" + semver "^5.5.0" -"@babel/helper-define-map@^7.5.5": - version "7.5.5" - resolved "https://registry.yarnpkg.com/@babel/helper-define-map/-/helper-define-map-7.5.5.tgz#3dec32c2046f37e09b28c93eb0b103fd2a25d369" - integrity sha512-fTfxx7i0B5NJqvUOBBGREnrqbTxRh7zinBANpZXAVDlsZxYdclDp467G1sQ8VZYMnAURY3RpBUAgOYT9GfzHBg== +"@babel/helper-create-class-features-plugin@^7.8.3", "@babel/helper-create-class-features-plugin@^7.9.6": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/helper-create-class-features-plugin/-/helper-create-class-features-plugin-7.9.6.tgz#965c8b0a9f051801fd9d3b372ca0ccf200a90897" + integrity sha512-6N9IeuyHvMBRyjNYOMJHrhwtu4WJMrYf8hVbEHD3pbbbmNOk1kmXSQs7bA4dYDUaIx4ZEzdnvo6NwC3WHd/Qow== dependencies: - "@babel/helper-function-name" "^7.1.0" - "@babel/types" "^7.5.5" + "@babel/helper-function-name" "^7.9.5" + "@babel/helper-member-expression-to-functions" "^7.8.3" + "@babel/helper-optimise-call-expression" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/helper-replace-supers" "^7.9.6" + "@babel/helper-split-export-declaration" "^7.8.3" + +"@babel/helper-create-regexp-features-plugin@^7.8.3", "@babel/helper-create-regexp-features-plugin@^7.8.8": + version "7.8.8" + resolved "https://registry.yarnpkg.com/@babel/helper-create-regexp-features-plugin/-/helper-create-regexp-features-plugin-7.8.8.tgz#5d84180b588f560b7864efaeea89243e58312087" + integrity sha512-LYVPdwkrQEiX9+1R29Ld/wTrmQu1SSKYnuOk3g0CkcZMA1p0gsNxJFj/3gBdaJ7Cg0Fnek5z0DsMULePP7Lrqg== + dependencies: + "@babel/helper-annotate-as-pure" "^7.8.3" + "@babel/helper-regex" "^7.8.3" + regexpu-core "^4.7.0" + +"@babel/helper-define-map@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-define-map/-/helper-define-map-7.8.3.tgz#a0655cad5451c3760b726eba875f1cd8faa02c15" + integrity sha512-PoeBYtxoZGtct3md6xZOCWPcKuMuk3IHhgxsRRNtnNShebf4C8YonTSblsK4tvDbm+eJAw2HAPOfCr+Q/YRG/g== + dependencies: + "@babel/helper-function-name" "^7.8.3" + "@babel/types" "^7.8.3" lodash "^4.17.13" -"@babel/helper-explode-assignable-expression@^7.1.0": - version "7.1.0" - resolved "https://registry.yarnpkg.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.1.0.tgz#537fa13f6f1674df745b0c00ec8fe4e99681c8f6" - integrity sha512-NRQpfHrJ1msCHtKjbzs9YcMmJZOg6mQMmGRB+hbamEdG5PNpaSm95275VD92DvJKuyl0s2sFiDmMZ+EnnvufqA== +"@babel/helper-explode-assignable-expression@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-explode-assignable-expression/-/helper-explode-assignable-expression-7.8.3.tgz#a728dc5b4e89e30fc2dfc7d04fa28a930653f982" + integrity sha512-N+8eW86/Kj147bO9G2uclsg5pwfs/fqqY5rwgIL7eTBklgXjcOJ3btzS5iM6AitJcftnY7pm2lGsrJVYLGjzIw== dependencies: - "@babel/traverse" "^7.1.0" - "@babel/types" "^7.0.0" + "@babel/traverse" "^7.8.3" + "@babel/types" "^7.8.3" -"@babel/helper-function-name@^7.1.0": - version "7.1.0" - resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.1.0.tgz#a0ceb01685f73355d4360c1247f582bfafc8ff53" - integrity sha512-A95XEoCpb3TO+KZzJ4S/5uW5fNe26DjBGqf1o9ucyLyCmi1dXq/B3c8iaWTfBk3VvetUxl16e8tIrd5teOCfGw== +"@babel/helper-function-name@^7.8.3", "@babel/helper-function-name@^7.9.5": + version "7.9.5" + resolved "https://registry.yarnpkg.com/@babel/helper-function-name/-/helper-function-name-7.9.5.tgz#2b53820d35275120e1874a82e5aabe1376920a5c" + integrity sha512-JVcQZeXM59Cd1qanDUxv9fgJpt3NeKUaqBqUEvfmQ+BCOKq2xUgaWZW2hr0dkbyJgezYuplEoh5knmrnS68efw== dependencies: - "@babel/helper-get-function-arity" "^7.0.0" - "@babel/template" "^7.1.0" - "@babel/types" "^7.0.0" + "@babel/helper-get-function-arity" "^7.8.3" + "@babel/template" "^7.8.3" + "@babel/types" "^7.9.5" -"@babel/helper-get-function-arity@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.0.0.tgz#83572d4320e2a4657263734113c42868b64e49c3" - integrity sha512-r2DbJeg4svYvt3HOS74U4eWKsUAMRH01Z1ds1zx8KNTPtpTL5JAsdFv8BNyOpVqdFhHkkRDIg5B4AsxmkjAlmQ== +"@babel/helper-get-function-arity@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-get-function-arity/-/helper-get-function-arity-7.8.3.tgz#b894b947bd004381ce63ea1db9f08547e920abd5" + integrity sha512-FVDR+Gd9iLjUMY1fzE2SR0IuaJToR4RkCDARVfsBBPSP53GEqSFjD8gNyxg246VUyc/ALRxFaAK8rVG7UT7xRA== dependencies: - "@babel/types" "^7.0.0" + "@babel/types" "^7.8.3" -"@babel/helper-hoist-variables@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.4.4.tgz#0298b5f25c8c09c53102d52ac4a98f773eb2850a" - integrity sha512-VYk2/H/BnYbZDDg39hr3t2kKyifAm1W6zHRfhx8jGjIHpQEBv9dry7oQ2f3+J703TLu69nYdxsovl0XYfcnK4w== +"@babel/helper-hoist-variables@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-hoist-variables/-/helper-hoist-variables-7.8.3.tgz#1dbe9b6b55d78c9b4183fc8cdc6e30ceb83b7134" + integrity sha512-ky1JLOjcDUtSc+xkt0xhYff7Z6ILTAHKmZLHPxAhOP0Nd77O+3nCsd6uSVYur6nJnCI029CrNbYlc0LoPfAPQg== dependencies: - "@babel/types" "^7.4.4" + "@babel/types" "^7.8.3" -"@babel/helper-member-expression-to-functions@^7.5.5": - version "7.5.5" - resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.5.5.tgz#1fb5b8ec4453a93c439ee9fe3aeea4a84b76b590" - integrity sha512-5qZ3D1uMclSNqYcXqiHoA0meVdv+xUEex9em2fqMnrk/scphGlGgg66zjMrPJESPwrFJ6sbfFQYUSa0Mz7FabA== +"@babel/helper-member-expression-to-functions@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-member-expression-to-functions/-/helper-member-expression-to-functions-7.8.3.tgz#659b710498ea6c1d9907e0c73f206eee7dadc24c" + integrity sha512-fO4Egq88utkQFjbPrSHGmGLFqmrshs11d46WI+WZDESt7Wu7wN2G2Iu+NMMZJFDOVRHAMIkB5SNh30NtwCA7RA== dependencies: - "@babel/types" "^7.5.5" + "@babel/types" "^7.8.3" -"@babel/helper-module-imports@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.0.0.tgz#96081b7111e486da4d2cd971ad1a4fe216cc2e3d" - integrity sha512-aP/hlLq01DWNEiDg4Jn23i+CXxW/owM4WpDLFUbpjxe4NS3BhLVZQ5i7E0ZrxuQ/vwekIeciyamgB1UIYxxM6A== +"@babel/helper-module-imports@^7.0.0", "@babel/helper-module-imports@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.8.3.tgz#7fe39589b39c016331b6b8c3f441e8f0b1419498" + integrity sha512-R0Bx3jippsbAEtzkpZ/6FIiuzOURPcMjHp+Z6xPe6DtApDJx+w7UYyOLanZqO8+wKR9G10s/FmHXvxaMd9s6Kg== dependencies: - "@babel/types" "^7.0.0" + "@babel/types" "^7.8.3" -"@babel/helper-module-transforms@^7.1.0", "@babel/helper-module-transforms@^7.4.4": - version "7.5.5" - resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.5.5.tgz#f84ff8a09038dcbca1fd4355661a500937165b4a" - integrity sha512-jBeCvETKuJqeiaCdyaheF40aXnnU1+wkSiUs/IQg3tB85up1LyL8x77ClY8qJpuRJUcXQo+ZtdNESmZl4j56Pw== +"@babel/helper-module-transforms@^7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/helper-module-transforms/-/helper-module-transforms-7.9.0.tgz#43b34dfe15961918707d247327431388e9fe96e5" + integrity sha512-0FvKyu0gpPfIQ8EkxlrAydOWROdHpBmiCiRwLkUiBGhCUPRRbVD2/tm3sFr/c/GWFrQ/ffutGUAnx7V0FzT2wA== dependencies: - "@babel/helper-module-imports" "^7.0.0" - "@babel/helper-simple-access" "^7.1.0" - "@babel/helper-split-export-declaration" "^7.4.4" - "@babel/template" "^7.4.4" - "@babel/types" "^7.5.5" + "@babel/helper-module-imports" "^7.8.3" + "@babel/helper-replace-supers" "^7.8.6" + "@babel/helper-simple-access" "^7.8.3" + "@babel/helper-split-export-declaration" "^7.8.3" + "@babel/template" "^7.8.6" + "@babel/types" "^7.9.0" lodash "^4.17.13" -"@babel/helper-optimise-call-expression@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.0.0.tgz#a2920c5702b073c15de51106200aa8cad20497d5" - integrity sha512-u8nd9NQePYNQV8iPWu/pLLYBqZBa4ZaY1YWRFMuxrid94wKI1QNt67NEZ7GAe5Kc/0LLScbim05xZFWkAdrj9g== +"@babel/helper-optimise-call-expression@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-optimise-call-expression/-/helper-optimise-call-expression-7.8.3.tgz#7ed071813d09c75298ef4f208956006b6111ecb9" + integrity sha512-Kag20n86cbO2AvHca6EJsvqAd82gc6VMGule4HwebwMlwkpXuVqrNRj6CkCV2sKxgi9MyAUnZVnZ6lJ1/vKhHQ== dependencies: - "@babel/types" "^7.0.0" + "@babel/types" "^7.8.3" -"@babel/helper-plugin-utils@^7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.0.0.tgz#bbb3fbee98661c569034237cc03967ba99b4f250" - integrity sha512-CYAOUCARwExnEixLdB6sDm2dIJ/YgEAKDM1MOeMeZu9Ld/bDgVo8aiWrXwcY7OBh+1Ea2uUcVRcxKk0GJvW7QA== +"@babel/helper-plugin-utils@^7.0.0", "@babel/helper-plugin-utils@^7.8.0", "@babel/helper-plugin-utils@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-plugin-utils/-/helper-plugin-utils-7.8.3.tgz#9ea293be19babc0f52ff8ca88b34c3611b208670" + integrity sha512-j+fq49Xds2smCUNYmEHF9kGNkhbet6yVIBp4e6oeQpH1RUs/Ir06xUKzDjDkGcaaokPiTNs2JBWHjaE4csUkZQ== -"@babel/helper-regex@^7.0.0", "@babel/helper-regex@^7.4.4": - version "7.5.5" - resolved "https://registry.yarnpkg.com/@babel/helper-regex/-/helper-regex-7.5.5.tgz#0aa6824f7100a2e0e89c1527c23936c152cab351" - integrity sha512-CkCYQLkfkiugbRDO8eZn6lRuR8kzZoGXCg3149iTk5se7g6qykSpy3+hELSwquhu+TgHn8nkLiBwHvNX8Hofcw== +"@babel/helper-regex@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-regex/-/helper-regex-7.8.3.tgz#139772607d51b93f23effe72105b319d2a4c6965" + integrity sha512-BWt0QtYv/cg/NecOAZMdcn/waj/5P26DR4mVLXfFtDokSR6fyuG0Pj+e2FqtSME+MqED1khnSMulkmGl8qWiUQ== dependencies: lodash "^4.17.13" -"@babel/helper-remap-async-to-generator@^7.1.0": - version "7.1.0" - resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.1.0.tgz#361d80821b6f38da75bd3f0785ece20a88c5fe7f" - integrity sha512-3fOK0L+Fdlg8S5al8u/hWE6vhufGSn0bN09xm2LXMy//REAF8kDCrYoOBKYmA8m5Nom+sV9LyLCwrFynA8/slg== +"@babel/helper-remap-async-to-generator@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-remap-async-to-generator/-/helper-remap-async-to-generator-7.8.3.tgz#273c600d8b9bf5006142c1e35887d555c12edd86" + integrity sha512-kgwDmw4fCg7AVgS4DukQR/roGp+jP+XluJE5hsRZwxCYGg+Rv9wSGErDWhlI90FODdYfd4xG4AQRiMDjjN0GzA== dependencies: - "@babel/helper-annotate-as-pure" "^7.0.0" - "@babel/helper-wrap-function" "^7.1.0" - "@babel/template" "^7.1.0" - "@babel/traverse" "^7.1.0" - "@babel/types" "^7.0.0" + "@babel/helper-annotate-as-pure" "^7.8.3" + "@babel/helper-wrap-function" "^7.8.3" + "@babel/template" "^7.8.3" + "@babel/traverse" "^7.8.3" + "@babel/types" "^7.8.3" -"@babel/helper-replace-supers@^7.5.5": - version "7.5.5" - resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.5.5.tgz#f84ce43df031222d2bad068d2626cb5799c34bc2" - integrity sha512-XvRFWrNnlsow2u7jXDuH4jDDctkxbS7gXssrP4q2nUD606ukXHRvydj346wmNg+zAgpFx4MWf4+usfC93bElJg== +"@babel/helper-replace-supers@^7.8.3", "@babel/helper-replace-supers@^7.8.6", "@babel/helper-replace-supers@^7.9.6": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/helper-replace-supers/-/helper-replace-supers-7.9.6.tgz#03149d7e6a5586ab6764996cd31d6981a17e1444" + integrity sha512-qX+chbxkbArLyCImk3bWV+jB5gTNU/rsze+JlcF6Nf8tVTigPJSI1o1oBow/9Resa1yehUO9lIipsmu9oG4RzA== dependencies: - "@babel/helper-member-expression-to-functions" "^7.5.5" - "@babel/helper-optimise-call-expression" "^7.0.0" - "@babel/traverse" "^7.5.5" - "@babel/types" "^7.5.5" + "@babel/helper-member-expression-to-functions" "^7.8.3" + "@babel/helper-optimise-call-expression" "^7.8.3" + "@babel/traverse" "^7.9.6" + "@babel/types" "^7.9.6" -"@babel/helper-simple-access@^7.1.0": - version "7.1.0" - resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.1.0.tgz#65eeb954c8c245beaa4e859da6188f39d71e585c" - integrity sha512-Vk+78hNjRbsiu49zAPALxTb+JUQCz1aolpd8osOF16BGnLtseD21nbHgLPGUwrXEurZgiCOUmvs3ExTu4F5x6w== +"@babel/helper-simple-access@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-simple-access/-/helper-simple-access-7.8.3.tgz#7f8109928b4dab4654076986af575231deb639ae" + integrity sha512-VNGUDjx5cCWg4vvCTR8qQ7YJYZ+HBjxOgXEl7ounz+4Sn7+LMD3CFrCTEU6/qXKbA2nKg21CwhhBzO0RpRbdCw== dependencies: - "@babel/template" "^7.1.0" - "@babel/types" "^7.0.0" + "@babel/template" "^7.8.3" + "@babel/types" "^7.8.3" -"@babel/helper-split-export-declaration@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.4.4.tgz#ff94894a340be78f53f06af038b205c49d993677" - integrity sha512-Ro/XkzLf3JFITkW6b+hNxzZ1n5OQ80NvIUdmHspih1XAhtN3vPTuUFT4eQnela+2MaZ5ulH+iyP513KJrxbN7Q== +"@babel/helper-split-export-declaration@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.8.3.tgz#31a9f30070f91368a7182cf05f831781065fc7a9" + integrity sha512-3x3yOeyBhW851hroze7ElzdkeRXQYQbFIb7gLK1WQYsw2GWDay5gAJNw1sWJ0VFP6z5J1whqeXH/WCdCjZv6dA== dependencies: - "@babel/types" "^7.4.4" + "@babel/types" "^7.8.3" -"@babel/helper-wrap-function@^7.1.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/helper-wrap-function/-/helper-wrap-function-7.2.0.tgz#c4e0012445769e2815b55296ead43a958549f6fa" - integrity sha512-o9fP1BZLLSrYlxYEYyl2aS+Flun5gtjTIG8iln+XuEzQTs0PLagAGSXUcqruJwD5fM48jzIEggCKpIfWTcR7pQ== - dependencies: - "@babel/helper-function-name" "^7.1.0" - "@babel/template" "^7.1.0" - "@babel/traverse" "^7.1.0" - "@babel/types" "^7.2.0" +"@babel/helper-validator-identifier@^7.9.0", "@babel/helper-validator-identifier@^7.9.5": + version "7.9.5" + resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.9.5.tgz#90977a8e6fbf6b431a7dc31752eee233bf052d80" + integrity sha512-/8arLKUFq882w4tWGj9JYzRpAlZgiWUJ+dtteNTDqrRBz9Iguck9Rn3ykuBDoUwh2TO4tSAJlrxDUOXWklJe4g== -"@babel/helpers@^7.6.0", "@babel/helpers@^7.6.2": - version "7.6.2" - resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.6.2.tgz#681ffe489ea4dcc55f23ce469e58e59c1c045153" - integrity sha512-3/bAUL8zZxYs1cdX2ilEE0WobqbCmKWr/889lf2SS0PpDcpEIY8pb1CCyz0pEcX3pEb+MCbks1jIokz2xLtGTA== +"@babel/helper-wrap-function@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/helper-wrap-function/-/helper-wrap-function-7.8.3.tgz#9dbdb2bb55ef14aaa01fe8c99b629bd5352d8610" + integrity sha512-LACJrbUET9cQDzb6kG7EeD7+7doC3JNvUgTEQOx2qaO1fKlzE/Bf05qs9w1oXQMmXlPO65lC3Tq9S6gZpTErEQ== dependencies: - "@babel/template" "^7.6.0" - "@babel/traverse" "^7.6.2" - "@babel/types" "^7.6.0" + "@babel/helper-function-name" "^7.8.3" + "@babel/template" "^7.8.3" + "@babel/traverse" "^7.8.3" + "@babel/types" "^7.8.3" -"@babel/highlight@^7.0.0": - version "7.5.0" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.5.0.tgz#56d11312bd9248fa619591d02472be6e8cb32540" - integrity sha512-7dV4eu9gBxoM0dAnj/BCFDW9LFU0zvTrkq0ugM7pnHEgguOEeOz1so2ZghEdzviYzQEED0r4EAgpsBChKy1TRQ== +"@babel/helpers@^7.6.0", "@babel/helpers@^7.9.0", "@babel/helpers@^7.9.6": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/helpers/-/helpers-7.9.6.tgz#092c774743471d0bb6c7de3ad465ab3d3486d580" + integrity sha512-tI4bUbldloLcHWoRUMAj4g1bF313M/o6fBKhIsb3QnGVPwRm9JsNf/gqMkQ7zjqReABiffPV6RWj7hEglID5Iw== dependencies: + "@babel/template" "^7.8.3" + "@babel/traverse" "^7.9.6" + "@babel/types" "^7.9.6" + +"@babel/highlight@^7.0.0", "@babel/highlight@^7.8.3": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.9.0.tgz#4e9b45ccb82b79607271b2979ad82c7b68163079" + integrity sha512-lJZPilxX7Op3Nv/2cvFdnlepPXDxi29wxteT57Q965oc5R9v86ztx0jfxVrTcBk8C2kcPkkDa2Z4T3ZsPPVWsQ== + dependencies: + "@babel/helper-validator-identifier" "^7.9.0" chalk "^2.0.0" - esutils "^2.0.2" js-tokens "^4.0.0" -"@babel/parser@^7.0.0", "@babel/parser@^7.1.0", "@babel/parser@^7.4.3", "@babel/parser@^7.6.0", "@babel/parser@^7.6.3", "@babel/parser@^7.6.4": - version "7.6.4" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.6.4.tgz#cb9b36a7482110282d5cb6dd424ec9262b473d81" - integrity sha512-D8RHPW5qd0Vbyo3qb+YjO5nvUVRTXFLQ/FsDxJU2Nqz4uB5EnUN0ZQSEYpvTIbRuttig1XbHWU5oMeQwQSAA+A== +"@babel/parser@^7.0.0", "@babel/parser@^7.1.0", "@babel/parser@^7.4.3", "@babel/parser@^7.6.0", "@babel/parser@^7.8.6", "@babel/parser@^7.9.0", "@babel/parser@^7.9.6": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.9.6.tgz#3b1bbb30dabe600cd72db58720998376ff653bc7" + integrity sha512-AoeIEJn8vt+d/6+PXDRPaksYhnlbMIiejioBZvvMQsOjW/JYK6k/0dKnvvP3EhK5GfMBWDPtrxRtegWdAcdq9Q== -"@babel/plugin-proposal-async-generator-functions@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.2.0.tgz#b289b306669dce4ad20b0252889a15768c9d417e" - integrity sha512-+Dfo/SCQqrwx48ptLVGLdE39YtWRuKc/Y9I5Fy0P1DDBB9lsAHpjcEJQt+4IifuSOSTLBKJObJqMvaO1pIE8LQ== +"@babel/plugin-proposal-async-generator-functions@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.8.3.tgz#bad329c670b382589721b27540c7d288601c6e6f" + integrity sha512-NZ9zLv848JsV3hs8ryEh7Uaz/0KsmPLqv0+PdkDJL1cJy0K4kOCFa8zc1E3mp+RHPQcpdfb/6GovEsW4VDrOMw== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-remap-async-to-generator" "^7.1.0" - "@babel/plugin-syntax-async-generators" "^7.2.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/helper-remap-async-to-generator" "^7.8.3" + "@babel/plugin-syntax-async-generators" "^7.8.0" -"@babel/plugin-proposal-class-properties@7.5.5": - version "7.5.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.5.5.tgz#a974cfae1e37c3110e71f3c6a2e48b8e71958cd4" - integrity sha512-AF79FsnWFxjlaosgdi421vmYG6/jg79bVD0dpD44QdgobzHKuLZ6S3vl8la9qIeSwGi8i1fS0O1mfuDAAdo1/A== +"@babel/plugin-proposal-class-properties@7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-class-properties/-/plugin-proposal-class-properties-7.8.3.tgz#5e06654af5cd04b608915aada9b2a6788004464e" + integrity sha512-EqFhbo7IosdgPgZggHaNObkmO1kNUe3slaKu54d5OWvy+p9QIKOzK1GAEpAIsZtWVtPXUHSMcT4smvDrCfY4AA== dependencies: - "@babel/helper-create-class-features-plugin" "^7.5.5" - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-create-class-features-plugin" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-proposal-decorators@7.6.0": - version "7.6.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-decorators/-/plugin-proposal-decorators-7.6.0.tgz#6659d2572a17d70abd68123e89a12a43d90aa30c" - integrity sha512-ZSyYw9trQI50sES6YxREXKu+4b7MAg6Qx2cvyDDYjP2Hpzd3FleOUwC9cqn1+za8d0A2ZU8SHujxFao956efUg== +"@babel/plugin-proposal-decorators@7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-decorators/-/plugin-proposal-decorators-7.8.3.tgz#2156860ab65c5abf068c3f67042184041066543e" + integrity sha512-e3RvdvS4qPJVTe288DlXjwKflpfy1hr0j5dz5WpIYYeP7vQZg2WfAEIp8k5/Lwis/m5REXEteIz6rrcDtXXG7w== dependencies: - "@babel/helper-create-class-features-plugin" "^7.6.0" - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-syntax-decorators" "^7.2.0" + "@babel/helper-create-class-features-plugin" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-decorators" "^7.8.3" -"@babel/plugin-proposal-dynamic-import@^7.5.0": - version "7.5.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.5.0.tgz#e532202db4838723691b10a67b8ce509e397c506" - integrity sha512-x/iMjggsKTFHYC6g11PL7Qy58IK8H5zqfm9e6hu4z1iH2IRyAp9u9dL80zA6R76yFovETFLKz2VJIC2iIPBuFw== +"@babel/plugin-proposal-dynamic-import@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-dynamic-import/-/plugin-proposal-dynamic-import-7.8.3.tgz#38c4fe555744826e97e2ae930b0fb4cc07e66054" + integrity sha512-NyaBbyLFXFLT9FP+zk0kYlUlA8XtCUbehs67F0nnEg7KICgMc2mNkIeu9TYhKzyXMkrapZFwAhXLdnt4IYHy1w== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-syntax-dynamic-import" "^7.2.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-dynamic-import" "^7.8.0" -"@babel/plugin-proposal-json-strings@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.2.0.tgz#568ecc446c6148ae6b267f02551130891e29f317" - integrity sha512-MAFV1CA/YVmYwZG0fBQyXhmj0BHCB5egZHCKWIFVv/XCxAeVGIHfos3SwDck4LvCllENIAg7xMKOG5kH0dzyUg== +"@babel/plugin-proposal-json-strings@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-json-strings/-/plugin-proposal-json-strings-7.8.3.tgz#da5216b238a98b58a1e05d6852104b10f9a70d6b" + integrity sha512-KGhQNZ3TVCQG/MjRbAUwuH+14y9q0tpxs1nWWs3pbSleRdDro9SAMMDyye8HhY1gqZ7/NqIc8SKhya0wRDgP1Q== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-syntax-json-strings" "^7.2.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-json-strings" "^7.8.0" -"@babel/plugin-proposal-object-rest-spread@7.5.5": - version "7.5.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.5.5.tgz#61939744f71ba76a3ae46b5eea18a54c16d22e58" - integrity sha512-F2DxJJSQ7f64FyTVl5cw/9MWn6naXGdk3Q3UhDbFEEHv+EilCPoeRD3Zh/Utx1CJz4uyKlQ4uH+bJPbEhMV7Zw== +"@babel/plugin-proposal-nullish-coalescing-operator@7.8.3", "@babel/plugin-proposal-nullish-coalescing-operator@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-nullish-coalescing-operator/-/plugin-proposal-nullish-coalescing-operator-7.8.3.tgz#e4572253fdeed65cddeecfdab3f928afeb2fd5d2" + integrity sha512-TS9MlfzXpXKt6YYomudb/KU7nQI6/xnapG6in1uZxoxDghuSMZsPb6D2fyUwNYSAp4l1iR7QtFOjkqcRYcUsfw== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-syntax-object-rest-spread" "^7.2.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.0" -"@babel/plugin-proposal-object-rest-spread@^7.5.5", "@babel/plugin-proposal-object-rest-spread@^7.6.2": - version "7.6.2" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.6.2.tgz#8ffccc8f3a6545e9f78988b6bf4fe881b88e8096" - integrity sha512-LDBXlmADCsMZV1Y9OQwMc0MyGZ8Ta/zlD9N67BfQT8uYwkRswiu2hU6nJKrjrt/58aH/vqfQlR/9yId/7A2gWw== +"@babel/plugin-proposal-numeric-separator@7.8.3", "@babel/plugin-proposal-numeric-separator@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-numeric-separator/-/plugin-proposal-numeric-separator-7.8.3.tgz#5d6769409699ec9b3b68684cd8116cedff93bad8" + integrity sha512-jWioO1s6R/R+wEHizfaScNsAx+xKgwTLNXSh7tTC4Usj3ItsPEhYkEpU4h+lpnBwq7NBVOJXfO6cRFYcX69JUQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-syntax-object-rest-spread" "^7.2.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-numeric-separator" "^7.8.3" -"@babel/plugin-proposal-optional-catch-binding@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.2.0.tgz#135d81edb68a081e55e56ec48541ece8065c38f5" - integrity sha512-mgYj3jCcxug6KUcX4OBoOJz3CMrwRfQELPQ5560F70YQUBZB7uac9fqaWamKR1iWUzGiK2t0ygzjTScZnVz75g== +"@babel/plugin-proposal-object-rest-spread@^7.9.0", "@babel/plugin-proposal-object-rest-spread@^7.9.6": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-object-rest-spread/-/plugin-proposal-object-rest-spread-7.9.6.tgz#7a093586fcb18b08266eb1a7177da671ac575b63" + integrity sha512-Ga6/fhGqA9Hj+y6whNpPv8psyaK5xzrQwSPsGPloVkvmH+PqW1ixdnfJ9uIO06OjQNYol3PMnfmJ8vfZtkzF+A== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-syntax-optional-catch-binding" "^7.2.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-object-rest-spread" "^7.8.0" + "@babel/plugin-transform-parameters" "^7.9.5" -"@babel/plugin-proposal-unicode-property-regex@^7.4.4", "@babel/plugin-proposal-unicode-property-regex@^7.6.2": - version "7.6.2" - resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.6.2.tgz#05413762894f41bfe42b9a5e80919bd575dcc802" - integrity sha512-NxHETdmpeSCtiatMRYWVJo7266rrvAC3DTeG5exQBIH/fMIUK7ejDNznBbn3HQl/o9peymRRg7Yqkx6PdUXmMw== +"@babel/plugin-proposal-optional-catch-binding@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-catch-binding/-/plugin-proposal-optional-catch-binding-7.8.3.tgz#9dee96ab1650eed88646ae9734ca167ac4a9c5c9" + integrity sha512-0gkX7J7E+AtAw9fcwlVQj8peP61qhdg/89D5swOkjYbkboA2CVckn3kiyum1DE0wskGb7KJJxBdyEBApDLLVdw== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-regex" "^7.4.4" - regexpu-core "^4.6.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.0" -"@babel/plugin-syntax-async-generators@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.2.0.tgz#69e1f0db34c6f5a0cf7e2b3323bf159a76c8cb7f" - integrity sha512-1ZrIRBv2t0GSlcwVoQ6VgSLpLgiN/FVQUzt9znxo7v2Ov4jJrs8RY8tv0wvDmFN3qIdMKWrmMMW6yZ0G19MfGg== +"@babel/plugin-proposal-optional-chaining@7.9.0", "@babel/plugin-proposal-optional-chaining@^7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-optional-chaining/-/plugin-proposal-optional-chaining-7.9.0.tgz#31db16b154c39d6b8a645292472b98394c292a58" + integrity sha512-NDn5tu3tcv4W30jNhmc2hyD5c56G6cXx4TesJubhxrJeCvuuMpttxr0OnNCqbZGhFjLrg+NIhxxC+BK5F6yS3w== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-optional-chaining" "^7.8.0" -"@babel/plugin-syntax-decorators@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-decorators/-/plugin-syntax-decorators-7.2.0.tgz#c50b1b957dcc69e4b1127b65e1c33eef61570c1b" - integrity sha512-38QdqVoXdHUQfTpZo3rQwqQdWtCn5tMv4uV6r2RMfTqNBuv4ZBhz79SfaQWKTVmxHjeFv/DnXVC/+agHCklYWA== +"@babel/plugin-proposal-unicode-property-regex@^7.4.4", "@babel/plugin-proposal-unicode-property-regex@^7.8.3": + version "7.8.8" + resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-unicode-property-regex/-/plugin-proposal-unicode-property-regex-7.8.8.tgz#ee3a95e90cdc04fe8cd92ec3279fa017d68a0d1d" + integrity sha512-EVhjVsMpbhLw9ZfHWSx2iy13Q8Z/eg8e8ccVWt23sWQK5l1UdkoLJPN5w69UA4uITGBnEZD2JOe4QOHycYKv8A== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-create-regexp-features-plugin" "^7.8.8" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-syntax-dynamic-import@7.2.0", "@babel/plugin-syntax-dynamic-import@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.2.0.tgz#69c159ffaf4998122161ad8ebc5e6d1f55df8612" - integrity sha512-mVxuJ0YroI/h/tbFTPGZR8cv6ai+STMKNBq0f8hFxsxWjl94qqhsb+wXbpNMDPU3cfR1TIsVFzU3nXyZMqyK4w== +"@babel/plugin-syntax-async-generators@^7.8.0": + version "7.8.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-async-generators/-/plugin-syntax-async-generators-7.8.4.tgz#a983fb1aeb2ec3f6ed042a210f640e90e786fe0d" + integrity sha512-tycmZxkGfZaxhMRbXlPXuVFpdWlXpir2W4AMhSJgRKzk/eDlIXOhb2LHWoLpDF7TEHylV5zNhykX6KAgHJmTNw== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-flow@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-flow/-/plugin-syntax-flow-7.2.0.tgz#a765f061f803bc48f240c26f8747faf97c26bf7c" - integrity sha512-r6YMuZDWLtLlu0kqIim5o/3TNRAlWb073HwT3e2nKf9I8IIvOggPrnILYPsrrKilmn/mYEMCf/Z07w3yQJF6dg== +"@babel/plugin-syntax-decorators@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-decorators/-/plugin-syntax-decorators-7.8.3.tgz#8d2c15a9f1af624b0025f961682a9d53d3001bda" + integrity sha512-8Hg4dNNT9/LcA1zQlfwuKR8BUc/if7Q7NkTam9sGTcJphLwpf2g4S42uhspQrIrR+dpzE0dtTqBVFoHl8GtnnQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-syntax-json-strings@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.2.0.tgz#72bd13f6ffe1d25938129d2a186b11fd62951470" - integrity sha512-5UGYnMSLRE1dqqZwug+1LISpA403HzlSfsg6P9VXU6TBjcSHeNlw4DxDx7LgpF+iKZoOG/+uzqoRHTdcUpiZNg== +"@babel/plugin-syntax-dynamic-import@^7.8.0": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-dynamic-import/-/plugin-syntax-dynamic-import-7.8.3.tgz#62bf98b2da3cd21d626154fc96ee5b3cb68eacb3" + integrity sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-jsx@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.2.0.tgz#0b85a3b4bc7cdf4cc4b8bf236335b907ca22e7c7" - integrity sha512-VyN4QANJkRW6lDBmENzRszvZf3/4AXaj9YR7GwrWeeN9tEBPuXbmDYVU9bYBN0D70zCWVwUy0HWq2553VCb6Hw== +"@babel/plugin-syntax-flow@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-flow/-/plugin-syntax-flow-7.8.3.tgz#f2c883bd61a6316f2c89380ae5122f923ba4527f" + integrity sha512-innAx3bUbA0KSYj2E2MNFSn9hiCeowOFLxlsuhXzw8hMQnzkDomUr9QCD7E9VF60NmnG1sNTuuv6Qf4f8INYsg== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-syntax-object-rest-spread@^7.0.0", "@babel/plugin-syntax-object-rest-spread@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.2.0.tgz#3b7a3e733510c57e820b9142a6579ac8b0dfad2e" - integrity sha512-t0JKGgqk2We+9may3t0xDdmneaXmyxq0xieYcKHxIsrJO64n1OiMWNUtc5gQK1PA0NpdCRrtZp4z+IUaKugrSA== +"@babel/plugin-syntax-json-strings@^7.8.0": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-json-strings/-/plugin-syntax-json-strings-7.8.3.tgz#01ca21b668cd8218c9e640cb6dd88c5412b2c96a" + integrity sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-syntax-optional-catch-binding@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.2.0.tgz#a94013d6eda8908dfe6a477e7f9eda85656ecf5c" - integrity sha512-bDe4xKNhb0LI7IvZHiA13kff0KEfaGX/Hv4lMA9+7TEc63hMNvfKo6ZFpXhKuEp+II/q35Gc4NoMeDZyaUbj9w== +"@babel/plugin-syntax-jsx@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.8.3.tgz#521b06c83c40480f1e58b4fd33b92eceb1d6ea94" + integrity sha512-WxdW9xyLgBdefoo0Ynn3MRSkhe5tFVxxKNVdnZSh318WrG2e2jH+E9wd/++JsqcLJZPfz87njQJ8j2Upjm0M0A== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-syntax-typescript@^7.2.0": - version "7.3.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.3.3.tgz#a7cc3f66119a9f7ebe2de5383cce193473d65991" - integrity sha512-dGwbSMA1YhVS8+31CnPR7LB4pcbrzcV99wQzby4uAfrkZPYZlQ7ImwdpzLqi6Z6IL02b8IAL379CaMwo0x5Lag== +"@babel/plugin-syntax-nullish-coalescing-operator@^7.8.0": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-nullish-coalescing-operator/-/plugin-syntax-nullish-coalescing-operator-7.8.3.tgz#167ed70368886081f74b5c36c65a88c03b66d1a9" + integrity sha512-aSff4zPII1u2QD7y+F8oDsz19ew4IGEJg9SVW+bqwpwtfFleiQDMdzA/R+UlWDzfnHFCxxleFT0PMIrR36XLNQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-transform-arrow-functions@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.2.0.tgz#9aeafbe4d6ffc6563bf8f8372091628f00779550" - integrity sha512-ER77Cax1+8/8jCB9fo4Ud161OZzWN5qawi4GusDuRLcDbDG+bIGYY20zb2dfAFdTRGzrfq2xZPvF0R64EHnimg== +"@babel/plugin-syntax-numeric-separator@^7.8.0", "@babel/plugin-syntax-numeric-separator@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-numeric-separator/-/plugin-syntax-numeric-separator-7.8.3.tgz#0e3fb63e09bea1b11e96467271c8308007e7c41f" + integrity sha512-H7dCMAdN83PcCmqmkHB5dtp+Xa9a6LKSvA2hiFBC/5alSHxM5VgWZXFqDi0YFe8XNGT6iCa+z4V4zSt/PdZ7Dw== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-async-to-generator@^7.5.0": - version "7.5.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.5.0.tgz#89a3848a0166623b5bc481164b5936ab947e887e" - integrity sha512-mqvkzwIGkq0bEF1zLRRiTdjfomZJDV33AH3oQzHVGkI2VzEmXLpKKOBvEVaFZBJdN0XTyH38s9j/Kiqr68dggg== +"@babel/plugin-syntax-object-rest-spread@^7.0.0", "@babel/plugin-syntax-object-rest-spread@^7.8.0": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-object-rest-spread/-/plugin-syntax-object-rest-spread-7.8.3.tgz#60e225edcbd98a640332a2e72dd3e66f1af55871" + integrity sha512-XoqMijGZb9y3y2XskN+P1wUGiVwWZ5JmoDRwx5+3GmEplNyVM2s2Dg8ILFQm8rWM48orGy5YpI5Bl8U1y7ydlA== dependencies: - "@babel/helper-module-imports" "^7.0.0" - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-remap-async-to-generator" "^7.1.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-transform-block-scoped-functions@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.2.0.tgz#5d3cc11e8d5ddd752aa64c9148d0db6cb79fd190" - integrity sha512-ntQPR6q1/NKuphly49+QiQiTN0O63uOwjdD6dhIjSWBI5xlrbUFh720TIpzBhpnrLfv2tNH/BXvLIab1+BAI0w== +"@babel/plugin-syntax-optional-catch-binding@^7.8.0": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-catch-binding/-/plugin-syntax-optional-catch-binding-7.8.3.tgz#6111a265bcfb020eb9efd0fdfd7d26402b9ed6c1" + integrity sha512-6VPD0Pc1lpTqw0aKoeRTMiB+kWhAoT24PA+ksWSBrFtl5SIRVpZlwN3NNPQjehA2E/91FV3RjLWoVTglWcSV3Q== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" -"@babel/plugin-transform-block-scoping@^7.6.0", "@babel/plugin-transform-block-scoping@^7.6.3": - version "7.6.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.6.3.tgz#6e854e51fbbaa84351b15d4ddafe342f3a5d542a" - integrity sha512-7hvrg75dubcO3ZI2rjYTzUrEuh1E9IyDEhhB6qfcooxhDA33xx2MasuLVgdxzcP6R/lipAC6n9ub9maNW6RKdw== +"@babel/plugin-syntax-optional-chaining@^7.8.0": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-optional-chaining/-/plugin-syntax-optional-chaining-7.8.3.tgz#4f69c2ab95167e0180cd5336613f8c5788f7d48a" + integrity sha512-KoK9ErH1MBlCPxV0VANkXW2/dw4vlbGDrFgz8bmUsBGYkFRcbRwMh6cIJubdPrkxRwuGdtCk0v/wPTKbQgBjkg== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.0" + +"@babel/plugin-syntax-top-level-await@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-top-level-await/-/plugin-syntax-top-level-await-7.8.3.tgz#3acdece695e6b13aaf57fc291d1a800950c71391" + integrity sha512-kwj1j9lL/6Wd0hROD3b/OZZ7MSrZLqqn9RAZ5+cYYsflQ9HZBIKCUkr3+uL1MEJ1NePiUbf98jjiMQSv0NMR9g== + dependencies: + "@babel/helper-plugin-utils" "^7.8.3" + +"@babel/plugin-syntax-typescript@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-syntax-typescript/-/plugin-syntax-typescript-7.8.3.tgz#c1f659dda97711a569cef75275f7e15dcaa6cabc" + integrity sha512-GO1MQ/SGGGoiEXY0e0bSpHimJvxqB7lktLLIq2pv8xG7WZ8IMEle74jIe1FhprHBWjwjZtXHkycDLZXIWM5Wfg== + dependencies: + "@babel/helper-plugin-utils" "^7.8.3" + +"@babel/plugin-transform-arrow-functions@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-arrow-functions/-/plugin-transform-arrow-functions-7.8.3.tgz#82776c2ed0cd9e1a49956daeb896024c9473b8b6" + integrity sha512-0MRF+KC8EqH4dbuITCWwPSzsyO3HIWWlm30v8BbbpOrS1B++isGxPnnuq/IZvOX5J2D/p7DQalQm+/2PnlKGxg== + dependencies: + "@babel/helper-plugin-utils" "^7.8.3" + +"@babel/plugin-transform-async-to-generator@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-async-to-generator/-/plugin-transform-async-to-generator-7.8.3.tgz#4308fad0d9409d71eafb9b1a6ee35f9d64b64086" + integrity sha512-imt9tFLD9ogt56Dd5CI/6XgpukMwd/fLGSrix2httihVe7LOGVPhyhMh1BU5kDM7iHD08i8uUtmV2sWaBFlHVQ== + dependencies: + "@babel/helper-module-imports" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/helper-remap-async-to-generator" "^7.8.3" + +"@babel/plugin-transform-block-scoped-functions@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoped-functions/-/plugin-transform-block-scoped-functions-7.8.3.tgz#437eec5b799b5852072084b3ae5ef66e8349e8a3" + integrity sha512-vo4F2OewqjbB1+yaJ7k2EJFHlTP3jR634Z9Cj9itpqNjuLXvhlVxgnjsHsdRgASR8xYDrx6onw4vW5H6We0Jmg== + dependencies: + "@babel/helper-plugin-utils" "^7.8.3" + +"@babel/plugin-transform-block-scoping@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-block-scoping/-/plugin-transform-block-scoping-7.8.3.tgz#97d35dab66857a437c166358b91d09050c868f3a" + integrity sha512-pGnYfm7RNRgYRi7bids5bHluENHqJhrV4bCZRwc5GamaWIIs07N4rZECcmJL6ZClwjDz1GbdMZFtPs27hTB06w== + dependencies: + "@babel/helper-plugin-utils" "^7.8.3" lodash "^4.17.13" -"@babel/plugin-transform-classes@^7.5.5": - version "7.5.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.5.5.tgz#d094299d9bd680a14a2a0edae38305ad60fb4de9" - integrity sha512-U2htCNK/6e9K7jGyJ++1p5XRU+LJjrwtoiVn9SzRlDT2KubcZ11OOwy3s24TjHxPgxNwonCYP7U2K51uVYCMDg== +"@babel/plugin-transform-classes@^7.9.0", "@babel/plugin-transform-classes@^7.9.5": + version "7.9.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-classes/-/plugin-transform-classes-7.9.5.tgz#800597ddb8aefc2c293ed27459c1fcc935a26c2c" + integrity sha512-x2kZoIuLC//O5iA7PEvecB105o7TLzZo8ofBVhP79N+DO3jaX+KYfww9TQcfBEZD0nikNyYcGB1IKtRq36rdmg== dependencies: - "@babel/helper-annotate-as-pure" "^7.0.0" - "@babel/helper-define-map" "^7.5.5" - "@babel/helper-function-name" "^7.1.0" - "@babel/helper-optimise-call-expression" "^7.0.0" - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-replace-supers" "^7.5.5" - "@babel/helper-split-export-declaration" "^7.4.4" + "@babel/helper-annotate-as-pure" "^7.8.3" + "@babel/helper-define-map" "^7.8.3" + "@babel/helper-function-name" "^7.9.5" + "@babel/helper-optimise-call-expression" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/helper-replace-supers" "^7.8.6" + "@babel/helper-split-export-declaration" "^7.8.3" globals "^11.1.0" -"@babel/plugin-transform-computed-properties@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.2.0.tgz#83a7df6a658865b1c8f641d510c6f3af220216da" - integrity sha512-kP/drqTxY6Xt3NNpKiMomfgkNn4o7+vKxK2DDKcBG9sHj51vHqMBGy8wbDS/J4lMxnqs153/T3+DmCEAkC5cpA== +"@babel/plugin-transform-computed-properties@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-computed-properties/-/plugin-transform-computed-properties-7.8.3.tgz#96d0d28b7f7ce4eb5b120bb2e0e943343c86f81b" + integrity sha512-O5hiIpSyOGdrQZRQ2ccwtTVkgUDBBiCuK//4RJ6UfePllUTCENOzKxfh6ulckXKc0DixTFLCfb2HVkNA7aDpzA== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-destructuring@7.6.0", "@babel/plugin-transform-destructuring@^7.6.0": - version "7.6.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.6.0.tgz#44bbe08b57f4480094d57d9ffbcd96d309075ba6" - integrity sha512-2bGIS5P1v4+sWTCnKNDZDxbGvEqi0ijeqM/YqHtVGrvG2y0ySgnEEhXErvE9dA0bnIzY9bIzdFK0jFA46ASIIQ== +"@babel/plugin-transform-destructuring@^7.8.3", "@babel/plugin-transform-destructuring@^7.9.5": + version "7.9.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-destructuring/-/plugin-transform-destructuring-7.9.5.tgz#72c97cf5f38604aea3abf3b935b0e17b1db76a50" + integrity sha512-j3OEsGel8nHL/iusv/mRd5fYZ3DrOxWC82x0ogmdN/vHfAP4MYw+AFKYanzWlktNwikKvlzUV//afBW5FTp17Q== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-dotall-regex@^7.4.4", "@babel/plugin-transform-dotall-regex@^7.6.2": - version "7.6.2" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.6.2.tgz#44abb948b88f0199a627024e1508acaf8dc9b2f9" - integrity sha512-KGKT9aqKV+9YMZSkowzYoYEiHqgaDhGmPNZlZxX6UeHC4z30nC1J9IrZuGqbYFB1jaIGdv91ujpze0exiVK8bA== +"@babel/plugin-transform-dotall-regex@^7.4.4", "@babel/plugin-transform-dotall-regex@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-dotall-regex/-/plugin-transform-dotall-regex-7.8.3.tgz#c3c6ec5ee6125c6993c5cbca20dc8621a9ea7a6e" + integrity sha512-kLs1j9Nn4MQoBYdRXH6AeaXMbEJFaFu/v1nQkvib6QzTj8MZI5OQzqmD83/2jEM1z0DLilra5aWO5YpyC0ALIw== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-regex" "^7.4.4" - regexpu-core "^4.6.0" + "@babel/helper-create-regexp-features-plugin" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-duplicate-keys@^7.5.0": - version "7.5.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.5.0.tgz#c5dbf5106bf84cdf691222c0974c12b1df931853" - integrity sha512-igcziksHizyQPlX9gfSjHkE2wmoCH3evvD2qR5w29/Dk0SMKE/eOI7f1HhBdNhR/zxJDqrgpoDTq5YSLH/XMsQ== +"@babel/plugin-transform-duplicate-keys@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-duplicate-keys/-/plugin-transform-duplicate-keys-7.8.3.tgz#8d12df309aa537f272899c565ea1768e286e21f1" + integrity sha512-s8dHiBUbcbSgipS4SMFuWGqCvyge5V2ZeAWzR6INTVC3Ltjig/Vw1G2Gztv0vU/hRG9X8IvKvYdoksnUfgXOEQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-exponentiation-operator@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.2.0.tgz#a63868289e5b4007f7054d46491af51435766008" - integrity sha512-umh4hR6N7mu4Elq9GG8TOu9M0bakvlsREEC+ialrQN6ABS4oDQ69qJv1VtR3uxlKMCQMCvzk7vr17RHKcjx68A== +"@babel/plugin-transform-exponentiation-operator@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-exponentiation-operator/-/plugin-transform-exponentiation-operator-7.8.3.tgz#581a6d7f56970e06bf51560cd64f5e947b70d7b7" + integrity sha512-zwIpuIymb3ACcInbksHaNcR12S++0MDLKkiqXHl3AzpgdKlFNhog+z/K0+TGW+b0w5pgTq4H6IwV/WhxbGYSjQ== dependencies: - "@babel/helper-builder-binary-assignment-operator-visitor" "^7.1.0" - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-builder-binary-assignment-operator-visitor" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-flow-strip-types@7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-flow-strip-types/-/plugin-transform-flow-strip-types-7.4.4.tgz#d267a081f49a8705fc9146de0768c6b58dccd8f7" - integrity sha512-WyVedfeEIILYEaWGAUWzVNyqG4sfsNooMhXWsu/YzOvVGcsnPb5PguysjJqI3t3qiaYj0BR8T2f5njdjTGe44Q== +"@babel/plugin-transform-flow-strip-types@7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-flow-strip-types/-/plugin-transform-flow-strip-types-7.9.0.tgz#8a3538aa40434e000b8f44a3c5c9ac7229bd2392" + integrity sha512-7Qfg0lKQhEHs93FChxVLAvhBshOPQDtJUTVHr/ZwQNRccCm4O9D79r9tVSoV8iNwjP1YgfD+e/fgHcPkN1qEQg== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-syntax-flow" "^7.2.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-flow" "^7.8.3" -"@babel/plugin-transform-for-of@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.4.4.tgz#0267fc735e24c808ba173866c6c4d1440fc3c556" - integrity sha512-9T/5Dlr14Z9TIEXLXkt8T1DU7F24cbhwhMNUziN3hB1AXoZcdzPcTiKGRn/6iOymDqtTKWnr/BtRKN9JwbKtdQ== +"@babel/plugin-transform-for-of@^7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-for-of/-/plugin-transform-for-of-7.9.0.tgz#0f260e27d3e29cd1bb3128da5e76c761aa6c108e" + integrity sha512-lTAnWOpMwOXpyDx06N+ywmF3jNbafZEqZ96CGYabxHrxNX8l5ny7dt4bK/rGwAh9utyP2b2Hv7PlZh1AAS54FQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-function-name@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.4.4.tgz#e1436116abb0610c2259094848754ac5230922ad" - integrity sha512-iU9pv7U+2jC9ANQkKeNF6DrPy4GBa4NWQtl6dHB4Pb3izX2JOEvDTFarlNsBj/63ZEzNNIAMs3Qw4fNCcSOXJA== +"@babel/plugin-transform-function-name@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-function-name/-/plugin-transform-function-name-7.8.3.tgz#279373cb27322aaad67c2683e776dfc47196ed8b" + integrity sha512-rO/OnDS78Eifbjn5Py9v8y0aR+aSYhDhqAwVfsTl0ERuMZyr05L1aFSCJnbv2mmsLkit/4ReeQ9N2BgLnOcPCQ== dependencies: - "@babel/helper-function-name" "^7.1.0" - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-function-name" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-literals@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-literals/-/plugin-transform-literals-7.2.0.tgz#690353e81f9267dad4fd8cfd77eafa86aba53ea1" - integrity sha512-2ThDhm4lI4oV7fVQ6pNNK+sx+c/GM5/SaML0w/r4ZB7sAneD/piDJtwdKlNckXeyGK7wlwg2E2w33C/Hh+VFCg== +"@babel/plugin-transform-literals@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-literals/-/plugin-transform-literals-7.8.3.tgz#aef239823d91994ec7b68e55193525d76dbd5dc1" + integrity sha512-3Tqf8JJ/qB7TeldGl+TT55+uQei9JfYaregDcEAyBZ7akutriFrt6C/wLYIer6OYhleVQvH/ntEhjE/xMmy10A== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-member-expression-literals@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.2.0.tgz#fa10aa5c58a2cb6afcf2c9ffa8cb4d8b3d489a2d" - integrity sha512-HiU3zKkSU6scTidmnFJ0bMX8hz5ixC93b4MHMiYebmk2lUVNGOboPsqQvx5LzooihijUoLR/v7Nc1rbBtnc7FA== +"@babel/plugin-transform-member-expression-literals@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-member-expression-literals/-/plugin-transform-member-expression-literals-7.8.3.tgz#963fed4b620ac7cbf6029c755424029fa3a40410" + integrity sha512-3Wk2EXhnw+rP+IDkK6BdtPKsUE5IeZ6QOGrPYvw52NwBStw9V1ZVzxgK6fSKSxqUvH9eQPR3tm3cOq79HlsKYA== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-modules-amd@^7.5.0": - version "7.5.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.5.0.tgz#ef00435d46da0a5961aa728a1d2ecff063e4fb91" - integrity sha512-n20UsQMKnWrltocZZm24cRURxQnWIvsABPJlw/fvoy9c6AgHZzoelAIzajDHAQrDpuKFFPPcFGd7ChsYuIUMpg== +"@babel/plugin-transform-modules-amd@^7.9.0", "@babel/plugin-transform-modules-amd@^7.9.6": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-amd/-/plugin-transform-modules-amd-7.9.6.tgz#8539ec42c153d12ea3836e0e3ac30d5aae7b258e" + integrity sha512-zoT0kgC3EixAyIAU+9vfaUVKTv9IxBDSabgHoUCBP6FqEJ+iNiN7ip7NBKcYqbfUDfuC2mFCbM7vbu4qJgOnDw== dependencies: - "@babel/helper-module-transforms" "^7.1.0" - "@babel/helper-plugin-utils" "^7.0.0" - babel-plugin-dynamic-import-node "^2.3.0" + "@babel/helper-module-transforms" "^7.9.0" + "@babel/helper-plugin-utils" "^7.8.3" + babel-plugin-dynamic-import-node "^2.3.3" -"@babel/plugin-transform-modules-commonjs@^7.6.0": - version "7.6.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.6.0.tgz#39dfe957de4420445f1fcf88b68a2e4aa4515486" - integrity sha512-Ma93Ix95PNSEngqomy5LSBMAQvYKVe3dy+JlVJSHEXZR5ASL9lQBedMiCyVtmTLraIDVRE3ZjTZvmXXD2Ozw3g== +"@babel/plugin-transform-modules-commonjs@^7.9.0", "@babel/plugin-transform-modules-commonjs@^7.9.6": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-commonjs/-/plugin-transform-modules-commonjs-7.9.6.tgz#64b7474a4279ee588cacd1906695ca721687c277" + integrity sha512-7H25fSlLcn+iYimmsNe3uK1at79IE6SKW9q0/QeEHTMC9MdOZ+4bA+T1VFB5fgOqBWoqlifXRzYD0JPdmIrgSQ== dependencies: - "@babel/helper-module-transforms" "^7.4.4" - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-simple-access" "^7.1.0" - babel-plugin-dynamic-import-node "^2.3.0" + "@babel/helper-module-transforms" "^7.9.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/helper-simple-access" "^7.8.3" + babel-plugin-dynamic-import-node "^2.3.3" -"@babel/plugin-transform-modules-systemjs@^7.5.0": - version "7.5.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.5.0.tgz#e75266a13ef94202db2a0620977756f51d52d249" - integrity sha512-Q2m56tyoQWmuNGxEtUyeEkm6qJYFqs4c+XyXH5RAuYxObRNz9Zgj/1g2GMnjYp2EUyEy7YTrxliGCXzecl/vJg== +"@babel/plugin-transform-modules-systemjs@^7.9.0", "@babel/plugin-transform-modules-systemjs@^7.9.6": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-systemjs/-/plugin-transform-modules-systemjs-7.9.6.tgz#207f1461c78a231d5337a92140e52422510d81a4" + integrity sha512-NW5XQuW3N2tTHim8e1b7qGy7s0kZ2OH3m5octc49K1SdAKGxYxeIx7hiIz05kS1R2R+hOWcsr1eYwcGhrdHsrg== dependencies: - "@babel/helper-hoist-variables" "^7.4.4" - "@babel/helper-plugin-utils" "^7.0.0" - babel-plugin-dynamic-import-node "^2.3.0" + "@babel/helper-hoist-variables" "^7.8.3" + "@babel/helper-module-transforms" "^7.9.0" + "@babel/helper-plugin-utils" "^7.8.3" + babel-plugin-dynamic-import-node "^2.3.3" -"@babel/plugin-transform-modules-umd@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.2.0.tgz#7678ce75169f0877b8eb2235538c074268dd01ae" - integrity sha512-BV3bw6MyUH1iIsGhXlOK6sXhmSarZjtJ/vMiD9dNmpY8QXFFQTj+6v92pcfy1iqa8DeAfJFwoxcrS/TUZda6sw== +"@babel/plugin-transform-modules-umd@^7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-modules-umd/-/plugin-transform-modules-umd-7.9.0.tgz#e909acae276fec280f9b821a5f38e1f08b480697" + integrity sha512-uTWkXkIVtg/JGRSIABdBoMsoIeoHQHPTL0Y2E7xf5Oj7sLqwVsNXOkNk0VJc7vF0IMBsPeikHxFjGe+qmwPtTQ== dependencies: - "@babel/helper-module-transforms" "^7.1.0" - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-module-transforms" "^7.9.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-named-capturing-groups-regex@^7.6.0", "@babel/plugin-transform-named-capturing-groups-regex@^7.6.3": - version "7.6.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.6.3.tgz#aaa6e409dd4fb2e50b6e2a91f7e3a3149dbce0cf" - integrity sha512-jTkk7/uE6H2s5w6VlMHeWuH+Pcy2lmdwFoeWCVnvIrDUnB5gQqTVI8WfmEAhF2CDEarGrknZcmSFg1+bkfCoSw== +"@babel/plugin-transform-named-capturing-groups-regex@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-named-capturing-groups-regex/-/plugin-transform-named-capturing-groups-regex-7.8.3.tgz#a2a72bffa202ac0e2d0506afd0939c5ecbc48c6c" + integrity sha512-f+tF/8UVPU86TrCb06JoPWIdDpTNSGGcAtaD9mLP0aYGA0OS0j7j7DHJR0GTFrUZPUU6loZhbsVZgTh0N+Qdnw== dependencies: - regexpu-core "^4.6.0" + "@babel/helper-create-regexp-features-plugin" "^7.8.3" -"@babel/plugin-transform-new-target@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.4.4.tgz#18d120438b0cc9ee95a47f2c72bc9768fbed60a5" - integrity sha512-r1z3T2DNGQwwe2vPGZMBNjioT2scgWzK9BCnDEh+46z8EEwXBq24uRzd65I7pjtugzPSj921aM15RpESgzsSuA== +"@babel/plugin-transform-new-target@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-new-target/-/plugin-transform-new-target-7.8.3.tgz#60cc2ae66d85c95ab540eb34babb6434d4c70c43" + integrity sha512-QuSGysibQpyxexRyui2vca+Cmbljo8bcRckgzYV4kRIsHpVeyeC3JDO63pY+xFZ6bWOBn7pfKZTqV4o/ix9sFw== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-object-super@^7.5.5": - version "7.5.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.5.5.tgz#c70021df834073c65eb613b8679cc4a381d1a9f9" - integrity sha512-un1zJQAhSosGFBduPgN/YFNvWVpRuHKU7IHBglLoLZsGmruJPOo6pbInneflUdmq7YvSVqhpPs5zdBvLnteltQ== +"@babel/plugin-transform-object-super@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-object-super/-/plugin-transform-object-super-7.8.3.tgz#ebb6a1e7a86ffa96858bd6ac0102d65944261725" + integrity sha512-57FXk+gItG/GejofIyLIgBKTas4+pEU47IXKDBWFTxdPd7F80H8zybyAY7UoblVfBhBGs2EKM+bJUu2+iUYPDQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-replace-supers" "^7.5.5" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/helper-replace-supers" "^7.8.3" -"@babel/plugin-transform-parameters@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.4.4.tgz#7556cf03f318bd2719fe4c922d2d808be5571e16" - integrity sha512-oMh5DUO1V63nZcu/ZVLQFqiihBGo4OpxJxR1otF50GMeCLiRx5nUdtokd+u9SuVJrvvuIh9OosRFPP4pIPnwmw== +"@babel/plugin-transform-parameters@^7.8.7", "@babel/plugin-transform-parameters@^7.9.5": + version "7.9.5" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-parameters/-/plugin-transform-parameters-7.9.5.tgz#173b265746f5e15b2afe527eeda65b73623a0795" + integrity sha512-0+1FhHnMfj6lIIhVvS4KGQJeuhe1GI//h5uptK4PvLt+BGBxsoUJbd3/IW002yk//6sZPlFgsG1hY6OHLcy6kA== dependencies: - "@babel/helper-call-delegate" "^7.4.4" - "@babel/helper-get-function-arity" "^7.0.0" - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-get-function-arity" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-property-literals@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.2.0.tgz#03e33f653f5b25c4eb572c98b9485055b389e905" - integrity sha512-9q7Dbk4RhgcLp8ebduOpCbtjh7C0itoLYHXd9ueASKAG/is5PQtMR5VJGka9NKqGhYEGn5ITahd4h9QeBMylWQ== +"@babel/plugin-transform-property-literals@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-property-literals/-/plugin-transform-property-literals-7.8.3.tgz#33194300d8539c1ed28c62ad5087ba3807b98263" + integrity sha512-uGiiXAZMqEoQhRWMK17VospMZh5sXWg+dlh2soffpkAl96KAm+WZuJfa6lcELotSRmooLqg0MWdH6UUq85nmmg== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" "@babel/plugin-transform-react-constant-elements@^7.0.0": - version "7.6.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-constant-elements/-/plugin-transform-react-constant-elements-7.6.3.tgz#9fc9ea060b983c7c035acbe481cbe1fb1245bfff" - integrity sha512-1/YogSSU7Tby9rq2VCmhuRg+6pxsHy2rI7w/oo8RKoBt6uBUFG+mk6x13kK+FY1/ggN92HAfg7ADd1v1+NCOKg== + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-constant-elements/-/plugin-transform-react-constant-elements-7.9.0.tgz#a75abc936a3819edec42d3386d9f1c93f28d9d9e" + integrity sha512-wXMXsToAUOxJuBBEHajqKLFWcCkOSLshTI2ChCFFj1zDd7od4IOxiwLCOObNUvOpkxLpjIuaIdBMmNt6ocCPAw== dependencies: - "@babel/helper-annotate-as-pure" "^7.0.0" - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-react-display-name@7.2.0", "@babel/plugin-transform-react-display-name@^7.0.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-display-name/-/plugin-transform-react-display-name-7.2.0.tgz#ebfaed87834ce8dc4279609a4f0c324c156e3eb0" - integrity sha512-Htf/tPa5haZvRMiNSQSFifK12gtr/8vwfr+A9y69uF0QcU77AVu4K7MiHEkTxF7lQoHOL0F9ErqgfNEAKgXj7A== +"@babel/plugin-transform-react-display-name@7.8.3", "@babel/plugin-transform-react-display-name@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-display-name/-/plugin-transform-react-display-name-7.8.3.tgz#70ded987c91609f78353dd76d2fb2a0bb991e8e5" + integrity sha512-3Jy/PCw8Fe6uBKtEgz3M82ljt+lTg+xJaM4og+eyu83qLT87ZUSckn0wy7r31jflURWLO83TW6Ylf7lyXj3m5A== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-react-jsx-self@^7.0.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx-self/-/plugin-transform-react-jsx-self-7.2.0.tgz#461e21ad9478f1031dd5e276108d027f1b5240ba" - integrity sha512-v6S5L/myicZEy+jr6ielB0OR8h+EH/1QFx/YJ7c7Ua+7lqsjj/vW6fD5FR9hB/6y7mGbfT4vAURn3xqBxsUcdg== +"@babel/plugin-transform-react-jsx-development@^7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx-development/-/plugin-transform-react-jsx-development-7.9.0.tgz#3c2a130727caf00c2a293f0aed24520825dbf754" + integrity sha512-tK8hWKrQncVvrhvtOiPpKrQjfNX3DtkNLSX4ObuGcpS9p0QrGetKmlySIGR07y48Zft8WVgPakqd/bk46JrMSw== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-syntax-jsx" "^7.2.0" + "@babel/helper-builder-react-jsx-experimental" "^7.9.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-jsx" "^7.8.3" -"@babel/plugin-transform-react-jsx-source@^7.0.0": - version "7.5.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx-source/-/plugin-transform-react-jsx-source-7.5.0.tgz#583b10c49cf057e237085bcbd8cc960bd83bd96b" - integrity sha512-58Q+Jsy4IDCZx7kqEZuSDdam/1oW8OdDX8f+Loo6xyxdfg1yF0GE2XNJQSTZCaMol93+FBzpWiPEwtbMloAcPg== +"@babel/plugin-transform-react-jsx-self@^7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx-self/-/plugin-transform-react-jsx-self-7.9.0.tgz#f4f26a325820205239bb915bad8e06fcadabb49b" + integrity sha512-K2ObbWPKT7KUTAoyjCsFilOkEgMvFG+y0FqOl6Lezd0/13kMkkjHskVsZvblRPj1PHA44PrToaZANrryppzTvQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-syntax-jsx" "^7.2.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-jsx" "^7.8.3" -"@babel/plugin-transform-react-jsx@^7.0.0": - version "7.3.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx/-/plugin-transform-react-jsx-7.3.0.tgz#f2cab99026631c767e2745a5368b331cfe8f5290" - integrity sha512-a/+aRb7R06WcKvQLOu4/TpjKOdvVEKRLWFpKcNuHhiREPgGRB4TQJxq07+EZLS8LFVYpfq1a5lDUnuMdcCpBKg== +"@babel/plugin-transform-react-jsx-source@^7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx-source/-/plugin-transform-react-jsx-source-7.9.0.tgz#89ef93025240dd5d17d3122294a093e5e0183de0" + integrity sha512-K6m3LlSnTSfRkM6FcRk8saNEeaeyG5k7AVkBU2bZK3+1zdkSED3qNdsWrUgQBeTVD2Tp3VMmerxVO2yM5iITmw== dependencies: - "@babel/helper-builder-react-jsx" "^7.3.0" - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-syntax-jsx" "^7.2.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-jsx" "^7.8.3" -"@babel/plugin-transform-regenerator@^7.4.5": - version "7.4.5" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.4.5.tgz#629dc82512c55cee01341fb27bdfcb210354680f" - integrity sha512-gBKRh5qAaCWntnd09S8QC7r3auLCqq5DI6O0DlfoyDjslSBVqBibrMdsqO+Uhmx3+BlOmE/Kw1HFxmGbv0N9dA== +"@babel/plugin-transform-react-jsx@^7.9.1", "@babel/plugin-transform-react-jsx@^7.9.4": + version "7.9.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-react-jsx/-/plugin-transform-react-jsx-7.9.4.tgz#86f576c8540bd06d0e95e0b61ea76d55f6cbd03f" + integrity sha512-Mjqf3pZBNLt854CK0C/kRuXAnE6H/bo7xYojP+WGtX8glDGSibcwnsWwhwoSuRg0+EBnxPC1ouVnuetUIlPSAw== dependencies: - regenerator-transform "^0.14.0" + "@babel/helper-builder-react-jsx" "^7.9.0" + "@babel/helper-builder-react-jsx-experimental" "^7.9.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-jsx" "^7.8.3" -"@babel/plugin-transform-reserved-words@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.2.0.tgz#4792af87c998a49367597d07fedf02636d2e1634" - integrity sha512-fz43fqW8E1tAB3DKF19/vxbpib1fuyCwSPE418ge5ZxILnBhWyhtPgz8eh1RCGGJlwvksHkyxMxh0eenFi+kFw== +"@babel/plugin-transform-regenerator@^7.8.7": + version "7.8.7" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-regenerator/-/plugin-transform-regenerator-7.8.7.tgz#5e46a0dca2bee1ad8285eb0527e6abc9c37672f8" + integrity sha512-TIg+gAl4Z0a3WmD3mbYSk+J9ZUH6n/Yc57rtKRnlA/7rcCvpekHXe0CMZHP1gYp7/KLe9GHTuIba0vXmls6drA== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + regenerator-transform "^0.14.2" -"@babel/plugin-transform-runtime@7.6.0": - version "7.6.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.6.0.tgz#85a3cce402b28586138e368fce20ab3019b9713e" - integrity sha512-Da8tMf7uClzwUm/pnJ1S93m/aRXmoYNDD7TkHua8xBDdaAs54uZpTWvEt6NGwmoVMb9mZbntfTqmG2oSzN/7Vg== +"@babel/plugin-transform-reserved-words@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-reserved-words/-/plugin-transform-reserved-words-7.8.3.tgz#9a0635ac4e665d29b162837dd3cc50745dfdf1f5" + integrity sha512-mwMxcycN3omKFDjDQUl+8zyMsBfjRFr0Zn/64I41pmjv4NJuqcYlEtezwYtw9TFd9WR1vN5kiM+O0gMZzO6L0A== dependencies: - "@babel/helper-module-imports" "^7.0.0" - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" + +"@babel/plugin-transform-runtime@7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.9.0.tgz#45468c0ae74cc13204e1d3b1f4ce6ee83258af0b" + integrity sha512-pUu9VSf3kI1OqbWINQ7MaugnitRss1z533436waNXp+0N3ur3zfut37sXiQMxkuCF4VUjwZucen/quskCh7NHw== + dependencies: + "@babel/helper-module-imports" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" resolve "^1.8.1" semver "^5.5.1" -"@babel/plugin-transform-shorthand-properties@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.2.0.tgz#6333aee2f8d6ee7e28615457298934a3b46198f0" - integrity sha512-QP4eUM83ha9zmYtpbnyjTLAGKQritA5XW/iG9cjtuOI8s1RuL/3V6a3DeSHfKutJQ+ayUfeZJPcnCYEQzaPQqg== +"@babel/plugin-transform-shorthand-properties@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.8.3.tgz#28545216e023a832d4d3a1185ed492bcfeac08c8" + integrity sha512-I9DI6Odg0JJwxCHzbzW08ggMdCezoWcuQRz3ptdudgwaHxTjxw5HgdFJmZIkIMlRymL6YiZcped4TTCB0JcC8w== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-spread@^7.2.0", "@babel/plugin-transform-spread@^7.6.2": - version "7.6.2" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-spread/-/plugin-transform-spread-7.6.2.tgz#fc77cf798b24b10c46e1b51b1b88c2bf661bb8dd" - integrity sha512-DpSvPFryKdK1x+EDJYCy28nmAaIMdxmhot62jAXF/o99iA33Zj2Lmcp3vDmz+MUh0LNYVPvfj5iC3feb3/+PFg== +"@babel/plugin-transform-spread@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-spread/-/plugin-transform-spread-7.8.3.tgz#9c8ffe8170fdfb88b114ecb920b82fb6e95fe5e8" + integrity sha512-CkuTU9mbmAoFOI1tklFWYYbzX5qCIZVXPVy0jpXgGwkplCndQAa58s2jr66fTeQnA64bDox0HL4U56CFYoyC7g== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-sticky-regex@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.2.0.tgz#a1e454b5995560a9c1e0d537dfc15061fd2687e1" - integrity sha512-KKYCoGaRAf+ckH8gEL3JHUaFVyNHKe3ASNsZ+AlktgHevvxGigoIttrEJb8iKN03Q7Eazlv1s6cx2B2cQ3Jabw== +"@babel/plugin-transform-sticky-regex@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-sticky-regex/-/plugin-transform-sticky-regex-7.8.3.tgz#be7a1290f81dae767475452199e1f76d6175b100" + integrity sha512-9Spq0vGCD5Bb4Z/ZXXSK5wbbLFMG085qd2vhL1JYu1WcQ5bXqZBAYRzU1d+p79GcHs2szYv5pVQCX13QgldaWw== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-regex" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/helper-regex" "^7.8.3" -"@babel/plugin-transform-template-literals@^7.4.4": - version "7.4.4" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.4.4.tgz#9d28fea7bbce637fb7612a0750989d8321d4bcb0" - integrity sha512-mQrEC4TWkhLN0z8ygIvEL9ZEToPhG5K7KDW3pzGqOfIGZ28Jb0POUkeWcoz8HnHvhFy6dwAT1j8OzqN8s804+g== +"@babel/plugin-transform-template-literals@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-template-literals/-/plugin-transform-template-literals-7.8.3.tgz#7bfa4732b455ea6a43130adc0ba767ec0e402a80" + integrity sha512-820QBtykIQOLFT8NZOcTRJ1UNuztIELe4p9DCgvj4NK+PwluSJ49we7s9FB1HIGNIYT7wFUJ0ar2QpCDj0escQ== dependencies: - "@babel/helper-annotate-as-pure" "^7.0.0" - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-annotate-as-pure" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-typeof-symbol@^7.2.0": - version "7.2.0" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.2.0.tgz#117d2bcec2fbf64b4b59d1f9819894682d29f2b2" - integrity sha512-2LNhETWYxiYysBtrBTqL8+La0jIoQQnIScUJc74OYvUGRmkskNY4EzLCnjHBzdmb38wqtTaixpo1NctEcvMDZw== +"@babel/plugin-transform-typeof-symbol@^7.8.4": + version "7.8.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typeof-symbol/-/plugin-transform-typeof-symbol-7.8.4.tgz#ede4062315ce0aaf8a657a920858f1a2f35fc412" + integrity sha512-2QKyfjGdvuNfHsb7qnBBlKclbD4CfshH2KvDabiijLMGXPHJXGxtDzwIF7bQP+T0ysw8fYTtxPafgfs/c1Lrqg== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/plugin-transform-typescript@^7.6.0": - version "7.6.3" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.6.3.tgz#dddb50cf3b8b2ef70b22e5326e9a91f05a1db13b" - integrity sha512-aiWINBrPMSC3xTXRNM/dfmyYuPNKY/aexYqBgh0HBI5Y+WO5oRAqW/oROYeYHrF4Zw12r9rK4fMk/ZlAmqx/FQ== +"@babel/plugin-transform-typescript@^7.9.0": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-typescript/-/plugin-transform-typescript-7.9.6.tgz#2248971416a506fc78278fc0c0ea3179224af1e9" + integrity sha512-8OvsRdvpt3Iesf2qsAn+YdlwAJD7zJ+vhFZmDCa4b8dTp7MmHtKk5FF2mCsGxjZwuwsy/yIIay/nLmxST1ctVQ== dependencies: - "@babel/helper-create-class-features-plugin" "^7.6.0" - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-syntax-typescript" "^7.2.0" + "@babel/helper-create-class-features-plugin" "^7.9.6" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-syntax-typescript" "^7.8.3" -"@babel/plugin-transform-unicode-regex@^7.4.4", "@babel/plugin-transform-unicode-regex@^7.6.2": - version "7.6.2" - resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.6.2.tgz#b692aad888a7e8d8b1b214be6b9dc03d5031f698" - integrity sha512-orZI6cWlR3nk2YmYdb0gImrgCUwb5cBUwjf6Ks6dvNVvXERkwtJWOQaEOjPiu0Gu1Tq6Yq/hruCZZOOi9F34Dw== +"@babel/plugin-transform-unicode-regex@^7.8.3": + version "7.8.3" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-unicode-regex/-/plugin-transform-unicode-regex-7.8.3.tgz#0cef36e3ba73e5c57273effb182f46b91a1ecaad" + integrity sha512-+ufgJjYdmWfSQ+6NS9VGUR2ns8cjJjYbrbi11mZBTaWm+Fui/ncTLFF28Ei1okavY+xkojGr1eJxNsWYeA5aZw== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/helper-regex" "^7.4.4" - regexpu-core "^4.6.0" + "@babel/helper-create-regexp-features-plugin" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" -"@babel/preset-env@7.6.0": - version "7.6.0" - resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.6.0.tgz#aae4141c506100bb2bfaa4ac2a5c12b395619e50" - integrity sha512-1efzxFv/TcPsNXlRhMzRnkBFMeIqBBgzwmZwlFDw5Ubj0AGLeufxugirwZmkkX/ayi3owsSqoQ4fw8LkfK9SYg== +"@babel/preset-env@7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.9.0.tgz#a5fc42480e950ae8f5d9f8f2bbc03f52722df3a8" + integrity sha512-712DeRXT6dyKAM/FMbQTV/FvRCms2hPCx+3weRjZ8iQVQWZejWWk1wwG6ViWMyqb/ouBbGOl5b6aCk0+j1NmsQ== dependencies: - "@babel/helper-module-imports" "^7.0.0" - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-proposal-async-generator-functions" "^7.2.0" - "@babel/plugin-proposal-dynamic-import" "^7.5.0" - "@babel/plugin-proposal-json-strings" "^7.2.0" - "@babel/plugin-proposal-object-rest-spread" "^7.5.5" - "@babel/plugin-proposal-optional-catch-binding" "^7.2.0" - "@babel/plugin-proposal-unicode-property-regex" "^7.4.4" - "@babel/plugin-syntax-async-generators" "^7.2.0" - "@babel/plugin-syntax-dynamic-import" "^7.2.0" - "@babel/plugin-syntax-json-strings" "^7.2.0" - "@babel/plugin-syntax-object-rest-spread" "^7.2.0" - "@babel/plugin-syntax-optional-catch-binding" "^7.2.0" - "@babel/plugin-transform-arrow-functions" "^7.2.0" - "@babel/plugin-transform-async-to-generator" "^7.5.0" - "@babel/plugin-transform-block-scoped-functions" "^7.2.0" - "@babel/plugin-transform-block-scoping" "^7.6.0" - "@babel/plugin-transform-classes" "^7.5.5" - "@babel/plugin-transform-computed-properties" "^7.2.0" - "@babel/plugin-transform-destructuring" "^7.6.0" - "@babel/plugin-transform-dotall-regex" "^7.4.4" - "@babel/plugin-transform-duplicate-keys" "^7.5.0" - "@babel/plugin-transform-exponentiation-operator" "^7.2.0" - "@babel/plugin-transform-for-of" "^7.4.4" - "@babel/plugin-transform-function-name" "^7.4.4" - "@babel/plugin-transform-literals" "^7.2.0" - "@babel/plugin-transform-member-expression-literals" "^7.2.0" - "@babel/plugin-transform-modules-amd" "^7.5.0" - "@babel/plugin-transform-modules-commonjs" "^7.6.0" - "@babel/plugin-transform-modules-systemjs" "^7.5.0" - "@babel/plugin-transform-modules-umd" "^7.2.0" - "@babel/plugin-transform-named-capturing-groups-regex" "^7.6.0" - "@babel/plugin-transform-new-target" "^7.4.4" - "@babel/plugin-transform-object-super" "^7.5.5" - "@babel/plugin-transform-parameters" "^7.4.4" - "@babel/plugin-transform-property-literals" "^7.2.0" - "@babel/plugin-transform-regenerator" "^7.4.5" - "@babel/plugin-transform-reserved-words" "^7.2.0" - "@babel/plugin-transform-shorthand-properties" "^7.2.0" - "@babel/plugin-transform-spread" "^7.2.0" - "@babel/plugin-transform-sticky-regex" "^7.2.0" - "@babel/plugin-transform-template-literals" "^7.4.4" - "@babel/plugin-transform-typeof-symbol" "^7.2.0" - "@babel/plugin-transform-unicode-regex" "^7.4.4" - "@babel/types" "^7.6.0" - browserslist "^4.6.0" - core-js-compat "^3.1.1" + "@babel/compat-data" "^7.9.0" + "@babel/helper-compilation-targets" "^7.8.7" + "@babel/helper-module-imports" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-proposal-async-generator-functions" "^7.8.3" + "@babel/plugin-proposal-dynamic-import" "^7.8.3" + "@babel/plugin-proposal-json-strings" "^7.8.3" + "@babel/plugin-proposal-nullish-coalescing-operator" "^7.8.3" + "@babel/plugin-proposal-numeric-separator" "^7.8.3" + "@babel/plugin-proposal-object-rest-spread" "^7.9.0" + "@babel/plugin-proposal-optional-catch-binding" "^7.8.3" + "@babel/plugin-proposal-optional-chaining" "^7.9.0" + "@babel/plugin-proposal-unicode-property-regex" "^7.8.3" + "@babel/plugin-syntax-async-generators" "^7.8.0" + "@babel/plugin-syntax-dynamic-import" "^7.8.0" + "@babel/plugin-syntax-json-strings" "^7.8.0" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.0" + "@babel/plugin-syntax-numeric-separator" "^7.8.0" + "@babel/plugin-syntax-object-rest-spread" "^7.8.0" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.0" + "@babel/plugin-syntax-optional-chaining" "^7.8.0" + "@babel/plugin-syntax-top-level-await" "^7.8.3" + "@babel/plugin-transform-arrow-functions" "^7.8.3" + "@babel/plugin-transform-async-to-generator" "^7.8.3" + "@babel/plugin-transform-block-scoped-functions" "^7.8.3" + "@babel/plugin-transform-block-scoping" "^7.8.3" + "@babel/plugin-transform-classes" "^7.9.0" + "@babel/plugin-transform-computed-properties" "^7.8.3" + "@babel/plugin-transform-destructuring" "^7.8.3" + "@babel/plugin-transform-dotall-regex" "^7.8.3" + "@babel/plugin-transform-duplicate-keys" "^7.8.3" + "@babel/plugin-transform-exponentiation-operator" "^7.8.3" + "@babel/plugin-transform-for-of" "^7.9.0" + "@babel/plugin-transform-function-name" "^7.8.3" + "@babel/plugin-transform-literals" "^7.8.3" + "@babel/plugin-transform-member-expression-literals" "^7.8.3" + "@babel/plugin-transform-modules-amd" "^7.9.0" + "@babel/plugin-transform-modules-commonjs" "^7.9.0" + "@babel/plugin-transform-modules-systemjs" "^7.9.0" + "@babel/plugin-transform-modules-umd" "^7.9.0" + "@babel/plugin-transform-named-capturing-groups-regex" "^7.8.3" + "@babel/plugin-transform-new-target" "^7.8.3" + "@babel/plugin-transform-object-super" "^7.8.3" + "@babel/plugin-transform-parameters" "^7.8.7" + "@babel/plugin-transform-property-literals" "^7.8.3" + "@babel/plugin-transform-regenerator" "^7.8.7" + "@babel/plugin-transform-reserved-words" "^7.8.3" + "@babel/plugin-transform-shorthand-properties" "^7.8.3" + "@babel/plugin-transform-spread" "^7.8.3" + "@babel/plugin-transform-sticky-regex" "^7.8.3" + "@babel/plugin-transform-template-literals" "^7.8.3" + "@babel/plugin-transform-typeof-symbol" "^7.8.4" + "@babel/plugin-transform-unicode-regex" "^7.8.3" + "@babel/preset-modules" "^0.1.3" + "@babel/types" "^7.9.0" + browserslist "^4.9.1" + core-js-compat "^3.6.2" invariant "^2.2.2" - js-levenshtein "^1.1.3" + levenary "^1.1.1" semver "^5.5.0" "@babel/preset-env@^7.4.5": - version "7.6.3" - resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.6.3.tgz#9e1bf05a2e2d687036d24c40e4639dc46cef2271" - integrity sha512-CWQkn7EVnwzlOdR5NOm2+pfgSNEZmvGjOhlCHBDq0J8/EStr+G+FvPEiz9B56dR6MoiUFjXhfE4hjLoAKKJtIQ== + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/preset-env/-/preset-env-7.9.6.tgz#df063b276c6455ec6fcfc6e53aacc38da9b0aea6" + integrity sha512-0gQJ9RTzO0heXOhzftog+a/WyOuqMrAIugVYxMYf83gh1CQaQDjMtsOpqOwXyDL/5JcWsrCm8l4ju8QC97O7EQ== dependencies: - "@babel/helper-module-imports" "^7.0.0" - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-proposal-async-generator-functions" "^7.2.0" - "@babel/plugin-proposal-dynamic-import" "^7.5.0" - "@babel/plugin-proposal-json-strings" "^7.2.0" - "@babel/plugin-proposal-object-rest-spread" "^7.6.2" - "@babel/plugin-proposal-optional-catch-binding" "^7.2.0" - "@babel/plugin-proposal-unicode-property-regex" "^7.6.2" - "@babel/plugin-syntax-async-generators" "^7.2.0" - "@babel/plugin-syntax-dynamic-import" "^7.2.0" - "@babel/plugin-syntax-json-strings" "^7.2.0" - "@babel/plugin-syntax-object-rest-spread" "^7.2.0" - "@babel/plugin-syntax-optional-catch-binding" "^7.2.0" - "@babel/plugin-transform-arrow-functions" "^7.2.0" - "@babel/plugin-transform-async-to-generator" "^7.5.0" - "@babel/plugin-transform-block-scoped-functions" "^7.2.0" - "@babel/plugin-transform-block-scoping" "^7.6.3" - "@babel/plugin-transform-classes" "^7.5.5" - "@babel/plugin-transform-computed-properties" "^7.2.0" - "@babel/plugin-transform-destructuring" "^7.6.0" - "@babel/plugin-transform-dotall-regex" "^7.6.2" - "@babel/plugin-transform-duplicate-keys" "^7.5.0" - "@babel/plugin-transform-exponentiation-operator" "^7.2.0" - "@babel/plugin-transform-for-of" "^7.4.4" - "@babel/plugin-transform-function-name" "^7.4.4" - "@babel/plugin-transform-literals" "^7.2.0" - "@babel/plugin-transform-member-expression-literals" "^7.2.0" - "@babel/plugin-transform-modules-amd" "^7.5.0" - "@babel/plugin-transform-modules-commonjs" "^7.6.0" - "@babel/plugin-transform-modules-systemjs" "^7.5.0" - "@babel/plugin-transform-modules-umd" "^7.2.0" - "@babel/plugin-transform-named-capturing-groups-regex" "^7.6.3" - "@babel/plugin-transform-new-target" "^7.4.4" - "@babel/plugin-transform-object-super" "^7.5.5" - "@babel/plugin-transform-parameters" "^7.4.4" - "@babel/plugin-transform-property-literals" "^7.2.0" - "@babel/plugin-transform-regenerator" "^7.4.5" - "@babel/plugin-transform-reserved-words" "^7.2.0" - "@babel/plugin-transform-shorthand-properties" "^7.2.0" - "@babel/plugin-transform-spread" "^7.6.2" - "@babel/plugin-transform-sticky-regex" "^7.2.0" - "@babel/plugin-transform-template-literals" "^7.4.4" - "@babel/plugin-transform-typeof-symbol" "^7.2.0" - "@babel/plugin-transform-unicode-regex" "^7.6.2" - "@babel/types" "^7.6.3" - browserslist "^4.6.0" - core-js-compat "^3.1.1" + "@babel/compat-data" "^7.9.6" + "@babel/helper-compilation-targets" "^7.9.6" + "@babel/helper-module-imports" "^7.8.3" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-proposal-async-generator-functions" "^7.8.3" + "@babel/plugin-proposal-dynamic-import" "^7.8.3" + "@babel/plugin-proposal-json-strings" "^7.8.3" + "@babel/plugin-proposal-nullish-coalescing-operator" "^7.8.3" + "@babel/plugin-proposal-numeric-separator" "^7.8.3" + "@babel/plugin-proposal-object-rest-spread" "^7.9.6" + "@babel/plugin-proposal-optional-catch-binding" "^7.8.3" + "@babel/plugin-proposal-optional-chaining" "^7.9.0" + "@babel/plugin-proposal-unicode-property-regex" "^7.8.3" + "@babel/plugin-syntax-async-generators" "^7.8.0" + "@babel/plugin-syntax-dynamic-import" "^7.8.0" + "@babel/plugin-syntax-json-strings" "^7.8.0" + "@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.0" + "@babel/plugin-syntax-numeric-separator" "^7.8.0" + "@babel/plugin-syntax-object-rest-spread" "^7.8.0" + "@babel/plugin-syntax-optional-catch-binding" "^7.8.0" + "@babel/plugin-syntax-optional-chaining" "^7.8.0" + "@babel/plugin-syntax-top-level-await" "^7.8.3" + "@babel/plugin-transform-arrow-functions" "^7.8.3" + "@babel/plugin-transform-async-to-generator" "^7.8.3" + "@babel/plugin-transform-block-scoped-functions" "^7.8.3" + "@babel/plugin-transform-block-scoping" "^7.8.3" + "@babel/plugin-transform-classes" "^7.9.5" + "@babel/plugin-transform-computed-properties" "^7.8.3" + "@babel/plugin-transform-destructuring" "^7.9.5" + "@babel/plugin-transform-dotall-regex" "^7.8.3" + "@babel/plugin-transform-duplicate-keys" "^7.8.3" + "@babel/plugin-transform-exponentiation-operator" "^7.8.3" + "@babel/plugin-transform-for-of" "^7.9.0" + "@babel/plugin-transform-function-name" "^7.8.3" + "@babel/plugin-transform-literals" "^7.8.3" + "@babel/plugin-transform-member-expression-literals" "^7.8.3" + "@babel/plugin-transform-modules-amd" "^7.9.6" + "@babel/plugin-transform-modules-commonjs" "^7.9.6" + "@babel/plugin-transform-modules-systemjs" "^7.9.6" + "@babel/plugin-transform-modules-umd" "^7.9.0" + "@babel/plugin-transform-named-capturing-groups-regex" "^7.8.3" + "@babel/plugin-transform-new-target" "^7.8.3" + "@babel/plugin-transform-object-super" "^7.8.3" + "@babel/plugin-transform-parameters" "^7.9.5" + "@babel/plugin-transform-property-literals" "^7.8.3" + "@babel/plugin-transform-regenerator" "^7.8.7" + "@babel/plugin-transform-reserved-words" "^7.8.3" + "@babel/plugin-transform-shorthand-properties" "^7.8.3" + "@babel/plugin-transform-spread" "^7.8.3" + "@babel/plugin-transform-sticky-regex" "^7.8.3" + "@babel/plugin-transform-template-literals" "^7.8.3" + "@babel/plugin-transform-typeof-symbol" "^7.8.4" + "@babel/plugin-transform-unicode-regex" "^7.8.3" + "@babel/preset-modules" "^0.1.3" + "@babel/types" "^7.9.6" + browserslist "^4.11.1" + core-js-compat "^3.6.2" invariant "^2.2.2" - js-levenshtein "^1.1.3" + levenary "^1.1.1" semver "^5.5.0" -"@babel/preset-react@7.0.0": - version "7.0.0" - resolved "https://registry.yarnpkg.com/@babel/preset-react/-/preset-react-7.0.0.tgz#e86b4b3d99433c7b3e9e91747e2653958bc6b3c0" - integrity sha512-oayxyPS4Zj+hF6Et11BwuBkmpgT/zMxyuZgFrMeZID6Hdh3dGlk4sHCAhdBCpuCKW2ppBfl2uCCetlrUIJRY3w== +"@babel/preset-modules@^0.1.3": + version "0.1.3" + resolved "https://registry.yarnpkg.com/@babel/preset-modules/-/preset-modules-0.1.3.tgz#13242b53b5ef8c883c3cf7dddd55b36ce80fbc72" + integrity sha512-Ra3JXOHBq2xd56xSF7lMKXdjBn3T772Y1Wet3yWnkDly9zHvJki029tAFzvAAK5cf4YV3yoxuP61crYRol6SVg== dependencies: "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-transform-react-display-name" "^7.0.0" - "@babel/plugin-transform-react-jsx" "^7.0.0" - "@babel/plugin-transform-react-jsx-self" "^7.0.0" - "@babel/plugin-transform-react-jsx-source" "^7.0.0" + "@babel/plugin-proposal-unicode-property-regex" "^7.4.4" + "@babel/plugin-transform-dotall-regex" "^7.4.4" + "@babel/types" "^7.4.4" + esutils "^2.0.2" + +"@babel/preset-react@7.9.1": + version "7.9.1" + resolved "https://registry.yarnpkg.com/@babel/preset-react/-/preset-react-7.9.1.tgz#b346403c36d58c3bb544148272a0cefd9c28677a" + integrity sha512-aJBYF23MPj0RNdp/4bHnAP0NVqqZRr9kl0NAOP4nJCex6OYVio59+dnQzsAWFuogdLyeaKA1hmfUIVZkY5J+TQ== + dependencies: + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-transform-react-display-name" "^7.8.3" + "@babel/plugin-transform-react-jsx" "^7.9.1" + "@babel/plugin-transform-react-jsx-development" "^7.9.0" + "@babel/plugin-transform-react-jsx-self" "^7.9.0" + "@babel/plugin-transform-react-jsx-source" "^7.9.0" "@babel/preset-react@^7.0.0": - version "7.6.3" - resolved "https://registry.yarnpkg.com/@babel/preset-react/-/preset-react-7.6.3.tgz#d5242c828322520205ae4eda5d4f4f618964e2f6" - integrity sha512-07yQhmkZmRAfwREYIQgW0HEwMY9GBJVuPY4Q12UC72AbfaawuupVWa8zQs2tlL+yun45Nv/1KreII/0PLfEsgA== + version "7.9.4" + resolved "https://registry.yarnpkg.com/@babel/preset-react/-/preset-react-7.9.4.tgz#c6c97693ac65b6b9c0b4f25b948a8f665463014d" + integrity sha512-AxylVB3FXeOTQXNXyiuAQJSvss62FEotbX2Pzx3K/7c+MKJMdSg6Ose6QYllkdCFA8EInCJVw7M/o5QbLuA4ZQ== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-transform-react-display-name" "^7.0.0" - "@babel/plugin-transform-react-jsx" "^7.0.0" - "@babel/plugin-transform-react-jsx-self" "^7.0.0" - "@babel/plugin-transform-react-jsx-source" "^7.0.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-transform-react-display-name" "^7.8.3" + "@babel/plugin-transform-react-jsx" "^7.9.4" + "@babel/plugin-transform-react-jsx-development" "^7.9.0" + "@babel/plugin-transform-react-jsx-self" "^7.9.0" + "@babel/plugin-transform-react-jsx-source" "^7.9.0" -"@babel/preset-typescript@7.6.0": - version "7.6.0" - resolved "https://registry.yarnpkg.com/@babel/preset-typescript/-/preset-typescript-7.6.0.tgz#25768cb8830280baf47c45ab1a519a9977498c98" - integrity sha512-4xKw3tTcCm0qApyT6PqM9qniseCE79xGHiUnNdKGdxNsGUc2X7WwZybqIpnTmoukg3nhPceI5KPNzNqLNeIJww== +"@babel/preset-typescript@7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/preset-typescript/-/preset-typescript-7.9.0.tgz#87705a72b1f0d59df21c179f7c3d2ef4b16ce192" + integrity sha512-S4cueFnGrIbvYJgwsVFKdvOmpiL0XGw9MFW9D0vgRys5g36PBhZRL8NX8Gr2akz8XRtzq6HuDXPD/1nniagNUg== dependencies: - "@babel/helper-plugin-utils" "^7.0.0" - "@babel/plugin-transform-typescript" "^7.6.0" + "@babel/helper-plugin-utils" "^7.8.3" + "@babel/plugin-transform-typescript" "^7.9.0" -"@babel/runtime@7.6.0": - version "7.6.0" - resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.6.0.tgz#4fc1d642a9fd0299754e8b5de62c631cf5568205" - integrity sha512-89eSBLJsxNxOERC0Op4vd+0Bqm6wRMqMbFtV3i0/fbaWw/mJ8Q3eBvgX0G4SyrOOLCtbu98HspF8o09MRT+KzQ== +"@babel/runtime@7.9.0": + version "7.9.0" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.9.0.tgz#337eda67401f5b066a6f205a3113d4ac18ba495b" + integrity sha512-cTIudHnzuWLS56ik4DnRnqqNf8MkdUzV4iFFI1h7Jo9xvrpQROYaAnaSd2mHLQAzzZAPfATynX5ord6YlNYNMA== dependencies: - regenerator-runtime "^0.13.2" + regenerator-runtime "^0.13.4" -"@babel/runtime@^7.0.0", "@babel/runtime@^7.3.4", "@babel/runtime@^7.4.2", "@babel/runtime@^7.4.5", "@babel/runtime@^7.5.5": - version "7.6.3" - resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.6.3.tgz#935122c74c73d2240cafd32ddb5fc2a6cd35cf1f" - integrity sha512-kq6anf9JGjW8Nt5rYfEuGRaEAaH1mkv3Bbu6rYvLOpPh/RusSJXuKPEAoZ7L7gybZkchE8+NV5g9vKF4AGAtsA== +"@babel/runtime@^7.0.0", "@babel/runtime@^7.3.4", "@babel/runtime@^7.4.5", "@babel/runtime@^7.5.5", "@babel/runtime@^7.7.2", "@babel/runtime@^7.8.4": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.9.6.tgz#a9102eb5cadedf3f31d08a9ecf294af7827ea29f" + integrity sha512-64AF1xY3OAkFHqOb9s4jpgk1Mm5vDZ4L3acHvAml+53nO1XbXLuDodsVpO4OIUsmemlUHMxNdYMNJmsvOwLrvQ== dependencies: - regenerator-runtime "^0.13.2" + regenerator-runtime "^0.13.4" -"@babel/template@^7.1.0", "@babel/template@^7.4.0", "@babel/template@^7.4.4", "@babel/template@^7.6.0": - version "7.6.0" - resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.6.0.tgz#7f0159c7f5012230dad64cca42ec9bdb5c9536e6" - integrity sha512-5AEH2EXD8euCk446b7edmgFdub/qfH1SN6Nii3+fyXP807QRx9Q73A2N5hNwRRslC2H9sNzaFhsPubkS4L8oNQ== +"@babel/template@^7.4.0", "@babel/template@^7.6.0", "@babel/template@^7.8.3", "@babel/template@^7.8.6": + version "7.8.6" + resolved "https://registry.yarnpkg.com/@babel/template/-/template-7.8.6.tgz#86b22af15f828dfb086474f964dcc3e39c43ce2b" + integrity sha512-zbMsPMy/v0PWFZEhQJ66bqjhH+z0JgMoBWuikXybgG3Gkd/3t5oQ1Rw2WQhnSrsOmsKXnZOx15tkC4qON/+JPg== dependencies: - "@babel/code-frame" "^7.0.0" - "@babel/parser" "^7.6.0" - "@babel/types" "^7.6.0" + "@babel/code-frame" "^7.8.3" + "@babel/parser" "^7.8.6" + "@babel/types" "^7.8.6" -"@babel/traverse@^7.0.0", "@babel/traverse@^7.1.0", "@babel/traverse@^7.4.3", "@babel/traverse@^7.4.4", "@babel/traverse@^7.5.5", "@babel/traverse@^7.6.0", "@babel/traverse@^7.6.2", "@babel/traverse@^7.6.3": - version "7.6.3" - resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.6.3.tgz#66d7dba146b086703c0fb10dd588b7364cec47f9" - integrity sha512-unn7P4LGsijIxaAJo/wpoU11zN+2IaClkQAxcJWBNCMS6cmVh802IyLHNkAjQ0iYnRS3nnxk5O3fuXW28IMxTw== +"@babel/traverse@^7.0.0", "@babel/traverse@^7.1.0", "@babel/traverse@^7.4.3", "@babel/traverse@^7.6.0", "@babel/traverse@^7.8.3", "@babel/traverse@^7.9.0", "@babel/traverse@^7.9.6": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.9.6.tgz#5540d7577697bf619cc57b92aa0f1c231a94f442" + integrity sha512-b3rAHSjbxy6VEAvlxM8OV/0X4XrG72zoxme6q1MOoe2vd0bEc+TwayhuC1+Dfgqh1QEG+pj7atQqvUprHIccsg== dependencies: - "@babel/code-frame" "^7.5.5" - "@babel/generator" "^7.6.3" - "@babel/helper-function-name" "^7.1.0" - "@babel/helper-split-export-declaration" "^7.4.4" - "@babel/parser" "^7.6.3" - "@babel/types" "^7.6.3" + "@babel/code-frame" "^7.8.3" + "@babel/generator" "^7.9.6" + "@babel/helper-function-name" "^7.9.5" + "@babel/helper-split-export-declaration" "^7.8.3" + "@babel/parser" "^7.9.6" + "@babel/types" "^7.9.6" debug "^4.1.0" globals "^11.1.0" lodash "^4.17.13" -"@babel/types@^7.0.0", "@babel/types@^7.2.0", "@babel/types@^7.3.0", "@babel/types@^7.4.0", "@babel/types@^7.4.4", "@babel/types@^7.5.5", "@babel/types@^7.6.0", "@babel/types@^7.6.3": - version "7.6.3" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.6.3.tgz#3f07d96f854f98e2fbd45c64b0cb942d11e8ba09" - integrity sha512-CqbcpTxMcpuQTMhjI37ZHVgjBkysg5icREQIEZ0eG1yCNwg3oy+5AaLiOKmjsCj6nqOsa6Hf0ObjRVwokb7srA== +"@babel/types@^7.0.0", "@babel/types@^7.3.0", "@babel/types@^7.4.0", "@babel/types@^7.4.4", "@babel/types@^7.6.0", "@babel/types@^7.8.3", "@babel/types@^7.8.6", "@babel/types@^7.9.0", "@babel/types@^7.9.5", "@babel/types@^7.9.6": + version "7.9.6" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.9.6.tgz#2c5502b427251e9de1bd2dff95add646d95cc9f7" + integrity sha512-qxXzvBO//jO9ZnoasKF1uJzHd2+M6Q2ZPIVfnFps8JJvXy0ZBbwbNOmE6SGIY5XOY6d1Bo5lb9d9RJ8nv3WSeA== dependencies: - esutils "^2.0.2" + "@babel/helper-validator-identifier" "^7.9.5" lodash "^4.17.13" to-fast-properties "^2.0.0" "@cnakazawa/watch@^1.0.3": - version "1.0.3" - resolved "https://registry.yarnpkg.com/@cnakazawa/watch/-/watch-1.0.3.tgz#099139eaec7ebf07a27c1786a3ff64f39464d2ef" - integrity sha512-r5160ogAvGyHsal38Kux7YYtodEKOj89RGb28ht1jh3SJb08VwRwAKKJL0bGb04Zd/3r9FL3BFIc3bBidYffCA== + version "1.0.4" + resolved "https://registry.yarnpkg.com/@cnakazawa/watch/-/watch-1.0.4.tgz#f864ae85004d0fcab6f50be9141c4da368d1656a" + integrity sha512-v9kIhKwjeZThiWrLmj0y17CWoyddASLj9O2yvbZkbvw/N3rWOYy9zkV66ursAoVr0mV15bL8g0c4QZUE6cdDoQ== dependencies: exec-sh "^0.3.2" minimist "^1.2.0" @@ -916,52 +1066,52 @@ integrity sha512-6It2EVfGskxZCQhuykrfnALg7oVeiI6KclWSmGDqB0AiInVrTGB9Jp9i4/Ad21u9Jde/voVQz6eFX/eSg/UsPA== "@emotion/is-prop-valid@^0.8.1": - version "0.8.3" - resolved "https://registry.yarnpkg.com/@emotion/is-prop-valid/-/is-prop-valid-0.8.3.tgz#cbe62ddbea08aa022cdf72da3971570a33190d29" - integrity sha512-We7VBiltAJ70KQA0dWkdPMXnYoizlxOXpvtjmu5/MBnExd+u0PGgV27WCYanmLAbCwAU30Le/xA0CQs/F/Otig== + version "0.8.8" + resolved "https://registry.yarnpkg.com/@emotion/is-prop-valid/-/is-prop-valid-0.8.8.tgz#db28b1c4368a259b60a97311d6a952d4fd01ac1a" + integrity sha512-u5WtneEAr5IDG2Wv65yhunPSMLIpuKsbuOktRojfrEiEvRyC85LgPMZI63cr7NUqT8ZIGdSVg8ZKGxIug4lXcA== dependencies: - "@emotion/memoize" "0.7.3" + "@emotion/memoize" "0.7.4" -"@emotion/memoize@0.7.3": - version "0.7.3" - resolved "https://registry.yarnpkg.com/@emotion/memoize/-/memoize-0.7.3.tgz#5b6b1c11d6a6dddf1f2fc996f74cf3b219644d78" - integrity sha512-2Md9mH6mvo+ygq1trTeVp2uzAKwE2P7In0cRpD/M9Q70aH8L+rxMLbb3JCN2JoSWsV2O+DdFjfbbXoMoLBczow== +"@emotion/memoize@0.7.4": + version "0.7.4" + resolved "https://registry.yarnpkg.com/@emotion/memoize/-/memoize-0.7.4.tgz#19bf0f5af19149111c40d98bb0cf82119f5d9eeb" + integrity sha512-Ja/Vfqe3HpuzRsG1oBtWTHk2PGZ7GR+2Vz5iYGelAw8dx32K0y7PjVuxK6z1nMpZOqAFsRUPCkK1YjJ56qJlgw== "@emotion/unitless@^0.7.0": - version "0.7.4" - resolved "https://registry.yarnpkg.com/@emotion/unitless/-/unitless-0.7.4.tgz#a87b4b04e5ae14a88d48ebef15015f6b7d1f5677" - integrity sha512-kBa+cDHOR9jpRJ+kcGMsysrls0leukrm68DmFQoMIWQcXdr2cZvyvypWuGYT7U+9kAExUE7+T7r6G3C3A6L8MQ== + version "0.7.5" + resolved "https://registry.yarnpkg.com/@emotion/unitless/-/unitless-0.7.5.tgz#77211291c1900a700b8a78cfafda3160d76949ed" + integrity sha512-OWORNpfjMsSSUBVrRBVGECkhWcULOAJz9ZW8uK9qgxD+87M7jHRcvh/A96XXNhXTLmKcoYSQtBEX7lHMO7YRwg== -"@fortawesome/fontawesome-common-types@^0.2.25": - version "0.2.25" - resolved "https://registry.yarnpkg.com/@fortawesome/fontawesome-common-types/-/fontawesome-common-types-0.2.25.tgz#6df015905081f2762e5cfddeb7a20d2e9b16c786" - integrity sha512-3RuZPDuuPELd7RXtUqTCfed14fcny9UiPOkdr2i+cYxBoTOfQgxcDoq77fHiiHcgWuo1LoBUpvGxFF1H/y7s3Q== +"@fortawesome/fontawesome-common-types@^0.2.28": + version "0.2.28" + resolved "https://registry.yarnpkg.com/@fortawesome/fontawesome-common-types/-/fontawesome-common-types-0.2.28.tgz#1091bdfe63b3f139441e9cba27aa022bff97d8b2" + integrity sha512-gtis2/5yLdfI6n0ia0jH7NJs5i/Z/8M/ZbQL6jXQhCthEOe5Cr5NcQPhgTvFxNOtURE03/ZqUcEskdn2M+QaBg== "@fortawesome/fontawesome-svg-core@^1.2.25": - version "1.2.25" - resolved "https://registry.yarnpkg.com/@fortawesome/fontawesome-svg-core/-/fontawesome-svg-core-1.2.25.tgz#24b03391d14f0c6171e8cad7057c687b74049790" - integrity sha512-MotKnn53JKqbkLQiwcZSBJVYtTgIKFbh7B8+kd05TSnfKYPFmjKKI59o2fpz5t0Hzl35vVGU6+N4twoOpZUrqA== + version "1.2.28" + resolved "https://registry.yarnpkg.com/@fortawesome/fontawesome-svg-core/-/fontawesome-svg-core-1.2.28.tgz#e5b8c8814ef375f01f5d7c132d3c3a2f83a3abf9" + integrity sha512-4LeaNHWvrneoU0i8b5RTOJHKx7E+y7jYejplR7uSVB34+mp3Veg7cbKk7NBCLiI4TyoWS1wh9ZdoyLJR8wSAdg== dependencies: - "@fortawesome/fontawesome-common-types" "^0.2.25" + "@fortawesome/fontawesome-common-types" "^0.2.28" "@fortawesome/free-solid-svg-icons@^5.11.2": - version "5.11.2" - resolved "https://registry.yarnpkg.com/@fortawesome/free-solid-svg-icons/-/free-solid-svg-icons-5.11.2.tgz#2f2f1459743a27902b76655a0d0bc5ec4d945631" - integrity sha512-zBue4i0PAZJUXOmLBBvM7L0O7wmsDC8dFv9IhpW5QL4kT9xhhVUsYg/LX1+5KaukWq4/cbDcKT+RT1aRe543sg== + version "5.13.0" + resolved "https://registry.yarnpkg.com/@fortawesome/free-solid-svg-icons/-/free-solid-svg-icons-5.13.0.tgz#44d9118668ad96b4fd5c9434a43efc5903525739" + integrity sha512-IHUgDJdomv6YtG4p3zl1B5wWf9ffinHIvebqQOmV3U+3SLw4fC+LUCCgwfETkbTtjy5/Qws2VoVf6z/ETQpFpg== dependencies: - "@fortawesome/fontawesome-common-types" "^0.2.25" + "@fortawesome/fontawesome-common-types" "^0.2.28" "@fortawesome/react-fontawesome@^0.1.6": - version "0.1.6" - resolved "https://registry.yarnpkg.com/@fortawesome/react-fontawesome/-/react-fontawesome-0.1.6.tgz#b798b96401e25d07c30bbe1b9ec0e6d8a33760a5" - integrity sha512-DNqt2t4JQ0YQKi832XzByk1wlQzgugwwCCNQHsFyz1z/zA9dtypSvsvVwMIaWXMljalYzKAA2zHX13C1DIxKAw== + version "0.1.9" + resolved "https://registry.yarnpkg.com/@fortawesome/react-fontawesome/-/react-fontawesome-0.1.9.tgz#c865b9286c707407effcec99958043711367cd02" + integrity sha512-49V3WNysLZU5fZ3sqSuys4nGRytsrxJktbv3vuaXkEoxv22C6T7TEG0TW6+nqVjMnkfCQd5xOnmJoZHMF78tOw== dependencies: - prop-types "^15.5.10" + prop-types "^15.7.2" "@google-cloud/common@^2.1.1": - version "2.2.3" - resolved "https://registry.yarnpkg.com/@google-cloud/common/-/common-2.2.3.tgz#fc29701b09d7bc9d26ea6b6be119c77485210dbf" - integrity sha512-lvw54mGKn8VqVIy2NzAk0l5fntBFX4UwQhHk6HaqkyCQ7WBl5oz4XhzKMtMilozF/3ObPcDogqwuyEWyZ6rnQQ== + version "2.4.0" + resolved "https://registry.yarnpkg.com/@google-cloud/common/-/common-2.4.0.tgz#2783b7de8435024a31453510f2dab5a6a91a4c82" + integrity sha512-zWFjBS35eI9leAHhjfeOYlK5Plcuj/77EzstnrJIZbKgF/nkqjcQuGiMCpzCwOfPyUbz8ZaEOYgbHa759AKbjg== dependencies: "@google-cloud/projectify" "^1.0.0" "@google-cloud/promisify" "^1.0.0" @@ -971,30 +1121,30 @@ extend "^3.0.2" google-auth-library "^5.5.0" retry-request "^4.0.0" - teeny-request "^5.2.1" + teeny-request "^6.0.0" "@google-cloud/paginator@^2.0.0": - version "2.0.1" - resolved "https://registry.yarnpkg.com/@google-cloud/paginator/-/paginator-2.0.1.tgz#89ca97933eecfdd7eaa07bd79ed01c9869c9531b" - integrity sha512-HZ6UTGY/gHGNriD7OCikYWL/Eu0sTEur2qqse2w6OVsz+57se3nTkqH14JIPxtf0vlEJ8IJN5w3BdZ22pjCB8g== + version "2.0.3" + resolved "https://registry.yarnpkg.com/@google-cloud/paginator/-/paginator-2.0.3.tgz#c7987ad05d1c3ebcef554381be80e9e8da4e4882" + integrity sha512-kp/pkb2p/p0d8/SKUu4mOq8+HGwF8NPzHWkj+VKrIPQPyMRw8deZtrO/OcSiy9C/7bpfU5Txah5ltUNfPkgEXg== dependencies: arrify "^2.0.0" extend "^3.0.2" "@google-cloud/projectify@^1.0.0": - version "1.0.1" - resolved "https://registry.yarnpkg.com/@google-cloud/projectify/-/projectify-1.0.1.tgz#f654c2ea9de923294ec814ff07c42891abf2d143" - integrity sha512-xknDOmsMgOYHksKc1GPbwDLsdej8aRNIA17SlSZgQdyrcC0lx0OGo4VZgYfwoEU1YS8oUxF9Y+6EzDOb0eB7Xg== + version "1.0.4" + resolved "https://registry.yarnpkg.com/@google-cloud/projectify/-/projectify-1.0.4.tgz#28daabebba6579ed998edcadf1a8f3be17f3b5f0" + integrity sha512-ZdzQUN02eRsmTKfBj9FDL0KNDIFNjBn/d6tHQmA/+FImH5DO6ZV8E7FzxMgAUiVAUq41RFAkb25p1oHOZ8psfg== "@google-cloud/promisify@^1.0.0": - version "1.0.2" - resolved "https://registry.yarnpkg.com/@google-cloud/promisify/-/promisify-1.0.2.tgz#e581aa79ff71fb6074acc1cc59e3d81bf84ce07b" - integrity sha512-7WfV4R/3YV5T30WRZW0lqmvZy9hE2/p9MvpI34WuKa2Wz62mLu5XplGTFEMK6uTbJCLWUxTcZ4J4IyClKucE5g== + version "1.0.4" + resolved "https://registry.yarnpkg.com/@google-cloud/promisify/-/promisify-1.0.4.tgz#ce86ffa94f9cfafa2e68f7b3e4a7fad194189723" + integrity sha512-VccZDcOql77obTnFh0TbNED/6ZbbmHDf8UMNnzO1d5g9V0Htfm4k5cllY8P1tJsRKC3zWYGRLaViiupcgVjBoQ== "@google-cloud/storage@^4.0.0": - version "4.0.0" - resolved "https://registry.yarnpkg.com/@google-cloud/storage/-/storage-4.0.0.tgz#ad7df44eb7a7ce469c26d86967c444a7484cf595" - integrity sha512-ZhMSvIrsyULJNGuhB3vK9VKxIh92W/sOjEezaxykKewB/NxK/d09cC1AfpwHFcnxN+ZZcy1fSLAIwfNAnKU+lA== + version "4.7.0" + resolved "https://registry.yarnpkg.com/@google-cloud/storage/-/storage-4.7.0.tgz#a7466086a83911c7979cc238d00a127ffb645615" + integrity sha512-f0guAlbeg7Z0m3gKjCfBCu7FG9qS3M3oL5OQQxlvGoPtK7/qg3+W+KQV73O2/sbuS54n0Kh2mvT5K2FWzF5vVQ== dependencies: "@google-cloud/common" "^2.1.1" "@google-cloud/paginator" "^2.0.0" @@ -1002,10 +1152,10 @@ arrify "^2.0.0" compressible "^2.0.12" concat-stream "^2.0.0" - date-and-time "^0.10.0" + date-and-time "^0.13.0" duplexify "^3.5.0" extend "^3.0.2" - gaxios "^2.0.1" + gaxios "^3.0.0" gcs-resumable-upload "^2.2.4" hash-stream-validation "^0.2.2" mime "^2.2.0" @@ -1020,9 +1170,9 @@ xdg-basedir "^4.0.0" "@hapi/address@2.x.x", "@hapi/address@^2.1.2": - version "2.1.2" - resolved "https://registry.yarnpkg.com/@hapi/address/-/address-2.1.2.tgz#1c794cd6dbf2354d1eb1ef10e0303f573e1c7222" - integrity sha512-O4QDrx+JoGKZc6aN64L04vqa7e41tIiLU+OvKdcYaEMP97UttL0f9GIi9/0A4WAMx0uBd6SidDIhktZhgOcN8Q== + version "2.1.4" + resolved "https://registry.yarnpkg.com/@hapi/address/-/address-2.1.4.tgz#5d67ed43f3fd41a69d4b9ff7b56e7c0d1d0a81e5" + integrity sha512-QD1PhQk+s31P1ixsX0H0Suoupp3VMXzIVMSwobR3F3MSUO2YCV0B7xqLcUw/Bh8yuvd3LhpyqLQWTNcRmp6IdQ== "@hapi/bourne@1.x.x": version "1.3.2" @@ -1035,9 +1185,9 @@ integrity sha512-UFbtbGPjstz0eWHb+ga/GM3Z9EzqKXFWIbSOFURU0A/Gku0Bky4bCk9/h//K2Xr3IrCfjFNhMm4jyZ5dbCewGA== "@hapi/hoek@8.x.x", "@hapi/hoek@^8.2.4", "@hapi/hoek@^8.3.0": - version "8.3.0" - resolved "https://registry.yarnpkg.com/@hapi/hoek/-/hoek-8.3.0.tgz#2b9db1cd00f3891005c77b3a8d608b88a6d0aa4d" - integrity sha512-C0QL9bmgUXTSuf8nDeGrpMjtJG7tPUr8wG6/wxPbP62tGwCwQtdMSJYfESowmY4P3Hn593f+8OzNY5bckcu/LQ== + version "8.5.1" + resolved "https://registry.yarnpkg.com/@hapi/hoek/-/hoek-8.5.1.tgz#fde96064ca446dec8c55a8c2f130957b070c6e06" + integrity sha512-yN7kbciD87WzLGc5539Tn0sApjyiGHAJgKvG9W8C7O+6c7qmoQMfVs0W4bX17eqz6C78QJqqFrtgdK5EWf6Qow== "@hapi/joi@^15.0.0", "@hapi/joi@^15.0.3": version "15.1.1" @@ -1050,9 +1200,9 @@ "@hapi/topo" "3.x.x" "@hapi/joi@^16.1.7": - version "16.1.7" - resolved "https://registry.yarnpkg.com/@hapi/joi/-/joi-16.1.7.tgz#360857223a87bb1f5f67691537964c1b4908ed93" - integrity sha512-anaIgnZhNooG3LJLrTFzgGALTiO97zRA1UkvQHm9KxxoSiIzCozB3RCNCpDnfhTJD72QlrHA8nwGmNgpFFCIeg== + version "16.1.8" + resolved "https://registry.yarnpkg.com/@hapi/joi/-/joi-16.1.8.tgz#84c1f126269489871ad4e2decc786e0adef06839" + integrity sha512-wAsVvTPe+FwSrsAurNt5vkg3zo+TblvC5Bb1zMVK6SJzZqw9UrJnexxR+76cpePmtUZKHAPxcQ2Bf7oVHyahhg== dependencies: "@hapi/address" "^2.1.2" "@hapi/formula" "^1.2.0" @@ -1065,14 +1215,7 @@ resolved "https://registry.yarnpkg.com/@hapi/pinpoint/-/pinpoint-1.0.2.tgz#025b7a36dbbf4d35bf1acd071c26b20ef41e0d13" integrity sha512-dtXC/WkZBfC5vxscazuiJ6iq4j9oNx1SHknmIr8hofarpKUZKmlUVYVIhNVzIEgK5Wrc4GMHL5lZtt1uS2flmQ== -"@hapi/topo@3.x.x": - version "3.1.5" - resolved "https://registry.yarnpkg.com/@hapi/topo/-/topo-3.1.5.tgz#3baea17e456530edad69a75c3fc7cde97dd6d331" - integrity sha512-bi9m1jrui9LlvtVdLaHv0DqeOoe+I8dep+nEcTgW6XxJHL3xArQcilYz3tIp0cRC4gWlsVtABK7vNKg4jzEmAA== - dependencies: - "@hapi/hoek" "8.x.x" - -"@hapi/topo@^3.1.3": +"@hapi/topo@3.x.x", "@hapi/topo@^3.1.3": version "3.1.6" resolved "https://registry.yarnpkg.com/@hapi/topo/-/topo-3.1.6.tgz#68d935fa3eae7fdd5ab0d7f953f3205d8b2bfc29" integrity sha512-tAag0jEcjwH+P2quUfipd7liWCNX2F8NvYjQp2wtInsZxnMlypdw0FtAOLxtvvkO+GSRRbmNi8m/5y42PQJYCQ== @@ -1227,6 +1370,16 @@ "@types/istanbul-reports" "^1.1.1" "@types/yargs" "^13.0.0" +"@jest/types@^26.0.1": + version "26.0.1" + resolved "https://registry.yarnpkg.com/@jest/types/-/types-26.0.1.tgz#b78333fbd113fa7aec8d39de24f88de8686dac67" + integrity sha512-IbtjvqI9+eS1qFnOIEL7ggWmT+iK/U+Vde9cGWtYb/b6XgKb3X44ZAe/z9YZzoAAZ/E92m0DqrilF934IGNnQA== + dependencies: + "@types/istanbul-lib-coverage" "^2.0.0" + "@types/istanbul-reports" "^1.1.1" + "@types/yargs" "^15.0.0" + chalk "^4.0.0" + "@mrmlnc/readdir-enhanced@^2.2.1": version "2.2.1" resolved "https://registry.yarnpkg.com/@mrmlnc/readdir-enhanced/-/readdir-enhanced-2.2.1.tgz#524af240d1a360527b730475ecfa1344aa540dde" @@ -1410,23 +1563,28 @@ bs58check "^2.1.2" buffer "^5.2.1" -"@ts-tools/node@^1.0.0": - version "1.0.0" - resolved "https://registry.yarnpkg.com/@ts-tools/node/-/node-1.0.0.tgz#60d808e3f132a7f47b45658b71e7e2ba1fbe1735" - integrity sha512-KiVn0EweB00oztLhPOto2xyqeUtb+7FdGWsRvyVcTPh9J0+Xz31834OqBkQBXNLLHpLiva5CCKzJzbCSAoW+1w== - dependencies: - "@ts-tools/transpile" "^1.0.0" - source-map-support "^0.5.13" +"@tootallnate/once@1": + version "1.1.2" + resolved "https://registry.yarnpkg.com/@tootallnate/once/-/once-1.1.2.tgz#ccb91445360179a04e7fe6aff78c00ffc1eeaf82" + integrity sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw== -"@ts-tools/transpile@^1.0.0": - version "1.0.0" - resolved "https://registry.yarnpkg.com/@ts-tools/transpile/-/transpile-1.0.0.tgz#5c474e0a506b584e0f91bedfaf2b5df8670e73be" - integrity sha512-CQ20ZArMdERjIy8JQX+Lt3Lo2CTxya/JiASQLLIXu9HhVxfQPyU/YM9F8tUrCU0aacO2d4ngTRct2OqEjY7DLw== +"@ts-tools/node@^1.0.0": + version "1.1.3" + resolved "https://registry.yarnpkg.com/@ts-tools/node/-/node-1.1.3.tgz#714349c9239fe9c46344f5e149a3a8d5515f7913" + integrity sha512-1IERQg/QxnnUuGSLXDI9p4GQwE6kJ+uQiNQFepPDPLKoqbf8dRH58HaQzIYQznzzOxV0VrXSi/ej7NxRQ8KCYg== + dependencies: + "@ts-tools/transpile" "^2.0.0" + source-map-support "^0.5.16" + +"@ts-tools/transpile@^2.0.0": + version "2.0.0" + resolved "https://registry.yarnpkg.com/@ts-tools/transpile/-/transpile-2.0.0.tgz#619c3bad28d050d579e7d6b71016e129aad3741d" + integrity sha512-Vv9SlCOMPF926iXErWg63zexwkjqfz3eQrgvLnkoyT3g01LG9XPScSEnYzIKJKu2gV2l1TxBMEAXjP1nHn85AA== "@types/babel__core@^7.1.0": - version "7.1.3" - resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.1.3.tgz#e441ea7df63cd080dfcd02ab199e6d16a735fc30" - integrity sha512-8fBo0UR2CcwWxeX7WIIgJ7lXjasFxoYgRnFHUj+hRvKkpiBJbxhdAPTCY6/ZKM0uxANFVzt4yObSLuTiTnazDA== + version "7.1.7" + resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.1.7.tgz#1dacad8840364a57c98d0dd4855c6dd3752c6b89" + integrity sha512-RL62NqSFPCDK2FM1pSDH0scHpJvsXtZNiYlMB73DgPBaG1E38ZYVL+ei5EkWRbr+KC4YNiAUNBnRj+bgwpgjMw== dependencies: "@babel/parser" "^7.1.0" "@babel/types" "^7.0.0" @@ -1435,9 +1593,9 @@ "@types/babel__traverse" "*" "@types/babel__generator@*": - version "7.6.0" - resolved "https://registry.yarnpkg.com/@types/babel__generator/-/babel__generator-7.6.0.tgz#f1ec1c104d1bb463556ecb724018ab788d0c172a" - integrity sha512-c1mZUu4up5cp9KROs/QAw0gTeHrw/x7m52LcnvMxxOZ03DmLwPV0MlGmlgzV3cnSdjhJOZsj7E7FHeioai+egw== + version "7.6.1" + resolved "https://registry.yarnpkg.com/@types/babel__generator/-/babel__generator-7.6.1.tgz#4901767b397e8711aeb99df8d396d7ba7b7f0e04" + integrity sha512-bBKm+2VPJcMRVwNhxKu8W+5/zT7pwNEqeokFOmbvVSqGzFneNxYcEBro9Ac7/N9tlsaPYnZLK8J1LWKkMsLAew== dependencies: "@babel/types" "^7.0.0" @@ -1450,24 +1608,29 @@ "@babel/types" "^7.0.0" "@types/babel__traverse@*", "@types/babel__traverse@^7.0.6": - version "7.0.7" - resolved "https://registry.yarnpkg.com/@types/babel__traverse/-/babel__traverse-7.0.7.tgz#2496e9ff56196cc1429c72034e07eab6121b6f3f" - integrity sha512-CeBpmX1J8kWLcDEnI3Cl2Eo6RfbGvzUctA+CjZUhOKDFbLfcr7fc4usEqLNWetrlJd7RhAkyYe2czXop4fICpw== + version "7.0.11" + resolved "https://registry.yarnpkg.com/@types/babel__traverse/-/babel__traverse-7.0.11.tgz#1ae3010e8bf8851d324878b42acec71986486d18" + integrity sha512-ddHK5icION5U6q11+tV2f9Mo6CZVuT8GJKld2q9LqHSZbvLbH34Kcu2yFGckZut453+eQU6btIA3RihmnRgI+Q== dependencies: "@babel/types" "^7.3.0" "@types/body-parser@*": - version "1.17.1" - resolved "https://registry.yarnpkg.com/@types/body-parser/-/body-parser-1.17.1.tgz#18fcf61768fb5c30ccc508c21d6fd2e8b3bf7897" - integrity sha512-RoX2EZjMiFMjZh9lmYrwgoP9RTpAjSHiJxdp4oidAQVO02T7HER3xj9UKue5534ULWeqVEkujhWcyvUce+d68w== + version "1.19.0" + resolved "https://registry.yarnpkg.com/@types/body-parser/-/body-parser-1.19.0.tgz#0685b3c47eb3006ffed117cdd55164b61f80538f" + integrity sha512-W98JrE0j2K78swW4ukqMleo8R7h/pFETjM2DQ90MF6XK2i4LO4W3gQ71Lt4w3bfm2EvVSyWHplECvB5sK22yFQ== dependencies: "@types/connect" "*" "@types/node" "*" +"@types/color-name@^1.1.1": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@types/color-name/-/color-name-1.1.1.tgz#1c1261bbeaa10a8055bbc5d8ab84b7b2afc846a0" + integrity sha512-rr+OQyAjxze7GgWrSaJwydHStIhHq2lvY3BOC2Mj7KnzI7XK0Uw1TOOdI9lDoajEbSWLiYgoo4f1R51erQfhPQ== + "@types/connect@*": - version "3.4.32" - resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.32.tgz#aa0e9616b9435ccad02bc52b5b454ffc2c70ba28" - integrity sha512-4r8qa0quOvh7lGD0pre62CAb1oni1OO6ecJLGCezTmhQ8Fz50Arx9RUszryR8KlgK6avuSXvviL6yWyViQABOg== + version "3.4.33" + resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.33.tgz#31610c901eca573b8713c3330abc6e6b9f588546" + integrity sha512-2+FrkXY4zllzTNfJth7jOqEHC+enpLeGslEhpnTAkg21GkRrWV4SsAtqchtT4YS9/nODBU2/ZfsBY2X4J/dX7A== dependencies: "@types/node" "*" @@ -1489,11 +1652,12 @@ integrity sha512-EaObqwIvayI5a8dCzhFrjKzVwKLxjoG9T6Ppd5CEo07LRKfQ8Yokw54r5+Wq7FaBQ+yXRvQAYPrHwya1/UFt9g== "@types/express-serve-static-core@*": - version "4.16.9" - resolved "https://registry.yarnpkg.com/@types/express-serve-static-core/-/express-serve-static-core-4.16.9.tgz#69e00643b0819b024bdede95ced3ff239bb54558" - integrity sha512-GqpaVWR0DM8FnRUJYKlWgyARoBUAVfRIeVDZQKOttLFp5SmhhF9YFIYeTPwMd/AXfxlP7xVO2dj1fGu0Q+krKQ== + version "4.17.7" + resolved "https://registry.yarnpkg.com/@types/express-serve-static-core/-/express-serve-static-core-4.17.7.tgz#dfe61f870eb549dc6d7e12050901847c7d7e915b" + integrity sha512-EMgTj/DF9qpgLXyc+Btimg+XoH7A2liE8uKul8qSmMTHCeNYzydDKFdsJskDvw42UsesCnhO63dO0Grbj8J4Dw== dependencies: "@types/node" "*" + "@types/qs" "*" "@types/range-parser" "*" "@types/express-winston@^3.0.4": @@ -1506,12 +1670,13 @@ winston "^3.0.0" "@types/express@*", "@types/express@^4.17.1": - version "4.17.1" - resolved "https://registry.yarnpkg.com/@types/express/-/express-4.17.1.tgz#4cf7849ae3b47125a567dfee18bfca4254b88c5c" - integrity sha512-VfH/XCP0QbQk5B5puLqTLEeFgR8lfCJHZJKkInZ9mkYd+u8byX0kztXEQxEk4wZXJs8HI+7km2ALXjn4YKcX9w== + version "4.17.6" + resolved "https://registry.yarnpkg.com/@types/express/-/express-4.17.6.tgz#6bce49e49570507b86ea1b07b806f04697fac45e" + integrity sha512-n/mr9tZI83kd4azlPG5y997C/M4DNABK9yErhFM6hKdym4kkmd9j0vtsJyjFIwfRBxtrxZtAfGZCNRIBMFLK5w== dependencies: "@types/body-parser" "*" "@types/express-serve-static-core" "*" + "@types/qs" "*" "@types/serve-static" "*" "@types/glob@^7.1.1": @@ -1524,11 +1689,11 @@ "@types/node" "*" "@types/hapi__joi@^16.0.1": - version "16.0.1" - resolved "https://registry.yarnpkg.com/@types/hapi__joi/-/hapi__joi-16.0.1.tgz#ec227341ec7ce2091066cccebc3b14f6c527ba6b" - integrity sha512-U4I9Pfk4qH6TCXlg55qOc3F730QndZi86hGWlZHPHY7b3J+MCDIAO6EejbkaLWk7U15v+jn2J3GRVKD4ruhS2Q== + version "16.0.12" + resolved "https://registry.yarnpkg.com/@types/hapi__joi/-/hapi__joi-16.0.12.tgz#fb9113f17cf5764d6b3586ae9817d1606cc7c90c" + integrity sha512-xJYifuz59jXdWY5JMS15uvA3ycS3nQYOGqoIIE0+fwQ0qI3/4CxBc6RHsOTp6wk9M0NWEdpcTl02lOQOKMifbQ== -"@types/hoist-non-react-statics@^3.3.0": +"@types/hoist-non-react-statics@*", "@types/hoist-non-react-statics@^3.3.0": version "3.3.1" resolved "https://registry.yarnpkg.com/@types/hoist-non-react-statics/-/hoist-non-react-statics-3.3.1.tgz#1124aafe5118cb591977aeb1ceaaed1070eb039f" integrity sha512-iMIqiko6ooLrTh1joXodJK5X9xeEALT1kM5G3ZLhD3hszxBdIEd5C75U834D9mLcINgD4OyZf5uQXjkuYydWvA== @@ -1537,29 +1702,31 @@ hoist-non-react-statics "^3.3.0" "@types/istanbul-lib-coverage@*", "@types/istanbul-lib-coverage@^2.0.0": - version "2.0.1" - resolved "https://registry.yarnpkg.com/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.1.tgz#42995b446db9a48a11a07ec083499a860e9138ff" - integrity sha512-hRJD2ahnnpLgsj6KWMYSrmXkM3rm2Dl1qkx6IOFD5FnuNPXJIG5L0dhgKXCYTRMGzU4n0wImQ/xfmRc4POUFlg== + version "2.0.2" + resolved "https://registry.yarnpkg.com/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.2.tgz#79d7a78bad4219f4c03d6557a1c72d9ca6ba62d5" + integrity sha512-rsZg7eL+Xcxsxk2XlBt9KcG8nOp9iYdKCOikY9x2RFJCyOdNj4MKPQty0e8oZr29vVAzKXr1BmR+kZauti3o1w== "@types/istanbul-lib-report@*": - version "1.1.1" - resolved "https://registry.yarnpkg.com/@types/istanbul-lib-report/-/istanbul-lib-report-1.1.1.tgz#e5471e7fa33c61358dd38426189c037a58433b8c" - integrity sha512-3BUTyMzbZa2DtDI2BkERNC6jJw2Mr2Y0oGI7mRxYNBPxppbtEK1F66u3bKwU2g+wxwWI7PAoRpJnOY1grJqzHg== + version "3.0.0" + resolved "https://registry.yarnpkg.com/@types/istanbul-lib-report/-/istanbul-lib-report-3.0.0.tgz#c14c24f18ea8190c118ee7562b7ff99a36552686" + integrity sha512-plGgXAPfVKFoYfa9NpYDAkseG+g6Jr294RqeqcqDixSbU34MZVJRi/P+7Y8GDpzkEwLaGZZOpKIEmeVZNtKsrg== dependencies: "@types/istanbul-lib-coverage" "*" "@types/istanbul-reports@^1.1.1": - version "1.1.1" - resolved "https://registry.yarnpkg.com/@types/istanbul-reports/-/istanbul-reports-1.1.1.tgz#7a8cbf6a406f36c8add871625b278eaf0b0d255a" - integrity sha512-UpYjBi8xefVChsCoBpKShdxTllC9pwISirfoZsUa2AAdQg/Jd2KQGtSbw+ya7GPo7x/wAPlH6JBhKhAsXUEZNA== + version "1.1.2" + resolved "https://registry.yarnpkg.com/@types/istanbul-reports/-/istanbul-reports-1.1.2.tgz#e875cc689e47bce549ec81f3df5e6f6f11cfaeb2" + integrity sha512-P/W9yOX/3oPZSpaYOCQzGqgCQRXn0FFO/V8bWrCQs+wLmvVVxk6CRBXALEvNs9OHIatlnlFokfhuDo2ug01ciw== dependencies: "@types/istanbul-lib-coverage" "*" "@types/istanbul-lib-report" "*" "@types/jest-diff@*": - version "20.0.1" - resolved "https://registry.yarnpkg.com/@types/jest-diff/-/jest-diff-20.0.1.tgz#35cc15b9c4f30a18ef21852e255fdb02f6d59b89" - integrity sha512-yALhelO3i0hqZwhjtcr6dYyaLoCHbAMshwtj6cGxTvHZAKXHsYGdff6E8EPw3xLKY0ELUTQ69Q1rQiJENnccMA== + version "24.3.0" + resolved "https://registry.yarnpkg.com/@types/jest-diff/-/jest-diff-24.3.0.tgz#29e237a3d954babfe6e23cc59b57ecd8ca8d858d" + integrity sha512-vx1CRDeDUwQ0Pc7v+hS61O1ETA81kD04IMEC0hS1kPyVtHDdZrokAvpF7MT9VI/fVSzicelUZNCepDvhRV1PeA== + dependencies: + jest-diff "*" "@types/jest@24.0.18": version "24.0.18" @@ -1569,21 +1736,21 @@ "@types/jest-diff" "*" "@types/jest@^24.0.23": - version "24.0.23" - resolved "https://registry.yarnpkg.com/@types/jest/-/jest-24.0.23.tgz#046f8e2ade026fe831623e361a36b6fb9a4463e4" - integrity sha512-L7MBvwfNpe7yVPTXLn32df/EK+AMBFAFvZrRuArGs7npEWnlziUXK+5GMIUTI4NIuwok3XibsjXCs5HxviYXjg== + version "24.9.1" + resolved "https://registry.yarnpkg.com/@types/jest/-/jest-24.9.1.tgz#02baf9573c78f1b9974a5f36778b366aa77bd534" + integrity sha512-Fb38HkXSVA4L8fGKEZ6le5bB8r6MRWlOCZbVuWZcmOMSCd2wCYOwN1ibj8daIoV9naq7aaOZjrLCoCMptKU/4Q== dependencies: jest-diff "^24.3.0" "@types/joi@^14.3.3": - version "14.3.3" - resolved "https://registry.yarnpkg.com/@types/joi/-/joi-14.3.3.tgz#f251aa8150fc0b6a7ce9feab21802a28473de335" - integrity sha512-6gAT/UkIzYb7zZulAbcof3lFxpiD5EI6xBeTvkL1wYN12pnFQ+y/+xl9BvnVgxkmaIDN89xWhGZLD9CvuOtZ9g== + version "14.3.4" + resolved "https://registry.yarnpkg.com/@types/joi/-/joi-14.3.4.tgz#eed1e14cbb07716079c814138831a520a725a1e0" + integrity sha512-1TQNDJvIKlgYXGNIABfgFp9y0FziDpuGrd799Q5RcnsDu+krD+eeW/0Fs5PHARvWWFelOhIG2OPCo6KbadBM4A== "@types/json-schema@^7.0.3": - version "7.0.3" - resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.3.tgz#bdfd69d61e464dcc81b25159c270d75a73c1a636" - integrity sha512-Il2DtDVRGDcqjDtE+rF8iqg1CArehSK84HZJCT7AMITlyXRBpuPhqGLDQMowraqqu1coEaimg4ZOqggt6L6L+A== + version "7.0.4" + resolved "https://registry.yarnpkg.com/@types/json-schema/-/json-schema-7.0.4.tgz#38fd73ddfd9b55abb1e1b2ed578cb55bd7b7d339" + integrity sha512-8+KAKzEvSUdeo+kmqnKrqgeE+LcA0tjYWFY7RPProVYwnqDjukzO+3b6dLD56rYX5TdWejnEOLJYOIeh4CXKuA== "@types/json5@^0.0.29": version "0.0.29" @@ -1591,14 +1758,16 @@ integrity sha1-7ihweulOEdK4J7y+UnC86n8+ce4= "@types/logform@*": - version "1.2.0" - resolved "https://registry.yarnpkg.com/@types/logform/-/logform-1.2.0.tgz#4ead916c7eb1ee99d726bfa849b6a2ee5ea50e3e" - integrity sha512-E8cLzW+PmqHI//4HLR+ZvE3cyzqVjsncYBx1O14P07oVJj3ezhmiL/azlgkXKLFyCWAeKsPQdjHNg/NEhBF5Ow== + version "1.10.1" + resolved "https://registry.yarnpkg.com/@types/logform/-/logform-1.10.1.tgz#d7abe0cc8bdc0931fd0072f6a90b7f91cdbb3f4f" + integrity sha512-7PFeU3gNsaG80dNWIl9FafSCnc4oYRXlyJ4yM38i0hMuqJaIMGSARS16QKTKfN4nZmNkA2Yy1z3h1WkJxgGbmA== + dependencies: + logform "*" "@types/mime@*": - version "2.0.1" - resolved "https://registry.yarnpkg.com/@types/mime/-/mime-2.0.1.tgz#dc488842312a7f075149312905b5e3c0b054c79d" - integrity sha512-FwI9gX75FgVBJ7ywgnq/P7tw+/o1GUbtP0KzbtusLigAOgIgNISRK0ZPl4qertvXSIE8YbsVJueQ90cDt9YYyw== + version "2.0.2" + resolved "https://registry.yarnpkg.com/@types/mime/-/mime-2.0.2.tgz#857a118d8634c84bba7ae14088e4508490cd5da5" + integrity sha512-4kPlzbljFcsttWEq6aBW0OZe6BDajAmyvr2xknBG92tejQnvdGtT9+kXSZ580DqpxY9qG2xeQVF9Dq0ymUTo5Q== "@types/minimatch@*": version "3.0.3" @@ -1606,36 +1775,52 @@ integrity sha512-tHq6qdbT9U1IRSGf14CL0pUlULksvY9OZ+5eEgl1N7t+OA3tGvNpxJCzuKQlsNgCVwbAs670L1vcVQi8j9HjnA== "@types/node-fetch@^2.5.4": - version "2.5.4" - resolved "https://registry.yarnpkg.com/@types/node-fetch/-/node-fetch-2.5.4.tgz#5245b6d8841fc3a6208b82291119bc11c4e0ce44" - integrity sha512-Oz6id++2qAOFuOlE1j0ouk1dzl3mmI1+qINPNBhi9nt/gVOz0G+13Ao6qjhdF0Ys+eOkhu6JnFmt38bR3H0POQ== + version "2.5.7" + resolved "https://registry.yarnpkg.com/@types/node-fetch/-/node-fetch-2.5.7.tgz#20a2afffa882ab04d44ca786449a276f9f6bbf3c" + integrity sha512-o2WVNf5UhWRkxlf6eq+jMZDu7kjgpgJfl4xVNlvryc95O/6F2ld8ztKX+qu+Rjyet93WAWm5LjeX9H5FGkODvw== dependencies: "@types/node" "*" + form-data "^3.0.0" -"@types/node@*", "@types/node@12.7.12": - version "12.7.12" - resolved "https://registry.yarnpkg.com/@types/node/-/node-12.7.12.tgz#7c6c571cc2f3f3ac4a59a5f2bd48f5bdbc8653cc" - integrity sha512-KPYGmfD0/b1eXurQ59fXD1GBzhSQfz6/lKBxkaHX9dKTzjXbK68Zt7yGUxUsCS1jeTy/8aL+d9JEr+S54mpkWQ== +"@types/node@*": + version "14.0.5" + resolved "https://registry.yarnpkg.com/@types/node/-/node-14.0.5.tgz#3d03acd3b3414cf67faf999aed11682ed121f22b" + integrity sha512-90hiq6/VqtQgX8Sp0EzeIsv3r+ellbGj4URKj5j30tLlZvRUpnAe9YbYnjl3pJM93GyXU0tghHhvXHq+5rnCKA== "@types/node@10": - version "10.14.21" - resolved "https://registry.yarnpkg.com/@types/node/-/node-10.14.21.tgz#4a9db7ef1d1671c0015e632c5fa3d46c86c58c1e" - integrity sha512-nuFlRdBiqbF+PJIEVxm2jLFcQWN7q7iWEJGsBV4n7v1dbI9qXB8im2pMMKMCUZe092sQb5SQft2DHfuQGK5hqQ== + version "10.17.24" + resolved "https://registry.yarnpkg.com/@types/node/-/node-10.17.24.tgz#c57511e3a19c4b5e9692bb2995c40a3a52167944" + integrity sha512-5SCfvCxV74kzR3uWgTYiGxrd69TbT1I6+cMx1A5kEly/IVveJBimtAMlXiEyVFn5DvUFewQWxOOiJhlxeQwxgA== "@types/node@11.11.6": version "11.11.6" resolved "https://registry.yarnpkg.com/@types/node/-/node-11.11.6.tgz#df929d1bb2eee5afdda598a41930fe50b43eaa6a" integrity sha512-Exw4yUWMBXM3X+8oqzJNRqZSwUAaS4+7NdvHqQuFi/d+synz++xmX3QIf+BFqneW8N31R8Ky+sikfZUXq07ggQ== +"@types/node@12.7.12": + version "12.7.12" + resolved "https://registry.yarnpkg.com/@types/node/-/node-12.7.12.tgz#7c6c571cc2f3f3ac4a59a5f2bd48f5bdbc8653cc" + integrity sha512-KPYGmfD0/b1eXurQ59fXD1GBzhSQfz6/lKBxkaHX9dKTzjXbK68Zt7yGUxUsCS1jeTy/8aL+d9JEr+S54mpkWQ== + +"@types/parse-json@^4.0.0": + version "4.0.0" + resolved "https://registry.yarnpkg.com/@types/parse-json/-/parse-json-4.0.0.tgz#2f8bb441434d163b35fb8ffdccd7138927ffb8c0" + integrity sha512-//oorEZjL6sbPcKUaCdIGlIUeH26mgzimjBB77G6XRgnDl/L5wOnpyBGRe/Mmf5CVW3PwEBE1NjiMZ/ssFh4wA== + "@types/prop-types@*": version "15.7.3" resolved "https://registry.yarnpkg.com/@types/prop-types/-/prop-types-15.7.3.tgz#2ab0d5da2e5815f94b0b9d4b95d1e5f243ab2ca7" integrity sha512-KfRL3PuHmqQLOG+2tGpRO26Ctg+Cq1E01D2DMriKEATHgWLfeNDmq9e29Q9WIky0dQ3NPkd1mzYH8Lm936Z9qw== "@types/q@^1.5.1": - version "1.5.2" - resolved "https://registry.yarnpkg.com/@types/q/-/q-1.5.2.tgz#690a1475b84f2a884fd07cd797c00f5f31356ea8" - integrity sha512-ce5d3q03Ex0sy4R14722Rmt6MT07Ua+k4FwDfdcToYJcMKNtRVQvJ6JCAPdAmAnbRb6CsX6aYb9m96NGod9uTw== + version "1.5.4" + resolved "https://registry.yarnpkg.com/@types/q/-/q-1.5.4.tgz#15925414e0ad2cd765bfef58842f7e26a7accb24" + integrity sha512-1HcDas8SEj4z1Wc696tH56G8OlRaH/sqZOynNNB+HF0WOeXPaxTtbYzJY2oEfiUxjSKjhCKr+MvR7dCHcEelug== + +"@types/qs@*": + version "6.9.3" + resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.9.3.tgz#b755a0934564a200d3efdf88546ec93c369abd03" + integrity sha512-7s9EQWupR1fTc2pSMtXRQ9w9gLOcrJn+h7HOXw4evxyvVqMi4f+q7d2tnFe3ng3SNHjtK+0EzGMGFUQX4/AQRA== "@types/range-parser@*": version "1.2.3" @@ -1650,31 +1835,38 @@ "@types/react" "*" "@types/react-native@*": - version "0.60.19" - resolved "https://registry.yarnpkg.com/@types/react-native/-/react-native-0.60.19.tgz#4d58516f9e981c3f477ad48727331e31a0792aae" - integrity sha512-1Qq1EQn/bi7dnsdrZJu0f9MK18KZrEmLGMfw3V9Im5As4uwFUTCIkD4LnFJkfQtRvtJQN1cOQri6MTqT7d9fkg== + version "0.62.11" + resolved "https://registry.yarnpkg.com/@types/react-native/-/react-native-0.62.11.tgz#12a19fbdd9709bcf2646f677f5ac49d4d474252b" + integrity sha512-hRJSROGw+3JIp2w4WAAA+/4YM/HApeOQul7FVxOzLduaMKV/YZnm+1bfkS7hhKp9JqlbFNgqoRY/p2Ut7AD47g== dependencies: - "@types/prop-types" "*" "@types/react" "*" "@types/react-outside-click-handler@^1.2.0": - version "1.2.0" - resolved "https://registry.yarnpkg.com/@types/react-outside-click-handler/-/react-outside-click-handler-1.2.0.tgz#a7c5d7b39affb7a80c45029931efa031f1130820" - integrity sha512-yejuPUAzmlMmFuPGPYY1nxKj9NI7nn8qaCsyK1hte+Qy488+1d49+tVXDOP/N4mHFN+UjNt8HXQpIyVpRDI/YQ== + version "1.3.0" + resolved "https://registry.yarnpkg.com/@types/react-outside-click-handler/-/react-outside-click-handler-1.3.0.tgz#ccf0014032fc6ec286210f8a05d26a5c1f94cc96" + integrity sha512-BxQpd5GsbA9rjqLcM4lYp70VnvahgjMUeJ4OKi0A7QOsDLD2yUPswOVixtDpmvCu0PkRTfvMoStIR3gKC/L3XQ== dependencies: "@types/react" "*" "@types/react-redux@^7.1.4": - version "7.1.4" - resolved "https://registry.yarnpkg.com/@types/react-redux/-/react-redux-7.1.4.tgz#e0d02a073e730b8b58a6341bddca2ea692ff0bce" - integrity sha512-SUV/7d+4L7C1Db/D4pqASgN1V1U2HnDEhEol9lYpPSguS76xFboZzf5ha2hTz6v31cUewyC7WksMh1q8JxhebQ== + version "7.1.9" + resolved "https://registry.yarnpkg.com/@types/react-redux/-/react-redux-7.1.9.tgz#280c13565c9f13ceb727ec21e767abe0e9b4aec3" + integrity sha512-mpC0jqxhP4mhmOl3P4ipRsgTgbNofMRXJb08Ms6gekViLj61v1hOZEKWDCyWsdONr6EjEA6ZHXC446wdywDe0w== dependencies: "@types/hoist-non-react-statics" "^3.3.0" "@types/react" "*" hoist-non-react-statics "^3.3.0" redux "^4.0.0" -"@types/react@*", "@types/react@16.9.5": +"@types/react@*": + version "16.9.35" + resolved "https://registry.yarnpkg.com/@types/react/-/react-16.9.35.tgz#a0830d172e8aadd9bd41709ba2281a3124bbd368" + integrity sha512-q0n0SsWcGc8nDqH2GJfWQWUOmZSJhXV64CjVN5SvcNti3TdEaA3AH0D8DwNmMdzjMAC/78tB8nAZIlV8yTz+zQ== + dependencies: + "@types/prop-types" "*" + csstype "^2.2.0" + +"@types/react@16.9.5": version "16.9.5" resolved "https://registry.yarnpkg.com/@types/react/-/react-16.9.5.tgz#079dabd918b19b32118c25fd00a786bb6d0d5e51" integrity sha512-jQ12VMiFOWYlp+j66dghOWcmDDwhca0bnlcTxS4Qz/fh5gi6wpaZDthPEu/Gc/YlAuO87vbiUXL8qKstFvuOaA== @@ -1683,9 +1875,9 @@ csstype "^2.2.0" "@types/serve-static@*": - version "1.13.3" - resolved "https://registry.yarnpkg.com/@types/serve-static/-/serve-static-1.13.3.tgz#eb7e1c41c4468272557e897e9171ded5e2ded9d1" - integrity sha512-oprSwp094zOglVrXdlo/4bAHtKTAxX6VT8FOZlBKrmyLbNvE1zxZyJ6yikMVtHIvwP45+ZQGJn+FdXGKTozq0g== + version "1.13.4" + resolved "https://registry.yarnpkg.com/@types/serve-static/-/serve-static-1.13.4.tgz#6662a93583e5a6cabca1b23592eb91e12fa80e7c" + integrity sha512-jTDt0o/YbpNwZbQmE/+2e+lfjJEJJR0I3OFaKQKPWkASkCoW3i6fsUnqudSMcNAfbtmADGu8f4MV4q+GqULmug== dependencies: "@types/express-serve-static-core" "*" "@types/mime" "*" @@ -1696,10 +1888,11 @@ integrity sha512-l42BggppR6zLmpfU6fq9HEa2oGPEI8yrSPL3GITjfRInppYFahObbIQOQK3UGxEnyQpltZLaPe75046NOZQikw== "@types/styled-components@^4.1.19": - version "4.1.19" - resolved "https://registry.yarnpkg.com/@types/styled-components/-/styled-components-4.1.19.tgz#535b455d7744fda1608c605df82c0800eda61a09" - integrity sha512-nDkoTQ8ItcJiyEvTa24TwsIpIfNKCG+Lq0LvAwApOcjQ8OaeOOCg66YSPHBePHUh6RPt1LA8aEzRlgWhQPFqPg== + version "4.4.3" + resolved "https://registry.yarnpkg.com/@types/styled-components/-/styled-components-4.4.3.tgz#74dd00ad760845a98890a8539361d8afc32059de" + integrity sha512-U0udeNOZBfUkJycmGJwmzun0FBt11rZy08weVQmE2xfUNAbX8AGOEWxWna2d+qAUKxKgMlcG+TZT0+K2FfDcnQ== dependencies: + "@types/hoist-non-react-statics" "*" "@types/react" "*" "@types/react-native" "*" csstype "^2.2.0" @@ -1717,56 +1910,66 @@ winston "*" "@types/yargs-parser@*": - version "13.1.0" - resolved "https://registry.yarnpkg.com/@types/yargs-parser/-/yargs-parser-13.1.0.tgz#c563aa192f39350a1d18da36c5a8da382bbd8228" - integrity sha512-gCubfBUZ6KxzoibJ+SCUc/57Ms1jz5NjHe4+dI2krNmU5zCPAphyLJYyTOg06ueIyfj+SaCUqmzun7ImlxDcKg== + version "15.0.0" + resolved "https://registry.yarnpkg.com/@types/yargs-parser/-/yargs-parser-15.0.0.tgz#cb3f9f741869e20cce330ffbeb9271590483882d" + integrity sha512-FA/BWv8t8ZWJ+gEOnLLd8ygxH/2UFbAvgEonyfN6yWGLKc7zVjbpl2Y4CTjid9h2RfgPP6SEt6uHwEOply00yw== "@types/yargs@^13.0.0": - version "13.0.3" - resolved "https://registry.yarnpkg.com/@types/yargs/-/yargs-13.0.3.tgz#76482af3981d4412d65371a318f992d33464a380" - integrity sha512-K8/LfZq2duW33XW/tFwEAfnZlqIfVsoyRB3kfXdPXYhl0nfM8mmh7GS0jg7WrX2Dgq/0Ha/pR1PaR+BvmWwjiQ== + version "13.0.9" + resolved "https://registry.yarnpkg.com/@types/yargs/-/yargs-13.0.9.tgz#44028e974343c7afcf3960f1a2b1099c39a7b5e1" + integrity sha512-xrvhZ4DZewMDhoH1utLtOAwYQy60eYFoXeje30TzM3VOvQlBwQaEpKFq5m34k1wOw2AKIi2pwtiAjdmhvlBUzg== + dependencies: + "@types/yargs-parser" "*" + +"@types/yargs@^15.0.0": + version "15.0.5" + resolved "https://registry.yarnpkg.com/@types/yargs/-/yargs-15.0.5.tgz#947e9a6561483bdee9adffc983e91a6902af8b79" + integrity sha512-Dk/IDOPtOgubt/IaevIUbTgV7doaKkoorvOyYM2CMwuDyP89bekI7H4xLIwunNYiK9jhCkmc6pUrJk3cj2AB9w== dependencies: "@types/yargs-parser" "*" "@typescript-eslint/eslint-plugin@^2.2.0": - version "2.3.3" - resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-2.3.3.tgz#71e06c6887650301e02105c99b4c8f67454157e3" - integrity sha512-12cCbwu5PbQudkq2xCIS/QhB7hCMrsNPXK+vJtqy/zFqtzVkPRGy12O5Yy0gUK086f3VHV/P4a4R4CjMW853pA== + version "2.34.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/eslint-plugin/-/eslint-plugin-2.34.0.tgz#6f8ce8a46c7dea4a6f1d171d2bb8fbae6dac2be9" + integrity sha512-4zY3Z88rEE99+CNvTbXSyovv2z9PNOVffTWD2W8QF5s2prBQtwN2zadqERcrHpcR7O/+KMI3fcTAmUUhK/iQcQ== dependencies: - "@typescript-eslint/experimental-utils" "2.3.3" - eslint-utils "^1.4.2" + "@typescript-eslint/experimental-utils" "2.34.0" functional-red-black-tree "^1.0.1" - regexpp "^2.0.1" + regexpp "^3.0.0" tsutils "^3.17.1" -"@typescript-eslint/experimental-utils@2.3.3": - version "2.3.3" - resolved "https://registry.yarnpkg.com/@typescript-eslint/experimental-utils/-/experimental-utils-2.3.3.tgz#0685613063ff397cfa9209be2e6e81c0382a9b11" - integrity sha512-MQ4jKPMTU1ty4TigJCRKFPye2qyQdH8jzIIkceaHgecKFmkNS1hXPqKiZ+mOehkz6+HcN5Nuvwm+frmWZR9tdg== +"@typescript-eslint/experimental-utils@2.34.0": + version "2.34.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/experimental-utils/-/experimental-utils-2.34.0.tgz#d3524b644cdb40eebceca67f8cf3e4cc9c8f980f" + integrity sha512-eS6FTkq+wuMJ+sgtuNTtcqavWXqsflWcfBnlYhg/nS4aZ1leewkXGbvBhaapn1q6qf4M71bsR1tez5JTRMuqwA== dependencies: "@types/json-schema" "^7.0.3" - "@typescript-eslint/typescript-estree" "2.3.3" + "@typescript-eslint/typescript-estree" "2.34.0" eslint-scope "^5.0.0" + eslint-utils "^2.0.0" "@typescript-eslint/parser@^2.2.0": - version "2.3.3" - resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-2.3.3.tgz#af519d6572bdee3e9610e21c8362766858976bc1" - integrity sha512-+cV53HuYFeeyrNW8x/rgPmbVrzzp/rpRmwbJnNtwn4K8mroL1BdjxwQh7X9cUHp9rm4BBiEWmD3cSBjKG7d5mw== + version "2.34.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-2.34.0.tgz#50252630ca319685420e9a39ca05fe185a256bc8" + integrity sha512-03ilO0ucSD0EPTw2X4PntSIRFtDPWjrVq7C3/Z3VQHRC7+13YB55rcJI3Jt+YgeHbjUdJPcPa7b23rXCBokuyA== dependencies: "@types/eslint-visitor-keys" "^1.0.0" - "@typescript-eslint/experimental-utils" "2.3.3" - "@typescript-eslint/typescript-estree" "2.3.3" + "@typescript-eslint/experimental-utils" "2.34.0" + "@typescript-eslint/typescript-estree" "2.34.0" eslint-visitor-keys "^1.1.0" -"@typescript-eslint/typescript-estree@2.3.3": - version "2.3.3" - resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-2.3.3.tgz#be802220876bedfb80384cde1d46fe57ae7abf71" - integrity sha512-GkACs12Xp8d/STunNv/iSMYJFQrkrax9vuPZySlgSzoJJtw1cp6tbEw4qsLskQv6vloLrkFJHcTJ0a/yCB5cIA== +"@typescript-eslint/typescript-estree@2.34.0": + version "2.34.0" + resolved "https://registry.yarnpkg.com/@typescript-eslint/typescript-estree/-/typescript-estree-2.34.0.tgz#14aeb6353b39ef0732cc7f1b8285294937cf37d5" + integrity sha512-OMAr+nJWKdlVM9LOqCqh3pQQPwxHAN7Du8DR6dmwCrAmxtiXQnhHJ6tBNtf+cggqfo51SG/FCwnKhXCIM7hnVg== dependencies: - glob "^7.1.4" + debug "^4.1.1" + eslint-visitor-keys "^1.1.0" + glob "^7.1.6" is-glob "^4.0.1" - lodash.unescape "4.0.1" - semver "^6.3.0" + lodash "^4.17.15" + semver "^7.3.2" + tsutils "^3.17.1" "@webassemblyjs/ast@1.8.5": version "1.8.5" @@ -1925,9 +2128,9 @@ integrity sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ== abab@^2.0.0: - version "2.0.2" - resolved "https://registry.yarnpkg.com/abab/-/abab-2.0.2.tgz#a2fba1b122c69a85caa02d10f9270c7219709a9d" - integrity sha512-2scffjvioEmNz0OyDSLGWDfKCVwaKc6l9Pm9kOIREU13ClXZvHpg/nRL5xyjSSSLhOnXqft2HpsAzNEEA8cFFg== + version "2.0.3" + resolved "https://registry.yarnpkg.com/abab/-/abab-2.0.3.tgz#623e2075e02eb2d3f2475e49f99c91846467907a" + integrity sha512-tsFzPpcttalNjFBCFMqsKYQcWxxen1pgJR56by//QwvJc4/OUS3kPOOttx2tSIfjsylB0pYu7f5D3K1RCxUnUg== abbrev@1: version "1.1.1" @@ -1957,10 +2160,10 @@ acorn-globals@^4.1.0, acorn-globals@^4.3.0: acorn "^6.0.1" acorn-walk "^6.0.1" -acorn-jsx@^5.0.2: - version "5.0.2" - resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.0.2.tgz#84b68ea44b373c4f8686023a551f61a21b7c4a4f" - integrity sha512-tiNTrP1MP0QrChmD2DdupCr6HWSFeKVw5d/dHTu4Y7rkAkRhU/Dt7dphAfIUyxtHpl/eBVip5uTNSpQJHylpAw== +acorn-jsx@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.2.0.tgz#4c66069173d6fdd68ed85239fc256226182b2ebe" + integrity sha512-HiUX/+K2YpkpJ+SzBffkM/AQ2YE03S0U1kjTLVpoJdhZMOWy8qvXVN9JdLqv2QsaQ6MPYQIuNmwD8zOiYUofLQ== acorn-walk@^6.0.1: version "6.2.0" @@ -1968,19 +2171,19 @@ acorn-walk@^6.0.1: integrity sha512-7evsyfH1cLOCdAzZAd43Cic04yKydNx0cF+7tiA19p1XnLLPU4dpCQOqpjqwokFe//vS0QqfqqjCS2JkiIs0cA== acorn@^5.5.3: - version "5.7.3" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.3.tgz#67aa231bf8812974b85235a96771eb6bd07ea279" - integrity sha512-T/zvzYRfbVojPWahDsE5evJdHb3oJoQfFbsrKM7w5Zcs++Tr257tia3BmMP8XYVjp1S9RZXQMh7gao96BlqZOw== + version "5.7.4" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.7.4.tgz#3e8d8a9947d0599a1796d10225d7432f4a4acf5e" + integrity sha512-1D++VG7BhrtvQpNbBzovKNc1FLGGEE/oGe7b9xJm/RFHMBeUaUGpluV9RLjZa47YFdPcDAenEYuq9pQPcMdLJg== acorn@^6.0.1, acorn@^6.0.4, acorn@^6.2.1: - version "6.3.0" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.3.0.tgz#0087509119ffa4fc0a0041d1e93a417e68cb856e" - integrity sha512-/czfa8BwS88b9gWQVhc8eknunSA2DoJpJyTQkhheIf5E48u1N0R4q/YxxsAeqRrmK9TQ/uYfgLDfZo91UlANIA== + version "6.4.1" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-6.4.1.tgz#531e58ba3f51b9dacb9a6646ca4debf5b14ca474" + integrity sha512-ZVA9k326Nwrj3Cj9jlh3wGFutC2ZornPNARZwsNYqQYgN0EsV2d53w5RN/co65Ohn4sUAUtb1rSUAOD6XN9idA== -acorn@^7.0.0: - version "7.1.0" - resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.1.0.tgz#949d36f2c292535da602283586c2477c57eb2d6c" - integrity sha512-kL5CuoXA/dgxlBbVrflsflzQ3PAas7RYZB52NOm/6839iVYJgKMJ3cQJD+t2i5+qFa8h3MDpEOJiS64E8JLnSQ== +acorn@^7.1.1: + version "7.2.0" + resolved "https://registry.yarnpkg.com/acorn/-/acorn-7.2.0.tgz#17ea7e40d7c8640ff54a694c889c26f31704effe" + integrity sha512-apwXVmYVpQ34m/i71vrApRrRKCWQnZZF1+npOD0WV5xZFfwWOmKGQ2RWlfdy9vWITsenisM8M0Qeq8agcFHNiQ== address@1.1.2, address@^1.0.1: version "1.1.2" @@ -1998,7 +2201,14 @@ adjust-sourcemap-loader@2.0.0: object-path "0.11.4" regex-parser "2.2.10" -agent-base@4, agent-base@^4.3.0: +agent-base@6: + version "6.0.0" + resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-6.0.0.tgz#5d0101f19bbfaed39980b22ae866de153b93f09a" + integrity sha512-j1Q7cSCqN+AwrmDd+pzgqc0/NpC655x2bUf5ZjRIO77DcNBFmh+OgRNzF6OKdCC9RSCb19fGd99+bhXFdkRNqw== + dependencies: + debug "4" + +agent-base@^4.3.0: version "4.3.0" resolved "https://registry.yarnpkg.com/agent-base/-/agent-base-4.3.0.tgz#8165f01c436009bccad0b1d122f05ed770efc6ee" integrity sha512-salcGninV0nPrwpGNn4VTXBb1SOuXQBiqbrNXoeizJsHrsL6ERFM2Ne3JUSBWRE6aeNJI2ROP/WEEIDUiDe3cg== @@ -2031,12 +2241,12 @@ ajv-keywords@^3.1.0, ajv-keywords@^3.4.1: resolved "https://registry.yarnpkg.com/ajv-keywords/-/ajv-keywords-3.4.1.tgz#ef916e271c64ac12171fd8384eaae6b2345854da" integrity sha512-RO1ibKvd27e6FEShVFfPALuHI3WjSVNeK5FIsmme/LYRNxjKuNj+Dt7bucLa6NdSv3JcVTyMlm9kGR84z1XpaQ== -ajv@^6.1.0, ajv@^6.10.0, ajv@^6.10.2, ajv@^6.5.5: - version "6.10.2" - resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.10.2.tgz#d3cea04d6b017b2894ad69040fec8b623eb4bd52" - integrity sha512-TXtUUEYHuaTEbLZWIKUr5pmBuhDLy+8KYtPYdcV8qC+pOZL+NKqYwvWSRrVXHn+ZmRRAu8vJTAznH7Oag6RVRw== +ajv@^6.1.0, ajv@^6.10.0, ajv@^6.10.2, ajv@^6.12.0, ajv@^6.5.5: + version "6.12.2" + resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.2.tgz#c629c5eced17baf314437918d2da88c99d5958cd" + integrity sha512-k+V+hzjm5q/Mr8ef/1Y9goCmlsK4I6Sm74teeyGvFk1XrOsbsKLjEdrvny42CZ+a8sXbk8KWpY/bDwS+FLL2UQ== dependencies: - fast-deep-equal "^2.0.1" + fast-deep-equal "^3.1.1" fast-json-stable-stringify "^2.0.0" json-schema-traverse "^0.4.1" uri-js "^4.2.2" @@ -2069,11 +2279,11 @@ ansi-escapes@^3.0.0, ansi-escapes@^3.2.0: integrity sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ== ansi-escapes@^4.2.1: - version "4.2.1" - resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-4.2.1.tgz#4dccdb846c3eee10f6d64dea66273eab90c37228" - integrity sha512-Cg3ymMAdN10wOk/VYfLV7KCQyv7EDirJ64500sU7n9UlmioEtDuU5Gd+hj73hXSU/ex7tHJSssmyftDdkMLO8Q== + version "4.3.1" + resolved "https://registry.yarnpkg.com/ansi-escapes/-/ansi-escapes-4.3.1.tgz#a5c47cc43181f1f38ffd7076837700d395522a61" + integrity sha512-JWF7ocqNrp8u9oqpgV+wH5ftbt+cfvv+PTjOvKLT3AdYly/LmORARfEVT1iyjwN+4MqE5UmVKoAdIBqeoCHgLA== dependencies: - type-fest "^0.5.2" + type-fest "^0.11.0" ansi-html@0.0.7: version "0.0.7" @@ -2095,6 +2305,11 @@ ansi-regex@^4.0.0, ansi-regex@^4.1.0: resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.1.0.tgz#8b9f8f08cf1acb843756a839ca8c7e3168c51997" integrity sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg== +ansi-regex@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.0.tgz#388539f55179bf39339c81af30a654d69f87cb75" + integrity sha512-bY6fj56OUQ0hU1KjFNDQuJFezqKdrAyFdIevADiqrWHwSlbmBNMHp5ak2f40Pm8JTFyM2mqxkG6ngkHO11f/lg== + ansi-styles@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" @@ -2107,6 +2322,14 @@ ansi-styles@^3.2.0, ansi-styles@^3.2.1: dependencies: color-convert "^1.9.0" +ansi-styles@^4.0.0, ansi-styles@^4.1.0: + version "4.2.1" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.2.1.tgz#90ae75c424d008d2624c5bf29ead3177ebfcf359" + integrity sha512-9VGjrMsG1vePxcSweQsN20KY/c4zN0h9fLjqAbwbPfahM3t+NL+M9HC8xeXG2I8pX5NoamTGNuomEUFI7fcUjA== + dependencies: + "@types/color-name" "^1.1.1" + color-convert "^2.0.1" + anymatch@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-2.0.0.tgz#bcb24b4f37934d9aa7ac17b4adaf89e7c76ef2eb" @@ -2115,6 +2338,14 @@ anymatch@^2.0.0: micromatch "^3.1.4" normalize-path "^2.1.1" +anymatch@~3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/anymatch/-/anymatch-3.1.1.tgz#c55ecf02185e2469259399310c173ce31233b142" + integrity sha512-mM8522psRCqzV+6LhomX5wgp25YVibjh8Wj23I5RPkPppSVSjyKD2A2mBJmWGa+KN7f2D6LNh9jkBCeyLktzjg== + dependencies: + normalize-path "^3.0.0" + picomatch "^2.0.4" + aproba@^1.0.3, aproba@^1.1.1: version "1.2.0" resolved "https://registry.yarnpkg.com/aproba/-/aproba-1.2.0.tgz#6802e6264efd18c790a1b0d517f0f2627bf2c94a" @@ -2129,9 +2360,9 @@ are-we-there-yet@~1.1.2: readable-stream "^2.0.6" arg@^4.1.0: - version "4.1.1" - resolved "https://registry.yarnpkg.com/arg/-/arg-4.1.1.tgz#485f8e7c390ce4c5f78257dbea80d4be11feda4c" - integrity sha512-SlmP3fEA88MBv0PypnXZ8ZfJhwmDeIE3SP71j37AiXQBXYosPV0x6uISAaHYSlSVhmHOVkomen0tbGk6Anlebw== + version "4.1.3" + resolved "https://registry.yarnpkg.com/arg/-/arg-4.1.3.tgz#269fc7ad5b8e42cb63c896d5666017261c144089" + integrity sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA== argparse@^1.0.7: version "1.0.10" @@ -2188,13 +2419,14 @@ array-flatten@^2.1.0: resolved "https://registry.yarnpkg.com/array-flatten/-/array-flatten-2.1.2.tgz#24ef80a28c1a893617e2149b0c6d0d788293b099" integrity sha512-hNfzcOV8W4NdualtqBFPyVO+54DSJuZGY9qT4pRroB6S9e3iiido2ISIC5h9R2sPJ8H3FHCIiEnsv1lPXO3KtQ== -array-includes@^3.0.3: - version "3.0.3" - resolved "https://registry.yarnpkg.com/array-includes/-/array-includes-3.0.3.tgz#184b48f62d92d7452bb31b323165c7f8bd02266d" - integrity sha1-GEtI9i2S10UrsxsyMWXH+L0CJm0= +array-includes@^3.0.3, array-includes@^3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/array-includes/-/array-includes-3.1.1.tgz#cdd67e6852bdf9c1215460786732255ed2459348" + integrity sha512-c2VXaCHl7zPsvpkFsw4nxvFie4fh1ur9bpcgsVkIjqn0H/Xwdg+7fv3n2r/isyS8EBj5b06M9kHyZuIr4El6WQ== dependencies: - define-properties "^1.1.2" - es-abstract "^1.7.0" + define-properties "^1.1.3" + es-abstract "^1.17.0" + is-string "^1.0.5" array-union@^1.0.1: version "1.0.2" @@ -2203,7 +2435,7 @@ array-union@^1.0.1: dependencies: array-uniq "^1.0.1" -array-uniq@^1.0.1, array-uniq@^1.0.2: +array-uniq@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/array-uniq/-/array-uniq-1.0.3.tgz#af6ac877a25cc7f74e058894753858dfdb24fdb6" integrity sha1-r2rId6Jcx/dOBYiUdThY39sk/bY= @@ -2214,12 +2446,12 @@ array-unique@^0.3.2: integrity sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg= array.prototype.find@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/array.prototype.find/-/array.prototype.find-2.1.0.tgz#630f2eaf70a39e608ac3573e45cf8ccd0ede9ad7" - integrity sha512-Wn41+K1yuO5p7wRZDl7890c3xvv5UBrfVXTVIe28rSQb6LS0fZMDrQB6PAcxQFRFy6vJTLDc3A2+3CjQdzVKRg== + version "2.1.1" + resolved "https://registry.yarnpkg.com/array.prototype.find/-/array.prototype.find-2.1.1.tgz#3baca26108ca7affb08db06bf0be6cb3115a969c" + integrity sha512-mi+MYNJYLTx2eNYy+Yh6raoQacCsNeeMUaspFPh9Y141lFSsWxxB8V9mM2ye+eqiRs917J6/pJ4M9ZPzenWckA== dependencies: define-properties "^1.1.3" - es-abstract "^1.13.0" + es-abstract "^1.17.4" arrify@^1.0.1: version "1.0.1" @@ -2302,12 +2534,7 @@ async-limiter@~1.0.0: resolved "https://registry.yarnpkg.com/async-limiter/-/async-limiter-1.0.1.tgz#dd379e94f0db8310b08291f9d64c3209766617fd" integrity sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ== -async@^1.5.2: - version "1.5.2" - resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a" - integrity sha1-7GphrlZIDAw8skHJVhjiCJL5Zyo= - -async@^2.6.1: +async@^2.6.1, async@^2.6.2: version "2.6.3" resolved "https://registry.yarnpkg.com/async/-/async-2.6.3.tgz#d72625e2344a3656e3a3ad4fa749fa83299d82ff" integrity sha512-zflvls11DCy+dQWzTW2dzuilv8Z5X/pjfmZOWba6TNIVDm+2UDaJmXSOXlasHKfNBs8oo3M0aT50fDEWfKZjXg== @@ -2319,23 +2546,23 @@ asynckit@^0.4.0: resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" integrity sha1-x57Zf380y48robyXkLzDZkdLS3k= -atob@^2.1.1: +atob@^2.1.2: version "2.1.2" resolved "https://registry.yarnpkg.com/atob/-/atob-2.1.2.tgz#6d9517eb9e030d2436666651e86bd9f6f13533c9" integrity sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg== autoprefixer@^9.6.1: - version "9.6.4" - resolved "https://registry.yarnpkg.com/autoprefixer/-/autoprefixer-9.6.4.tgz#e6453be47af316b2923eaeaed87860f52ad4b7eb" - integrity sha512-Koz2cJU9dKOxG8P1f8uVaBntOv9lP4yz9ffWvWaicv9gHBPhpQB22nGijwd8gqW9CNT+UdkbQOQNLVI8jN1ZfQ== + version "9.8.0" + resolved "https://registry.yarnpkg.com/autoprefixer/-/autoprefixer-9.8.0.tgz#68e2d2bef7ba4c3a65436f662d0a56a741e56511" + integrity sha512-D96ZiIHXbDmU02dBaemyAg53ez+6F5yZmapmgKcjm35yEe1uVDYI8hGW3VYoGRaG290ZFf91YxHrR518vC0u/A== dependencies: - browserslist "^4.7.0" - caniuse-lite "^1.0.30000998" + browserslist "^4.12.0" + caniuse-lite "^1.0.30001061" chalk "^2.4.2" normalize-range "^0.1.2" num2fraction "^1.2.2" - postcss "^7.0.18" - postcss-value-parser "^4.0.2" + postcss "^7.0.30" + postcss-value-parser "^4.1.0" aws-sign2@~0.7.0: version "0.7.0" @@ -2343,24 +2570,21 @@ aws-sign2@~0.7.0: integrity sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg= aws4@^1.8.0: - version "1.8.0" - resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.8.0.tgz#f0e003d9ca9e7f59c7a508945d7b2ef9a04a542f" - integrity sha512-ReZxvNHIOv88FlT7rxcXIIC0fPt4KZqZbOlivyWtXLt8ESx84zd3kMC6iK5jVeS2qt+g7ftS7ye4fi06X5rtRQ== + version "1.10.0" + resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.10.0.tgz#a17b3a8ea811060e74d47d306122400ad4497ae2" + integrity sha512-3YDiu347mtVtjpyV3u5kVqQLP242c06zwDOgpeRnybmXlYYsLbtTrUBUm8i8srONt+FWobl5aibnU1030PeeuA== axios@^0.19.0: - version "0.19.0" - resolved "https://registry.yarnpkg.com/axios/-/axios-0.19.0.tgz#8e09bff3d9122e133f7b8101c8fbdd00ed3d2ab8" - integrity sha512-1uvKqKQta3KBxIz14F2v06AEHZ/dIoeKfbTRkK1E5oqjDnuEerLmYTgJB5AiQZHJcljpg1TuRzdjDR06qNk0DQ== + version "0.19.2" + resolved "https://registry.yarnpkg.com/axios/-/axios-0.19.2.tgz#3ea36c5d8818d0d5f8a8a97a6d36b86cdc00cb27" + integrity sha512-fjgm5MvRHLhx+osE2xoekY70AhARk3a6hkN+3Io1jc00jtquGvxYlKlsFUhmUET0V5te6CcZI7lcv2Ym61mjHA== dependencies: follow-redirects "1.5.10" - is-buffer "^2.0.2" axobject-query@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/axobject-query/-/axobject-query-2.0.2.tgz#ea187abe5b9002b377f925d8bf7d1c561adf38f9" - integrity sha512-MCeek8ZH7hKyO1rWUbKNQBbl4l2eY0ntk7OGi+q0RlafrCnfPxC06WZA+uebCfmYp4mNU9jRBP1AhGyf8+W3ww== - dependencies: - ast-types-flow "0.0.7" + version "2.1.2" + resolved "https://registry.yarnpkg.com/axobject-query/-/axobject-query-2.1.2.tgz#2bdffc0371e643e5f03ba99065d5179b9ca79799" + integrity sha512-ICt34ZmrVt8UQnvPl6TVyDTkmhXmAyAT4Jh5ugfGUX4MOrZ+U/ZY6/sdylRw3qGNr9Ub5AJsaHeDMzNLehRdOQ== babel-code-frame@^6.22.0: version "6.26.0" @@ -2413,10 +2637,10 @@ babel-loader@8.0.6: mkdirp "^0.5.1" pify "^4.0.1" -babel-plugin-dynamic-import-node@2.3.0, babel-plugin-dynamic-import-node@^2.3.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/babel-plugin-dynamic-import-node/-/babel-plugin-dynamic-import-node-2.3.0.tgz#f00f507bdaa3c3e3ff6e7e5e98d90a7acab96f7f" - integrity sha512-o6qFkpeQEBxcqt0XYlWzAVxNCSCZdUgcR8IRlhD/8DylxjjO4foPcvTW0GGKa/cVt3rvxZ7o5ippJ+/0nvLhlQ== +babel-plugin-dynamic-import-node@^2.3.3: + version "2.3.3" + resolved "https://registry.yarnpkg.com/babel-plugin-dynamic-import-node/-/babel-plugin-dynamic-import-node-2.3.3.tgz#84fda19c976ec5c6defef57f9427b3def66e17a3" + integrity sha512-jZVI+s9Zg3IqA/kdi0i6UDCybUI3aSBLnglhYbSSjKlV7yF1F/5LWv8MakQmvYpnbJDS6fcBL2KzHSxNCMtWSQ== dependencies: object.assign "^4.1.0" @@ -2437,24 +2661,24 @@ babel-plugin-jest-hoist@^24.9.0: dependencies: "@types/babel__traverse" "^7.0.6" -babel-plugin-macros@2.6.1: - version "2.6.1" - resolved "https://registry.yarnpkg.com/babel-plugin-macros/-/babel-plugin-macros-2.6.1.tgz#41f7ead616fc36f6a93180e89697f69f51671181" - integrity sha512-6W2nwiXme6j1n2erPOnmRiWfObUhWH7Qw1LMi9XZy8cj+KtESu3T6asZvtk5bMQQjX8te35o7CFueiSdL/2NmQ== +babel-plugin-macros@2.8.0: + version "2.8.0" + resolved "https://registry.yarnpkg.com/babel-plugin-macros/-/babel-plugin-macros-2.8.0.tgz#0f958a7cc6556b1e65344465d99111a1e5e10138" + integrity sha512-SEP5kJpfGYqYKpBrj5XU3ahw5p5GOHJ0U5ssOSQ/WBVdwkD2Dzlce95exQTs3jOVWPPKLBN2rlEWkCK7dSmLvg== dependencies: - "@babel/runtime" "^7.4.2" - cosmiconfig "^5.2.0" - resolve "^1.10.0" + "@babel/runtime" "^7.7.2" + cosmiconfig "^6.0.0" + resolve "^1.12.0" babel-plugin-named-asset-import@^0.3.4: - version "0.3.4" - resolved "https://registry.yarnpkg.com/babel-plugin-named-asset-import/-/babel-plugin-named-asset-import-0.3.4.tgz#4a8fc30e9a3e2b1f5ed36883386ab2d84e1089bd" - integrity sha512-S6d+tEzc5Af1tKIMbsf2QirCcPdQ+mKUCY2H1nJj1DyA1ShwpsoxEOAwbWsG5gcXNV/olpvQd9vrUWRx4bnhpw== + version "0.3.6" + resolved "https://registry.yarnpkg.com/babel-plugin-named-asset-import/-/babel-plugin-named-asset-import-0.3.6.tgz#c9750a1b38d85112c9e166bf3ef7c5dbc605f4be" + integrity sha512-1aGDUfL1qOOIoqk9QKGIo2lANk+C7ko/fqH0uIyC71x3PEGz0uVP8ISgfEsFuG+FKmjHTvFK/nNM8dowpmUxLA== "babel-plugin-styled-components@>= 1": - version "1.10.6" - resolved "https://registry.yarnpkg.com/babel-plugin-styled-components/-/babel-plugin-styled-components-1.10.6.tgz#f8782953751115faf09a9f92431436912c34006b" - integrity sha512-gyQj/Zf1kQti66100PhrCRjI5ldjaze9O0M3emXRPAN80Zsf8+e1thpTpaXJXVHXtaM4/+dJEgZHyS9Its+8SA== + version "1.10.7" + resolved "https://registry.yarnpkg.com/babel-plugin-styled-components/-/babel-plugin-styled-components-1.10.7.tgz#3494e77914e9989b33cc2d7b3b29527a949d635c" + integrity sha512-MBMHGcIA22996n9hZRf/UJLVVgkEOITuR2SvjHLb5dSTUyR4ZRGn+ngITapes36FI3WLxZHfRhkA1ffHxihOrg== dependencies: "@babel/helper-annotate-as-pure" "^7.0.0" "@babel/helper-module-imports" "^7.0.0" @@ -2493,25 +2717,24 @@ babel-preset-jest@^24.9.0: babel-plugin-jest-hoist "^24.9.0" babel-preset-react-app@^9.0.2: - version "9.0.2" - resolved "https://registry.yarnpkg.com/babel-preset-react-app/-/babel-preset-react-app-9.0.2.tgz#247d37e883d6d6f4b4691e5f23711bb2dd80567d" - integrity sha512-aXD+CTH8Chn8sNJr4tO/trWKqe5sSE4hdO76j9fhVezJSzmpWYWUSc5JoPmdSxADwef5kQFNGKXd433vvkd2VQ== + version "9.1.2" + resolved "https://registry.yarnpkg.com/babel-preset-react-app/-/babel-preset-react-app-9.1.2.tgz#54775d976588a8a6d1a99201a702befecaf48030" + integrity sha512-k58RtQOKH21NyKtzptoAvtAODuAJJs3ZhqBMl456/GnXEQ/0La92pNmwgWoMn5pBTrsvk3YYXdY7zpY4e3UIxA== dependencies: - "@babel/core" "7.6.0" - "@babel/plugin-proposal-class-properties" "7.5.5" - "@babel/plugin-proposal-decorators" "7.6.0" - "@babel/plugin-proposal-object-rest-spread" "7.5.5" - "@babel/plugin-syntax-dynamic-import" "7.2.0" - "@babel/plugin-transform-destructuring" "7.6.0" - "@babel/plugin-transform-flow-strip-types" "7.4.4" - "@babel/plugin-transform-react-display-name" "7.2.0" - "@babel/plugin-transform-runtime" "7.6.0" - "@babel/preset-env" "7.6.0" - "@babel/preset-react" "7.0.0" - "@babel/preset-typescript" "7.6.0" - "@babel/runtime" "7.6.0" - babel-plugin-dynamic-import-node "2.3.0" - babel-plugin-macros "2.6.1" + "@babel/core" "7.9.0" + "@babel/plugin-proposal-class-properties" "7.8.3" + "@babel/plugin-proposal-decorators" "7.8.3" + "@babel/plugin-proposal-nullish-coalescing-operator" "7.8.3" + "@babel/plugin-proposal-numeric-separator" "7.8.3" + "@babel/plugin-proposal-optional-chaining" "7.9.0" + "@babel/plugin-transform-flow-strip-types" "7.9.0" + "@babel/plugin-transform-react-display-name" "7.8.3" + "@babel/plugin-transform-runtime" "7.9.0" + "@babel/preset-env" "7.9.0" + "@babel/preset-react" "7.9.1" + "@babel/preset-typescript" "7.9.0" + "@babel/runtime" "7.9.0" + babel-plugin-macros "2.8.0" babel-plugin-transform-react-remove-prop-types "0.4.24" babel-runtime@^6.26.0: @@ -2533,9 +2756,9 @@ balanced-match@^1.0.0: integrity sha1-ibTRmasr7kneFk6gK4nORi1xt2c= base-x@^3.0.2: - version "3.0.7" - resolved "https://registry.yarnpkg.com/base-x/-/base-x-3.0.7.tgz#1c5a7fafe8f66b4114063e8da102799d4e7c408f" - integrity sha512-zAKJGuQPihXW22fkrfOclUUZXM2g92z5GzlSMHxhO6r6Qj+Nm0ccaGNBzDZojzwOMkpjAv4J0fOv1U4go+a4iw== + version "3.0.8" + resolved "https://registry.yarnpkg.com/base-x/-/base-x-3.0.8.tgz#1e1106c2537f0162e8b52474a557ebb09000018d" + integrity sha512-Rl/1AWP4J/zRrk54hhlxH4drNxPJXYUaKffODVI53/dAsV4t9fBxyxYKAVPU1XBHxYwOWP9h9H0hM2MVw4YfJA== dependencies: safe-buffer "^5.0.1" @@ -2589,6 +2812,18 @@ binary-extensions@^1.0.0: resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-1.13.1.tgz#598afe54755b2868a5330d2aff9d4ebb53209b65" integrity sha512-Un7MIEDdUC5gNpcGDV97op1Ywk748MpHcFTHoYs6qnj1Z3j7I53VG3nwZhKzoBZmbdRNnb6WRdFlwl7tSDuZGw== +binary-extensions@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-2.0.0.tgz#23c0df14f6a88077f5f986c0d167ec03c3d5537c" + integrity sha512-Phlt0plgpIIBOGTT/ehfFnbNlfsDEiqmzE2KRXoX1bLIlir4X/MR+zSyBEkL05ffWgnRSf/DXv+WrUAVr93/ow== + +bindings@^1.5.0: + version "1.5.0" + resolved "https://registry.yarnpkg.com/bindings/-/bindings-1.5.0.tgz#10353c9e945334bc0511a6d90b38fbc7c9c504df" + integrity sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ== + dependencies: + file-uri-to-path "1.0.0" + bintrees@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/bintrees/-/bintrees-1.0.1.tgz#0e655c9b9c2435eaab68bf4027226d2b55a34524" @@ -2617,14 +2852,19 @@ block-stream@*: inherits "~2.0.0" bluebird@^3.5.5: - version "3.7.0" - resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.7.0.tgz#56a6a886e03f6ae577cffedeb524f8f2450293cf" - integrity sha512-aBQ1FxIa7kSWCcmKHlcHFlT2jt6J/l4FzC7KcPELkOJOsPOb/bccdhmIrKDfXhwFrmc7vDoDrrepFvGqjyXGJg== + version "3.7.2" + resolved "https://registry.yarnpkg.com/bluebird/-/bluebird-3.7.2.tgz#9f229c15be272454ffa973ace0dbee79a1b0c36f" + integrity sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg== -bn.js@^4.0.0, bn.js@^4.1.0, bn.js@^4.1.1, bn.js@^4.4.0: - version "4.11.8" - resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.11.8.tgz#2cde09eb5ee341f484746bb0309b3253b1b1442f" - integrity sha512-ItfYfPLkWHUjckQCk8xC+LwxgK8NYcXywGigJgSwOP8Y2iyWT4f2vsZnoOXTTbo+o5yXmIUJ4gn5538SO5S3gA== +bn.js@^4.0.0, bn.js@^4.1.0, bn.js@^4.4.0: + version "4.11.9" + resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.11.9.tgz#26d556829458f9d1e81fc48952493d0ba3507828" + integrity sha512-E6QoYqCKZfgatHTdHzs1RRKP7ip4vvm+EyRUeE2RF0NblwVvb0p6jSVeNTOFxPn26QXN2o6SMfNxKp6kU8zQaw== + +bn.js@^5.1.1: + version "5.1.2" + resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-5.1.2.tgz#c9686902d3c9a27729f43ab10f9d79c2004da7b0" + integrity sha512-40rZaf3bUNKTVYu9sIeeEGOg7g14Yvnj9kH7b50EiwX0Q7A6umbvfI5tvHaOERH0XigqKkfLkFQxzb4e6CIXnA== body-parser@1.19.0, body-parser@^1.19.0: version "1.19.0" @@ -2696,7 +2936,7 @@ braces@^2.3.1, braces@^2.3.2: split-string "^3.0.2" to-regex "^3.0.1" -braces@^3.0.1: +braces@^3.0.1, braces@~3.0.2: version "3.0.2" resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz#3454e1a462ee8d599e236df336cd9ea4f8afe107" integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A== @@ -2708,10 +2948,10 @@ brorand@^1.0.1: resolved "https://registry.yarnpkg.com/brorand/-/brorand-1.1.0.tgz#12c25efe40a45e3c323eb8675a0a0ce57b22371f" integrity sha1-EsJe/kCkXjwyPrhnWgoM5XsiNx8= -browser-process-hrtime@^0.1.2: - version "0.1.3" - resolved "https://registry.yarnpkg.com/browser-process-hrtime/-/browser-process-hrtime-0.1.3.tgz#616f00faef1df7ec1b5bf9cfe2bdc3170f26c7b4" - integrity sha512-bRFnI4NnjO6cnyLmOV/7PVoDEMJChlcfN0z4s1YMBY989/SvlfMI1lgCnkFUs53e9gQF+w7qu7XdllSTiSl8Aw== +browser-process-hrtime@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/browser-process-hrtime/-/browser-process-hrtime-1.0.0.tgz#3c9b4b7d782c8121e56f10106d84c0d0ffc94626" + integrity sha512-9o5UecI3GhkpM6DrXr69PblIuWxPKk9Y0jHBRhdocZ2y7YECBFCsHm79Pr3OyR2AvjhDkabFJaDJMYRazHgsow== browser-resolve@^1.11.3: version "1.11.3" @@ -2751,7 +2991,7 @@ browserify-des@^1.0.0: inherits "^2.0.1" safe-buffer "^5.1.2" -browserify-rsa@^4.0.0: +browserify-rsa@^4.0.0, browserify-rsa@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/browserify-rsa/-/browserify-rsa-4.0.1.tgz#21e0abfaf6f2029cf2fafb133567a701d4135524" integrity sha1-IeCr+vbyApzy+vsTNWenAdQTVSQ= @@ -2760,17 +3000,19 @@ browserify-rsa@^4.0.0: randombytes "^2.0.1" browserify-sign@^4.0.0: - version "4.0.4" - resolved "https://registry.yarnpkg.com/browserify-sign/-/browserify-sign-4.0.4.tgz#aa4eb68e5d7b658baa6bf6a57e630cbd7a93d298" - integrity sha1-qk62jl17ZYuqa/alfmMMvXqT0pg= + version "4.2.0" + resolved "https://registry.yarnpkg.com/browserify-sign/-/browserify-sign-4.2.0.tgz#545d0b1b07e6b2c99211082bf1b12cce7a0b0e11" + integrity sha512-hEZC1KEeYuoHRqhGhTy6gWrpJA3ZDjFWv0DE61643ZnOXAKJb3u7yWcrU0mMc9SwAqK1n7myPGndkp0dFG7NFA== dependencies: - bn.js "^4.1.1" - browserify-rsa "^4.0.0" - create-hash "^1.1.0" - create-hmac "^1.1.2" - elliptic "^6.0.0" - inherits "^2.0.1" - parse-asn1 "^5.0.0" + bn.js "^5.1.1" + browserify-rsa "^4.0.1" + create-hash "^1.2.0" + create-hmac "^1.1.7" + elliptic "^6.5.2" + inherits "^2.0.4" + parse-asn1 "^5.1.5" + readable-stream "^3.6.0" + safe-buffer "^5.2.0" browserify-zlib@^0.2.0: version "0.2.0" @@ -2779,7 +3021,7 @@ browserify-zlib@^0.2.0: dependencies: pako "~1.0.5" -browserslist@4.7.0, browserslist@^4.0.0, browserslist@^4.1.1, browserslist@^4.6.0, browserslist@^4.6.4, browserslist@^4.6.6, browserslist@^4.7.0: +browserslist@4.7.0: version "4.7.0" resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.7.0.tgz#9ee89225ffc07db03409f2fee524dc8227458a17" integrity sha512-9rGNDtnj+HaahxiVV38Gn8n8Lr8REKsel68v1sPFfIGEK6uSXTY3h9acgiT1dZVtOOUtifo/Dn8daDQ5dUgVsA== @@ -2788,6 +3030,16 @@ browserslist@4.7.0, browserslist@^4.0.0, browserslist@^4.1.1, browserslist@^4.6. electron-to-chromium "^1.3.247" node-releases "^1.1.29" +browserslist@^4.0.0, browserslist@^4.1.1, browserslist@^4.11.1, browserslist@^4.12.0, browserslist@^4.6.4, browserslist@^4.8.5, browserslist@^4.9.1: + version "4.12.0" + resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.12.0.tgz#06c6d5715a1ede6c51fc39ff67fd647f740b656d" + integrity sha512-UH2GkcEDSI0k/lRkuDSzFl9ZZ87skSy9w2XAn1MsZnL+4c4rqbBd3e82UWHbYDpztABrPBhZsTEeuxVfHppqDg== + dependencies: + caniuse-lite "^1.0.30001043" + electron-to-chromium "^1.3.413" + node-releases "^1.1.53" + pkg-up "^2.0.0" + bs-logger@0.x: version "0.2.6" resolved "https://registry.yarnpkg.com/bs-logger/-/bs-logger-0.2.6.tgz#eb7d365307a72cf974cc6cda76b68354ad336bd8" @@ -2811,13 +3063,18 @@ bs58check@^2.1.2: create-hash "^1.1.0" safe-buffer "^5.1.2" -bser@^2.0.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/bser/-/bser-2.1.0.tgz#65fc784bf7f87c009b973c12db6546902fa9c7b5" - integrity sha512-8zsjWrQkkBoLK6uxASk1nJ2SKv97ltiGDo6A3wA0/yRPz+CwmEyDo0hUrhIuukG2JHpAl3bvFIixw2/3Hi0DOg== +bser@2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/bser/-/bser-2.1.1.tgz#e6787da20ece9d07998533cfd9de6f5c38f4bc05" + integrity sha512-gQxTNE/GAfIIrmHLUE3oJyp5FO6HRBfhjnw4/wMmA63ZGDJnWBmgY/lyQBpnDUkGmAhbSe39tx2d/iTOAfglwQ== dependencies: node-int64 "^0.4.0" +buffer-crc32@~0.2.3: + version "0.2.13" + resolved "https://registry.yarnpkg.com/buffer-crc32/-/buffer-crc32-0.2.13.tgz#0d333e3f00eac50aa1454abd30ef8c2a5d9a7242" + integrity sha1-DTM+PwDqxQqhRUq9MO+MKl2ackI= + buffer-equal-constant-time@1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/buffer-equal-constant-time/-/buffer-equal-constant-time-1.0.1.tgz#f8e71132f7ffe6e01a5c9697a4c6f3e48d5cc819" @@ -2839,18 +3096,18 @@ buffer-xor@^1.0.3: integrity sha1-JuYe0UIvtw3ULm42cp7VHYVf6Nk= buffer@^4.3.0: - version "4.9.1" - resolved "https://registry.yarnpkg.com/buffer/-/buffer-4.9.1.tgz#6d1bb601b07a4efced97094132093027c95bc298" - integrity sha1-bRu2AbB6TvztlwlBMgkwJ8lbwpg= + version "4.9.2" + resolved "https://registry.yarnpkg.com/buffer/-/buffer-4.9.2.tgz#230ead344002988644841ab0244af8c44bbe3ef8" + integrity sha512-xq+q3SRMOxGivLhBNaUdC64hDTQwejJ+H0T/NB1XMtTVEwNTrfFF3gAxiyW0Bu/xWEGhjVKgUcMhCrUy2+uCWg== dependencies: base64-js "^1.0.2" ieee754 "^1.1.4" isarray "^1.0.0" buffer@^5.2.1: - version "5.4.3" - resolved "https://registry.yarnpkg.com/buffer/-/buffer-5.4.3.tgz#3fbc9c69eb713d323e3fc1a895eee0710c072115" - integrity sha512-zvj65TkFeIt3i6aj5bIvJDzjjQQGs4o/sNoezg1F1kYap9Nu2jcUdpwzRSJTHMMzG0H7bZkn4rNQpImhuxWX2A== + version "5.6.0" + resolved "https://registry.yarnpkg.com/buffer/-/buffer-5.6.0.tgz#a31749dc7d81d84db08abf937b6b8c4033f62786" + integrity sha512-/gDYp/UtU0eA1ys8bOs9J6a+E/KWIY+DZ+Q2WESNUA0jFRsJOc0SNUO6xJ5SGA1xueg3NL65W6s+NY5l9cunuw== dependencies: base64-js "^1.0.2" ieee754 "^1.1.4" @@ -2871,9 +3128,9 @@ bytes@3.1.0: integrity sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg== cacache@^12.0.2: - version "12.0.3" - resolved "https://registry.yarnpkg.com/cacache/-/cacache-12.0.3.tgz#be99abba4e1bf5df461cd5a2c1071fc432573390" - integrity sha512-kqdmfXEGFepesTuROHMs3MpFLWrPkSSpRqOw80RCflZXy/khxaArvFrQ7uJxSUduzAufc6G0g1VUCOZXxWavPw== + version "12.0.4" + resolved "https://registry.yarnpkg.com/cacache/-/cacache-12.0.4.tgz#668bcbd105aeb5f1d92fe25570ec9525c8faa40c" + integrity sha512-a0tMB40oefvuInr4Cwb3GerbL9xTj1D5yg0T5xrjGCGyfvbxseIXX7BAO/u/hIXdafzOI5JC3wDwHyf24buOAQ== dependencies: bluebird "^3.5.5" chownr "^1.1.1" @@ -2961,11 +3218,6 @@ camelcase@^2.0.0: resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-2.1.1.tgz#7c1d16d679a1bbe59ca02cacecfb011e201f5a1f" integrity sha1-fB0W1nmhu+WcoCys7PsBHiAfWh8= -camelcase@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-3.0.0.tgz#32fc4b9fcdaf845fcdf7e73bb97cac2261f0ab0a" - integrity sha1-MvxLn82vhF/N9+c7uXysImHwqwo= - camelcase@^4.0.0, camelcase@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-4.1.0.tgz#d545635be1e33c542649c69173e5de6acfae34dd" @@ -2991,10 +3243,10 @@ caniuse-api@^3.0.0: lodash.memoize "^4.1.2" lodash.uniq "^4.5.0" -caniuse-lite@^1.0.0, caniuse-lite@^1.0.30000981, caniuse-lite@^1.0.30000989, caniuse-lite@^1.0.30000998: - version "1.0.30000999" - resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30000999.tgz#427253a69ad7bea4aa8d8345687b8eec51ca0e43" - integrity sha512-1CUyKyecPeksKwXZvYw0tEoaMCo/RwBlXmEtN5vVnabvO0KPd9RQLcaAuR9/1F+KDMv6esmOFWlsXuzDk+8rxg== +caniuse-lite@^1.0.0, caniuse-lite@^1.0.30000981, caniuse-lite@^1.0.30000989, caniuse-lite@^1.0.30001043, caniuse-lite@^1.0.30001061: + version "1.0.30001065" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001065.tgz#e8d7fef61cdfd8a7107493ad6bf551a4eb59c68f" + integrity sha512-DDxCLgJ266YnAHQv0jS1wdOaihRFF52Zgmlag39sQJVy2H46oROpJp4hITstqhdB8qnHSrKNoAEkQA9L/oYF9A== capture-exit@^2.0.0: version "2.0.0" @@ -3038,12 +3290,28 @@ chalk@^1.1.1, chalk@^1.1.3: strip-ansi "^3.0.0" supports-color "^2.0.0" +chalk@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-3.0.0.tgz#3f73c2bf526591f574cc492c51e2456349f844e4" + integrity sha512-4D3B6Wf41KOYRFdszmDqMCGq5VV/uMAB273JILmO+3jAlh8X4qDtdtgCR3fxtbLEMzSx22QdhnDcJvu2u1fVwg== + dependencies: + ansi-styles "^4.1.0" + supports-color "^7.1.0" + +chalk@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.0.0.tgz#6e98081ed2d17faab615eb52ac66ec1fe6209e72" + integrity sha512-N9oWFcegS0sFr9oh1oz2d7Npos6vNoWW9HvtCg5N1KRFpUhaAhvTv5Y58g880fZaEYSNm3qDz8SU1UrGvp+n7A== + dependencies: + ansi-styles "^4.1.0" + supports-color "^7.1.0" + chardet@^0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/chardet/-/chardet-0.7.0.tgz#90094849f0937f2eedc2425d0d28a9e5f0cbad9e" integrity sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA== -chokidar@^2.0.0, chokidar@^2.0.2, chokidar@^2.0.4, chokidar@^2.1.5: +chokidar@^2.0.0, chokidar@^2.0.4, chokidar@^2.1.8: version "2.1.8" resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-2.1.8.tgz#804b3a7b6a99358c3c5c61e71d8728f041cff917" integrity sha512-ZmZUazfOzf0Nve7duiCKD23PFSCs4JPoYyccjUFF3aQkQadqBhfzhjkwBH2mNOG9cTBwhamM37EIsIkZw3nRgg== @@ -3062,10 +3330,25 @@ chokidar@^2.0.0, chokidar@^2.0.2, chokidar@^2.0.4, chokidar@^2.1.5: optionalDependencies: fsevents "^1.2.7" +chokidar@^3.4.0: + version "3.4.0" + resolved "https://registry.yarnpkg.com/chokidar/-/chokidar-3.4.0.tgz#b30611423ce376357c765b9b8f904b9fba3c0be8" + integrity sha512-aXAaho2VJtisB/1fg1+3nlLJqGOuewTzQpd/Tz0yTg2R0e4IGtshYvtjowyEumcBv2z+y4+kc75Mz7j5xJskcQ== + dependencies: + anymatch "~3.1.1" + braces "~3.0.2" + glob-parent "~5.1.0" + is-binary-path "~2.1.0" + is-glob "~4.0.1" + normalize-path "~3.0.0" + readdirp "~3.4.0" + optionalDependencies: + fsevents "~2.1.2" + chownr@^1.1.1: - version "1.1.3" - resolved "https://registry.yarnpkg.com/chownr/-/chownr-1.1.3.tgz#42d837d5239688d55f303003a508230fa6727142" - integrity sha512-i70fVHhmV3DtTl6nqvZOnIjbY0Pe4kAUjwHj8z0zAdgBtYrJyYwLKCCuRBQ5ppkyL0AkN7HKRnETdmdp1zqNXw== + version "1.1.4" + resolved "https://registry.yarnpkg.com/chownr/-/chownr-1.1.4.tgz#6fc9d7b42d32a583596337666e7d08084da2cc6b" + integrity sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg== chrome-trace-event@^1.0.2: version "1.0.2" @@ -3103,9 +3386,9 @@ class-utils@^0.3.5: static-extend "^0.1.1" clean-css@4.2.x: - version "4.2.1" - resolved "https://registry.yarnpkg.com/clean-css/-/clean-css-4.2.1.tgz#2d411ef76b8569b6d0c84068dabe85b0aa5e5c17" - integrity sha512-4ZxI6dy4lrY6FHzfiy1aEOXgu4LIsW2MhwG0VBKdcoGoH/XLFgaHSdLTGr4O8Be6A8r3MOphEiI8Gc1n0ecf3g== + version "4.2.3" + resolved "https://registry.yarnpkg.com/clean-css/-/clean-css-4.2.3.tgz#507b5de7d97b48ee53d84adb0160ff6216380f78" + integrity sha512-VcMWDN54ZN/DS+g58HYL5/n4Zrqe8vHJpGA8KdgUXFU4fuP/aHNw8eld9SyEIyabIMJX/0RaY/fplOo5hYLSFA== dependencies: source-map "~0.6.0" @@ -3121,19 +3404,17 @@ cli-cursor@^2.1.0: dependencies: restore-cursor "^2.0.0" -cli-width@^2.0.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-2.2.0.tgz#ff19ede8a9a5e579324147b0c11f0fbcbabed639" - integrity sha1-/xnt6Kml5XkyQUewwR8PvLq+1jk= - -cliui@^3.2.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/cliui/-/cliui-3.2.0.tgz#120601537a916d29940f934da3b48d585a39213d" - integrity sha1-EgYBU3qRbSmUD5NNo7SNWFo5IT0= +cli-cursor@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/cli-cursor/-/cli-cursor-3.1.0.tgz#264305a7ae490d1d03bf0c9ba7c925d1753af307" + integrity sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw== dependencies: - string-width "^1.0.1" - strip-ansi "^3.0.1" - wrap-ansi "^2.0.0" + restore-cursor "^3.1.0" + +cli-width@^2.0.0: + version "2.2.1" + resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-2.2.1.tgz#b0433d0b4e9c847ef18868a4ef16fd5fc8271c48" + integrity sha512-GRMWDxpOB6Dgk2E5Uo+3eEBvtOOlimMmpbFiKuLFnQzYDavtLFY3K5ona41jgN/WdRZtG7utuVSVTL4HbZHGkw== cliui@^4.0.0: version "4.1.0" @@ -3207,12 +3488,19 @@ color-convert@^1.9.0, color-convert@^1.9.1: dependencies: color-name "1.1.3" +color-convert@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" + integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== + dependencies: + color-name "~1.1.4" + color-name@1.1.3: version "1.1.3" resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU= -color-name@^1.0.0: +color-name@^1.0.0, color-name@~1.1.4: version "1.1.4" resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== @@ -3259,7 +3547,7 @@ colorspace@1.1.x: color "3.0.x" text-hex "1.0.x" -combined-stream@^1.0.6, combined-stream@~1.0.6: +combined-stream@^1.0.6, combined-stream@^1.0.8, combined-stream@~1.0.6: version "1.0.8" resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.8.tgz#c3d45a8b34fd730631a110a8a2520682b31d5a7f" integrity sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg== @@ -3271,15 +3559,10 @@ commander@2.17.x: resolved "https://registry.yarnpkg.com/commander/-/commander-2.17.1.tgz#bd77ab7de6de94205ceacc72f1716d29f20a77bf" integrity sha512-wPMUt6FnH2yzG95SA6mzjQOEKUU3aLaDEmzs1ti+1E9h+CsrZghRlqEM/EJ4KscsQVG8uNN4uVreUeT8+drlgg== -commander@2.20.0: - version "2.20.0" - resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.0.tgz#d58bb2b5c1ee8f87b0d340027e9e94e222c5a422" - integrity sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ== - commander@^2.11.0, commander@^2.20.0: - version "2.20.1" - resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.1.tgz#3863ce3ca92d0831dcf2a102f5fb4b5926afd0f9" - integrity sha512-cCuLsMhJeWQ/ZpsFTbE765kvVfoeSddc4nU3up4fV+fDBcfUXnbITJ+JzhkdjzOqhURjZgujxaioam4RM9yGUg== + version "2.20.3" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" + integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ== commander@^3.0.2: version "3.0.2" @@ -3314,11 +3597,11 @@ compose-function@3.0.3: arity-n "^1.0.4" compressible@^2.0.12, compressible@~2.0.16: - version "2.0.17" - resolved "https://registry.yarnpkg.com/compressible/-/compressible-2.0.17.tgz#6e8c108a16ad58384a977f3a482ca20bff2f38c1" - integrity sha512-BGHeLCK1GV7j1bSmQQAi26X+GgWcTjLr/0tzSvMCl3LH1w1IJ4PFSPoV5316b30cneTziC+B1a+3OjoSUcQYmw== + version "2.0.18" + resolved "https://registry.yarnpkg.com/compressible/-/compressible-2.0.18.tgz#af53cca6b070d4c3c0750fbd77286a6d7cc46fba" + integrity sha512-AF3r7P5dWxL8MxyITRMlORQNaOA2IkAFaTr4k7BUumjPtRpGDTZpl0Pb1XCO6JeDCBdp126Cgs9sMxqSjgYyRg== dependencies: - mime-db ">= 1.40.0 < 2" + mime-db ">= 1.43.0 < 2" compression@^1.5.2: version "1.7.4" @@ -3338,7 +3621,7 @@ concat-map@0.0.1: resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b" integrity sha1-2Klr13/Wjfd5OnMDajug1UBdR3s= -concat-stream@1.6.2, concat-stream@^1.5.0: +concat-stream@^1.5.0, concat-stream@^1.6.2: version "1.6.2" resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.6.2.tgz#904bdf194cd3122fc675c77fc4ac3d4ff0fd1a34" integrity sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw== @@ -3371,11 +3654,11 @@ configstore@^3.0.0: xdg-basedir "^3.0.0" configstore@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/configstore/-/configstore-5.0.0.tgz#37de662c7a49b5fe8dbcf8f6f5818d2d81ed852b" - integrity sha512-eE/hvMs7qw7DlcB5JPRnthmrITuHMmACUJAp89v6PT6iOqzoLS7HRWhBtuHMlhNHo2AhUSA/3Dh1bKNJHcublQ== + version "5.0.1" + resolved "https://registry.yarnpkg.com/configstore/-/configstore-5.0.1.tgz#d365021b5df4b98cdd187d6a3b0e3f6a7cc5ed96" + integrity sha512-aMKprgk5YhBNyH25hj8wGt2+D52Sw1DRRIzqBwLp2Ya9mFmY8KPvvtvmna8SxVR9JMZ4kzMD68N22vlaRpkeFA== dependencies: - dot-prop "^5.1.0" + dot-prop "^5.2.0" graceful-fs "^4.1.2" make-dir "^3.0.0" unique-string "^2.0.0" @@ -3393,11 +3676,9 @@ connect-history-api-fallback@^1.3.0: integrity sha512-e54B99q/OUoH64zYYRf3HBP5z24G38h5D3qXu23JGRoigpX5Ss4r9ZnDk3g0Z8uQC2x2lPaJ+UlWBc1ZWBWdLg== console-browserify@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/console-browserify/-/console-browserify-1.1.0.tgz#f0241c45730a9fc6323b206dbf38edc741d0bb10" - integrity sha1-8CQcRXMKn8YyOyBtvzjtx0HQuxA= - dependencies: - date-now "^0.1.4" + version "1.2.0" + resolved "https://registry.yarnpkg.com/console-browserify/-/console-browserify-1.2.0.tgz#67063cef57ceb6cf4993a2ab3a55840ae8c49336" + integrity sha512-ZMkYO/LkF17QvCPqM0gxw8yUzigAOZOSWSHg91FH6orS7vcEj5dVZTidN2fQ14yBSdg97RqhSNwLUXInd52OTA== console-control-strings@^1.0.0, console-control-strings@~1.1.0: version "1.1.0" @@ -3431,7 +3712,7 @@ content-type@~1.0.4: resolved "https://registry.yarnpkg.com/content-type/-/content-type-1.0.4.tgz#e138cc75e040c727b1966fe5e5f8c9aee256fe3b" integrity sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA== -convert-source-map@1.6.0, convert-source-map@^1.1.0, convert-source-map@^1.4.0: +convert-source-map@1.6.0: version "1.6.0" resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.6.0.tgz#51b537a8c43e0f04dec1993bffcdd504e758ac20" integrity sha512-eFu7XigvxdZ1ETfbgPBohgyQ/Z++C0eEhTor0qRwBw9unw+L0/6V8wkSuGgzdThkiS5lSpdptOQPD8Ak40a+7A== @@ -3443,6 +3724,13 @@ convert-source-map@^0.3.3: resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-0.3.5.tgz#f1d802950af7dd2631a1febe0596550c86ab3190" integrity sha1-8dgClQr33SYxof6+BZZVDIarMZA= +convert-source-map@^1.1.0, convert-source-map@^1.4.0, convert-source-map@^1.7.0: + version "1.7.0" + resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.7.0.tgz#17a2cb882d7f77d3490585e2ce6c524424a3a442" + integrity sha512-4FJkXzKXEDB1snCFZlLP4gpC3JILicCpGbzG9f9G7tGqGCzETQ2hWPrcinA9oU4wtf2biUaEH5065UnMeR33oA== + dependencies: + safe-buffer "~5.1.1" + cookie-signature@1.0.6: version "1.0.6" resolved "https://registry.yarnpkg.com/cookie-signature/-/cookie-signature-1.0.6.tgz#e303a882b342cc3ee8ca513a79999734dab3ae2c" @@ -3475,28 +3763,23 @@ copy-descriptor@^0.1.0: resolved "https://registry.yarnpkg.com/copy-descriptor/-/copy-descriptor-0.1.1.tgz#676f6eb3c39997c2ee1ac3a924fd6124748f578d" integrity sha1-Z29us8OZl8LuGsOpJP1hJHSPV40= -core-js-compat@^3.1.1: - version "3.2.1" - resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.2.1.tgz#0cbdbc2e386e8e00d3b85dc81c848effec5b8150" - integrity sha512-MwPZle5CF9dEaMYdDeWm73ao/IflDH+FjeJCWEADcEgFSE9TLimFKwJsfmkwzI8eC0Aj0mgvMDjeQjrElkz4/A== +core-js-compat@^3.6.2: + version "3.6.5" + resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.6.5.tgz#2a51d9a4e25dfd6e690251aa81f99e3c05481f1c" + integrity sha512-7ItTKOhOZbznhXAQ2g/slGg1PJV5zDO/WdkTwi7UEOJmkvsE32PWvx6mKtDjiMpjnR2CNf6BAD6sSxIlv7ptng== dependencies: - browserslist "^4.6.6" - semver "^6.3.0" + browserslist "^4.8.5" + semver "7.0.0" -core-js@3.2.1: - version "3.2.1" - resolved "https://registry.yarnpkg.com/core-js/-/core-js-3.2.1.tgz#cd41f38534da6cc59f7db050fe67307de9868b09" - integrity sha512-Qa5XSVefSVPRxy2XfUC13WbvqkxhkwB3ve+pgCQveNgYzbM/UxZeu1dcOX/xr4UmfUd+muuvsaxilQzCyUurMw== +core-js@^2.4.0, core-js@^2.6.5: + version "2.6.11" + resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.6.11.tgz#38831469f9922bded8ee21c9dc46985e0399308c" + integrity sha512-5wjnpaT/3dV+XB4borEsnAYQchn00XSgTAWKDkEqv+K8KevjbzmofK6hfJ9TZIlpj2N0xQpazy7PiRQiWHqzWg== -core-js@^2.4.0: - version "2.6.9" - resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.6.9.tgz#6b4b214620c834152e179323727fc19741b084f2" - integrity sha512-HOpZf6eXmnl7la+cUdMnLvUxKNqLUzJvgIziQ0DiF3JwSImNphIqdGqzj6hIKyX04MmV0poclQ7+wjWvxQyR2A== - -core-js@^2.6.5: - version "2.6.10" - resolved "https://registry.yarnpkg.com/core-js/-/core-js-2.6.10.tgz#8a5b8391f8cc7013da703411ce5b585706300d7f" - integrity sha512-I39t74+4t+zau64EN1fE5v2W31Adtc/REhzWN+gWRRXg6WH5qAsZm62DHpQ1+Yhe4047T55jvzz7MUqF/dBBlA== +core-js@^3.5.0: + version "3.6.5" + resolved "https://registry.yarnpkg.com/core-js/-/core-js-3.6.5.tgz#7395dc273af37fb2e50e9bd3d9fe841285231d1a" + integrity sha512-vZVEEwZoIsI+vPEuoF9Iqf5H7/M3eeQqWlQnYa8FSKKePuYTf5MWnxb5SDAzCa60b3JBRS5g9b+Dq7b1y/RCrA== core-util-is@1.0.2, core-util-is@~1.0.0: version "1.0.2" @@ -3511,7 +3794,7 @@ cors@^2.8.5: object-assign "^4" vary "^1" -cosmiconfig@^5.0.0, cosmiconfig@^5.2.0, cosmiconfig@^5.2.1: +cosmiconfig@^5.0.0, cosmiconfig@^5.2.1: version "5.2.1" resolved "https://registry.yarnpkg.com/cosmiconfig/-/cosmiconfig-5.2.1.tgz#040f726809c591e77a17c0a3626ca45b4f168b1a" integrity sha512-H65gsXo1SKjf8zmrJ67eJk8aIRKV5ff2D4uKZIBZShbhGSpEmsQOPW/SKMKYhSTrqR7ufy6RP69rPogdaPh/kA== @@ -3521,6 +3804,17 @@ cosmiconfig@^5.0.0, cosmiconfig@^5.2.0, cosmiconfig@^5.2.1: js-yaml "^3.13.1" parse-json "^4.0.0" +cosmiconfig@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/cosmiconfig/-/cosmiconfig-6.0.0.tgz#da4fee853c52f6b1e6935f41c1a2fc50bd4a9982" + integrity sha512-xb3ZL6+L8b9JLLCx3ZdoZy4+2ECphCMo2PwqgP1tlfVq6M6YReyzBJtvWWtbDSpNr9hn96pkCiZqUcFEc+54Qg== + dependencies: + "@types/parse-json" "^4.0.0" + import-fresh "^3.1.0" + parse-json "^5.0.0" + path-type "^4.0.0" + yaml "^1.7.2" + create-ecdh@^4.0.0: version "4.0.3" resolved "https://registry.yarnpkg.com/create-ecdh/-/create-ecdh-4.0.3.tgz#c9111b6f33045c4697f144787f9254cdc77c45ff" @@ -3536,7 +3830,7 @@ create-error-class@^3.0.0: dependencies: capture-stack-trace "^1.0.0" -create-hash@^1.1.0, create-hash@^1.1.2: +create-hash@^1.1.0, create-hash@^1.1.2, create-hash@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/create-hash/-/create-hash-1.2.0.tgz#889078af11a63756bcfb59bd221996be3a9ef196" integrity sha512-z00bCGNHDG8mHAkP7CtT1qVu+bFQUPjYq/4Iv3C3kWjTFV10zIjfSoeqXo9Asws8gwSHDGj/hl2u4OGIjapeCg== @@ -3547,7 +3841,7 @@ create-hash@^1.1.0, create-hash@^1.1.2: ripemd160 "^2.0.1" sha.js "^2.4.0" -create-hmac@^1.1.0, create-hmac@^1.1.2, create-hmac@^1.1.4: +create-hmac@^1.1.0, create-hmac@^1.1.4, create-hmac@^1.1.7: version "1.1.7" resolved "https://registry.yarnpkg.com/create-hmac/-/create-hmac-1.1.7.tgz#69170c78b3ab957147b2b8b04572e47ead2243ff" integrity sha512-MJG9liiZ+ogc4TzUwuvbER1JRdgvUFSB5+VR/g5h82fGaIRWMWddtKBHi7/sVhfjQZ6SehlyhvQYrcYkaUIpLg== @@ -3687,12 +3981,12 @@ css-select@^1.1.0: nth-check "~1.0.1" css-select@^2.0.0: - version "2.0.2" - resolved "https://registry.yarnpkg.com/css-select/-/css-select-2.0.2.tgz#ab4386cec9e1f668855564b17c3733b43b2a5ede" - integrity sha512-dSpYaDVoWaELjvZ3mS6IKZM/y2PMPa/XYoEfYNZePL4U/XgyxZNroHEHReDx/d+VgXh9VbCTtFqLkFbmeqeaRQ== + version "2.1.0" + resolved "https://registry.yarnpkg.com/css-select/-/css-select-2.1.0.tgz#6a34653356635934a81baca68d0255432105dbef" + integrity sha512-Dqk7LQKpwLoH3VovzZnkzegqNSuAziQyNZUcrdDM401iY+R5NkGBXGmtO05/yaXQziALuPogeG0b7UAgjnTJTQ== dependencies: boolbase "^1.0.0" - css-what "^2.1.2" + css-what "^3.2.1" domutils "^1.7.0" nth-check "^1.0.2" @@ -3705,32 +3999,32 @@ css-to-react-native@^2.2.2: css-color-keywords "^1.0.0" postcss-value-parser "^3.3.0" -css-tree@1.0.0-alpha.29: - version "1.0.0-alpha.29" - resolved "https://registry.yarnpkg.com/css-tree/-/css-tree-1.0.0-alpha.29.tgz#3fa9d4ef3142cbd1c301e7664c1f352bd82f5a39" - integrity sha512-sRNb1XydwkW9IOci6iB2xmy8IGCj6r/fr+JWitvJ2JxQRPzN3T4AGGVWCMlVmVwM1gtgALJRmGIlWv5ppnGGkg== - dependencies: - mdn-data "~1.1.0" - source-map "^0.5.3" - -css-tree@1.0.0-alpha.33: - version "1.0.0-alpha.33" - resolved "https://registry.yarnpkg.com/css-tree/-/css-tree-1.0.0-alpha.33.tgz#970e20e5a91f7a378ddd0fc58d0b6c8d4f3be93e" - integrity sha512-SPt57bh5nQnpsTBsx/IXbO14sRc9xXu5MtMAVuo0BaQQmyf0NupNPPSoMaqiAF5tDFafYsTkfeH4Q/HCKXkg4w== +css-tree@1.0.0-alpha.37: + version "1.0.0-alpha.37" + resolved "https://registry.yarnpkg.com/css-tree/-/css-tree-1.0.0-alpha.37.tgz#98bebd62c4c1d9f960ec340cf9f7522e30709a22" + integrity sha512-DMxWJg0rnz7UgxKT0Q1HU/L9BeJI0M6ksor0OgqOnF+aRCDWg/N2641HmVyU9KVIu0OVVWOb2IpC9A+BJRnejg== dependencies: mdn-data "2.0.4" - source-map "^0.5.3" + source-map "^0.6.1" -css-unit-converter@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/css-unit-converter/-/css-unit-converter-1.1.1.tgz#d9b9281adcfd8ced935bdbaba83786897f64e996" - integrity sha1-2bkoGtz9jO2TW9urqDeGiX9k6ZY= +css-tree@1.0.0-alpha.39: + version "1.0.0-alpha.39" + resolved "https://registry.yarnpkg.com/css-tree/-/css-tree-1.0.0-alpha.39.tgz#2bff3ffe1bb3f776cf7eefd91ee5cba77a149eeb" + integrity sha512-7UvkEYgBAHRG9Nt980lYxjsTrCyHFN53ky3wVsDkiMdVqylqRt+Zc+jm5qw7/qyOvN2dHSYtX0e4MbCCExSvnA== + dependencies: + mdn-data "2.0.6" + source-map "^0.6.1" -css-what@2.1, css-what@^2.1.2: +css-what@2.1: version "2.1.3" resolved "https://registry.yarnpkg.com/css-what/-/css-what-2.1.3.tgz#a6d7604573365fe74686c3f311c56513d88285f2" integrity sha512-a+EPoD+uZiNfh+5fxw2nO9QwFa6nJe2Or35fGY6Ipw1R3R4AGz1d1TEZrCegvw2YTmZ0jXirGYlzxxpYSHwpEg== +css-what@^3.2.1: + version "3.2.1" + resolved "https://registry.yarnpkg.com/css-what/-/css-what-3.2.1.tgz#f4a8f12421064621b456755e34a03a2c22df5da1" + integrity sha512-WwOrosiQTvyms+Ti5ZC5vGEK0Vod3FTt1ca+payZqvKuGJF+dq7bG63DstxtN0dpm6FxY27a/zS3Wten+gEtGw== + css@^2.0.0: version "2.2.4" resolved "https://registry.yarnpkg.com/css/-/css-2.2.4.tgz#c646755c73971f2bba6a601e2cf2fd71b1298929" @@ -3824,12 +4118,12 @@ cssnano@^4.1.10: is-resolvable "^1.0.0" postcss "^7.0.0" -csso@^3.5.1: - version "3.5.1" - resolved "https://registry.yarnpkg.com/csso/-/csso-3.5.1.tgz#7b9eb8be61628973c1b261e169d2f024008e758b" - integrity sha512-vrqULLffYU1Q2tLdJvaCYbONStnfkfimRxXNaGjxMldI0C7JPBC4rB1RyjhfdZ4m1frm8pM9uRPKH3d2knZ8gg== +csso@^4.0.2: + version "4.0.3" + resolved "https://registry.yarnpkg.com/csso/-/csso-4.0.3.tgz#0d9985dc852c7cc2b2cacfbbe1079014d1a8e903" + integrity sha512-NL3spysxUkcrOgnpsT4Xdl2aiEiBG6bXswAABQVHcMrfjjBisFOKwLDOmf4wf32aPdcJws1zds2B0Rg+jqMyHQ== dependencies: - css-tree "1.0.0-alpha.29" + css-tree "1.0.0-alpha.39" cssom@0.3.x, "cssom@>= 0.3.2 < 0.4.0", cssom@^0.3.4: version "0.3.8" @@ -3844,9 +4138,9 @@ cssstyle@^1.0.0, cssstyle@^1.1.1: cssom "0.3.x" csstype@^2.2.0: - version "2.6.7" - resolved "https://registry.yarnpkg.com/csstype/-/csstype-2.6.7.tgz#20b0024c20b6718f4eda3853a1f5a1cce7f5e4a5" - integrity sha512-9Mcn9sFbGBAdmimWb2gLVDtFJzeKtDGIr76TUqmjZrw9LFXBMSU70lcs+C0/7fyCd6iBDqmksUcCOUIkisPHsQ== + version "2.6.10" + resolved "https://registry.yarnpkg.com/csstype/-/csstype-2.6.10.tgz#e63af50e66d7c266edb6b32909cfd0aabe03928b" + integrity sha512-D34BqZU4cIlMCY93rZHbrq9pjTAQJ3U8S8rfBqjwHxkGPThWFjzZDQpgMJY0QViLxth6ZKYiwFBo14RdN44U/w== currently-unhandled@^0.4.1: version "0.4.1" @@ -3877,9 +4171,9 @@ d@1, d@^1.0.1: type "^1.0.1" damerau-levenshtein@^1.0.4: - version "1.0.5" - resolved "https://registry.yarnpkg.com/damerau-levenshtein/-/damerau-levenshtein-1.0.5.tgz#780cf7144eb2e8dbd1c3bb83ae31100ccc31a414" - integrity sha512-CBCRqFnpu715iPmw1KrdOrzRqbdFwQTwAWyyyYS42+iAgHCuXZ+/TdMgQkUENPomxEz9z1BEzuQU2Xw0kUuAgA== + version "1.0.6" + resolved "https://registry.yarnpkg.com/damerau-levenshtein/-/damerau-levenshtein-1.0.6.tgz#143c1641cb3d85c60c32329e26899adea8701791" + integrity sha512-JVrozIeElnj3QzfUIt8tB8YMluBJom4Vw9qTPpjGYQ9fYlB3D/rb6OordUxf3xeFB35LKWs0xqcO5U6ySvBtug== dashdash@^1.12.0: version "1.14.1" @@ -3897,15 +4191,10 @@ data-urls@^1.0.0, data-urls@^1.1.0: whatwg-mimetype "^2.2.0" whatwg-url "^7.0.0" -date-and-time@^0.10.0: - version "0.10.0" - resolved "https://registry.yarnpkg.com/date-and-time/-/date-and-time-0.10.0.tgz#53825b774167b55fbdf0bbd0f17f19357df7bc70" - integrity sha512-IbIzxtvK80JZOVsWF6+NOjunTaoFVYxkAQoyzmflJyuRCJAJebehy48mPiCAedcGp4P7/UO3QYRWa0fe6INftg== - -date-now@^0.1.4: - version "0.1.4" - resolved "https://registry.yarnpkg.com/date-now/-/date-now-0.1.4.tgz#eaf439fd4d4848ad74e5cc7dbef200672b9e345b" - integrity sha1-6vQ5/U1ISK105cx9vvIAZyueNFs= +date-and-time@^0.13.0: + version "0.13.1" + resolved "https://registry.yarnpkg.com/date-and-time/-/date-and-time-0.13.1.tgz#d12ba07ac840d5b112dc4c83f8a03e8a51f78dd6" + integrity sha512-/Uge9DJAT+s+oAcDxtBhyR8+sKjUnZbYmyhbmWjTHNtX7B7oWD8YyYdeXcBRbwSj6hVvj+IQegJam7m7czhbFw== debug@2.6.9, debug@^2.2.0, debug@^2.3.3, debug@^2.6.0, debug@^2.6.8, debug@^2.6.9: version "2.6.9" @@ -3914,28 +4203,28 @@ debug@2.6.9, debug@^2.2.0, debug@^2.3.3, debug@^2.6.0, debug@^2.6.8, debug@^2.6. dependencies: ms "2.0.0" -debug@3.1.0, debug@=3.1.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" - integrity sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g== - dependencies: - ms "2.0.0" - -debug@^3.0.0, debug@^3.1.0, debug@^3.2.5, debug@^3.2.6: - version "3.2.6" - resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.6.tgz#e83d17de16d8a7efb7717edbe5fb10135eee629b" - integrity sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ== - dependencies: - ms "^2.1.1" - -debug@^4.0.1, debug@^4.1.0, debug@^4.1.1: +debug@4, debug@^4.0.1, debug@^4.1.0, debug@^4.1.1: version "4.1.1" resolved "https://registry.yarnpkg.com/debug/-/debug-4.1.1.tgz#3b72260255109c6b589cee050f1d516139664791" integrity sha512-pYAIzeRo8J6KPEaJ0VWOh5Pzkbw/RetuzehGM7QRRX5he4fPHx2rdKMB256ehJCkX+XRQm16eZLqLNS8RSZXZw== dependencies: ms "^2.1.1" -decamelize@^1.1.1, decamelize@^1.1.2, decamelize@^1.2.0: +debug@=3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/debug/-/debug-3.1.0.tgz#5bb5a0672628b64149566ba16819e61518c67261" + integrity sha512-OX8XqP7/1a9cqkxYw2yXss15f26NKWBpDXQd0/uK/KPqdQhxbPa994hnzjcE2VqQpDslf55723cKPUOGSmMY3g== + dependencies: + ms "2.0.0" + +debug@^3.0.0, debug@^3.1.0, debug@^3.1.1, debug@^3.2.5, debug@^3.2.6: + version "3.2.6" + resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.6.tgz#e83d17de16d8a7efb7717edbe5fb10135eee629b" + integrity sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ== + dependencies: + ms "^2.1.1" + +decamelize@^1.1.2, decamelize@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" integrity sha1-9lNNFRSCabIDUue+4m9QH5oZEpA= @@ -3953,9 +4242,9 @@ decode-uri-component@^0.2.0: integrity sha1-6zkTMzRYd1y4TNGh+uBiEGu4dUU= deep-equal@^1.0.1: - version "1.1.0" - resolved "https://registry.yarnpkg.com/deep-equal/-/deep-equal-1.1.0.tgz#3103cdf8ab6d32cf4a8df7865458f2b8d33f3745" - integrity sha512-ZbfWJq/wN1Z273o7mUSjILYqehAktR2NVoSrOukDkU9kg2v/Uv89yU4Cvz8seJeAmtN5oqiefKq8FPuXOboqLw== + version "1.1.1" + resolved "https://registry.yarnpkg.com/deep-equal/-/deep-equal-1.1.1.tgz#b5c98c942ceffaf7cb051e24e1434a25a2e6076a" + integrity sha512-yd9c5AdiqVcR+JjcwUQb9DkhJc8ngNr0MahEBGvDiJw8puWab2yZlh+nkasOnZP+EGTAP6rRp2JzJhJZzvNF8g== dependencies: is-arguments "^1.0.4" is-date-object "^1.0.1" @@ -4039,9 +4328,9 @@ depd@~1.1.0, depd@~1.1.2: integrity sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak= des.js@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/des.js/-/des.js-1.0.0.tgz#c074d2e2aa6a8a9a07dbd61f9a15c2cd83ec8ecc" - integrity sha1-wHTS4qpqipoH29YfmhXCzYPsjsw= + version "1.0.1" + resolved "https://registry.yarnpkg.com/des.js/-/des.js-1.0.1.tgz#5382142e1bdc53f85d86d53e5f4aa7deb91e0843" + integrity sha512-Q0I4pfFrv2VPd34/vfLrFOoRmlYj3OV50i7fskps1jZWK1kApMWWT9G6RRUeYedLcBDIhnSDaUvJMb3AhUlaEA== dependencies: inherits "^2.0.1" minimalistic-assert "^1.0.0" @@ -4051,11 +4340,6 @@ destroy@~1.0.4: resolved "https://registry.yarnpkg.com/destroy/-/destroy-1.0.4.tgz#978857442c44749e4206613e37946205826abd80" integrity sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA= -detect-libc@^1.0.2: - version "1.0.3" - resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-1.0.3.tgz#fa137c4bd698edf55cd5cd02ac559f91a4c4ba9b" - integrity sha1-+hN8S9aY7fVc1c0CrFWfkaTEups= - detect-newline@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/detect-newline/-/detect-newline-2.1.0.tgz#f41f1c10be4b00e87b5f13da680759f2c5bfd3e2" @@ -4088,10 +4372,15 @@ diff-sequences@^24.9.0: resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-24.9.0.tgz#5715d6244e2aa65f48bba0bc972db0b0b11e95b5" integrity sha512-Dj6Wk3tWyTE+Fo1rW8v0Xhwk80um6yFYKbuAxc9c3EZxIHFDYwbi34Uk42u1CdnIiVorvt4RmlSDjIPyzGC2ew== +diff-sequences@^26.0.0: + version "26.0.0" + resolved "https://registry.yarnpkg.com/diff-sequences/-/diff-sequences-26.0.0.tgz#0760059a5c287637b842bd7085311db7060e88a6" + integrity sha512-JC/eHYEC3aSS0vZGjuoc4vHA0yAQTzhQQldXMeMF+JlxLGJlCO38Gma82NV9gk1jGFz8mDzUMeaKXvjRRdJ2dg== + diff@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/diff/-/diff-4.0.1.tgz#0c667cb467ebbb5cea7f14f135cc2dba7780a8ff" - integrity sha512-s2+XdvhPCOF01LRQBC8hf4vhbVmI2CGS5aZnxLJlT5FtdhPCDFq80q++zK2KlrVorVDdL5BOGZ/VfLrVtYNF+Q== + version "4.0.2" + resolved "https://registry.yarnpkg.com/diff/-/diff-4.0.2.tgz#60f3aecb89d5fae520c11aa19efc2bb982aade7d" + integrity sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A== diffie-hellman@^5.0.0: version "5.0.3" @@ -4166,10 +4455,10 @@ dom-converter@^0.2: dependencies: utila "~0.4" -dom-serializer@0: - version "0.2.1" - resolved "https://registry.yarnpkg.com/dom-serializer/-/dom-serializer-0.2.1.tgz#13650c850daffea35d8b626a4cfc4d3a17643fdb" - integrity sha512-sK3ujri04WyjwQXVoK4PU3y8ula1stq10GJZpqHIUgoGZdsGzAGu65BnU3d08aTVSvO7mGPZUc0wTEDL+qGE0Q== +dom-serializer@0, dom-serializer@^0.2.1: + version "0.2.2" + resolved "https://registry.yarnpkg.com/dom-serializer/-/dom-serializer-0.2.2.tgz#1afb81f533717175d478655debc5e332d9f9bb51" + integrity sha512-2/xPb3ORsQ42nHYiSunXkDjPLBaEj/xTwUO4B7XCZQTRk7EBtTOPaygh10YAAh2OI1Qrp6NWfpAhzswj0ydt9g== dependencies: domelementtype "^2.0.1" entities "^2.0.0" @@ -4203,6 +4492,13 @@ domhandler@^2.3.0: dependencies: domelementtype "1" +domhandler@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/domhandler/-/domhandler-3.0.0.tgz#51cd13efca31da95bbb0c5bee3a48300e333b3e9" + integrity sha512-eKLdI5v9m67kbXQbJSNn1zjh0SDzvzWVWtX+qEI3eMjZw8daH9k8rlj1FZY9memPwjiskQFbe7vHVVJIAqoEhw== + dependencies: + domelementtype "^2.0.1" + domutils@1.5.1: version "1.5.1" resolved "https://registry.yarnpkg.com/domutils/-/domutils-1.5.1.tgz#dcd8488a26f563d61079e48c9f7b7e32373682cf" @@ -4219,17 +4515,26 @@ domutils@^1.5.1, domutils@^1.7.0: dom-serializer "0" domelementtype "1" -dot-prop@^4.1.0, dot-prop@^4.1.1: +domutils@^2.0.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/domutils/-/domutils-2.1.0.tgz#7ade3201af43703fde154952e3a868eb4b635f16" + integrity sha512-CD9M0Dm1iaHfQ1R/TI+z3/JWp/pgub0j4jIQKH89ARR4ATAV2nbaOQS5XxU9maJP5jHaPdDDQSEHuE2UmpUTKg== + dependencies: + dom-serializer "^0.2.1" + domelementtype "^2.0.1" + domhandler "^3.0.0" + +dot-prop@^4.1.0: version "4.2.0" resolved "https://registry.yarnpkg.com/dot-prop/-/dot-prop-4.2.0.tgz#1f19e0c2e1aa0e32797c49799f2837ac6af69c57" integrity sha512-tUMXrxlExSW6U2EXiiKGSBVdYgtV8qlHL+C10TsW4PURY/ic+eaysnSkwB4kA/mBlCyy/IKDJ+Lc3wbWeaXtuQ== dependencies: is-obj "^1.0.0" -dot-prop@^5.1.0: - version "5.1.1" - resolved "https://registry.yarnpkg.com/dot-prop/-/dot-prop-5.1.1.tgz#85783b39f2a54e04ae1981489a0ef2b9719bbd7d" - integrity sha512-QCHI6Lkf+9fJMpwfAFsTvbiSh6ujoPmhCLiDvD/n4dGtLvHfhuBwPdN6z2x4YSOwwtTcLoO/LP70xELWGF/JVA== +dot-prop@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/dot-prop/-/dot-prop-5.2.0.tgz#c34ecc29556dc45f1f4c22697b6f4904e0cc4fcb" + integrity sha512-uEUyaDKoSQ1M4Oq8l45hSE26SnTxL6snNnqvK/VWx5wJhmff5z0FUVJDKDanor/6w3kzE3i7XZOk+7wC0EXr1A== dependencies: is-obj "^2.0.0" @@ -4281,7 +4586,7 @@ ecc-jsbn@~0.1.1: jsbn "~0.1.0" safer-buffer "^2.1.0" -ecdsa-sig-formatter@1.0.11: +ecdsa-sig-formatter@1.0.11, ecdsa-sig-formatter@^1.0.11: version "1.0.11" resolved "https://registry.yarnpkg.com/ecdsa-sig-formatter/-/ecdsa-sig-formatter-1.0.11.tgz#ae0f0fa2d85045ef14a817daa3ce9acd0489e5bf" integrity sha512-nagl3RYrbNv6kQkeJIpt6NJZy8twLB/2vtz6yN9Z4vRKHN4/QZJIEbqohALSgwKdnksuY3k5Addp5lg8sVoVcQ== @@ -4293,15 +4598,15 @@ ee-first@1.1.1: resolved "https://registry.yarnpkg.com/ee-first/-/ee-first-1.1.1.tgz#590c61156b0ae2f4f0255732a158b266bc56b21d" integrity sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0= -electron-to-chromium@^1.3.247: - version "1.3.280" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.280.tgz#5f8950c8329e3e11b59c705fd59b4b8d9b3de5b9" - integrity sha512-qYWNMjKLEfQAWZF2Sarvo+ahigu0EArnpCFSoUuZJS3W5wIeVfeEvsgmT2mgIrieQkeQ0+xFmykK3nx2ezekPQ== +electron-to-chromium@^1.3.247, electron-to-chromium@^1.3.413: + version "1.3.451" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.451.tgz#0c075af3e2f06d706670bde0279432802ca8c83f" + integrity sha512-2fvco0F2bBIgqzO8GRP0Jt/91pdrf9KfZ5FsmkYkjERmIJG585cFeFZV4+CO6oTmU3HmCTgfcZuEa7kW8VUh3A== -elliptic@^6.0.0, elliptic@^6.5.1: - version "6.5.1" - resolved "https://registry.yarnpkg.com/elliptic/-/elliptic-6.5.1.tgz#c380f5f909bf1b9b4428d028cd18d3b0efd6b52b" - integrity sha512-xvJINNLbTeWQjrl6X+7eQCrIy/YPv5XCpKW6kB5mKvtnGILoLDcySuwomfdzt0BMdLNVnuRNTuzKNHj0bva1Cg== +elliptic@^6.0.0, elliptic@^6.5.1, elliptic@^6.5.2: + version "6.5.2" + resolved "https://registry.yarnpkg.com/elliptic/-/elliptic-6.5.2.tgz#05c5678d7173c049d8ca433552224a495d0e3762" + integrity sha512-f4x70okzZbIQl/NSRLkI/+tteV/9WqL98zx+SQ69KbXxmVrmjwsNUPn/gYJJ0sHvEak24cZgHIPegRePAtA/xw== dependencies: bn.js "^4.4.0" brorand "^1.0.1" @@ -4316,11 +4621,21 @@ emoji-regex@^7.0.1, emoji-regex@^7.0.2: resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-7.0.3.tgz#933a04052860c85e83c122479c4748a8e4c72156" integrity sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA== +emoji-regex@^8.0.0: + version "8.0.0" + resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" + integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== + emojis-list@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/emojis-list/-/emojis-list-2.1.0.tgz#4daa4d9db00f9819880c79fa457ae5b09a1fd389" integrity sha1-TapNnbAPmBmIDHn6RXrlsJof04k= +emojis-list@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/emojis-list/-/emojis-list-3.0.0.tgz#5570662046ad29e2e916e71aae260abdff4f6a78" + integrity sha512-/kyM18EfinwXZbno9FyUGeFh87KC8HRQBQGildHZbEuRyWFOmv1U10o9BBp8XVZDVNNuQKyIGIu5ZYAAXJ0V2Q== + enabled@1.0.x: version "1.0.2" resolved "https://registry.yarnpkg.com/enabled/-/enabled-1.0.2.tgz#965f6513d2c2d1c5f4652b64a2e3396467fc2f93" @@ -4360,14 +4675,14 @@ entities@^1.1.1: integrity sha512-f2LZMYl1Fzu7YSBKg+RoROelpOaNrcGmE9AZubeDfrCEia483oW4MI4VyFd5VNHIgQ/7qm1I0wUHK1eJnn2y2w== entities@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/entities/-/entities-2.0.0.tgz#68d6084cab1b079767540d80e56a39b423e4abf4" - integrity sha512-D9f7V0JSRwIxlRI2mjMqufDrRDnx8p+eEOz7aUM9SuvF8gsBzra0/6tbjl1m8eQHrZlYj6PxqE00hZ1SAIKPLw== + version "2.0.2" + resolved "https://registry.yarnpkg.com/entities/-/entities-2.0.2.tgz#ac74db0bba8d33808bbf36809c3a5c3683531436" + integrity sha512-dmD3AvJQBUjKpcNkoqr+x+IF0SdRtPz9Vk0uTy4yWqga9ibB6s4v++QFWNohjiUGoMlF552ZvNyXDxz5iW0qmw== env-variable@0.0.x: - version "0.0.5" - resolved "https://registry.yarnpkg.com/env-variable/-/env-variable-0.0.5.tgz#913dd830bef11e96a039c038d4130604eba37f88" - integrity sha512-zoB603vQReOFvTg5xMl9I1P2PnHsHQQKTEowsKKD7nseUfJq6UWzK+4YtlWUO1nhiQUxe6XMkk+JleSZD1NZFA== + version "0.0.6" + resolved "https://registry.yarnpkg.com/env-variable/-/env-variable-0.0.6.tgz#74ab20b3786c545b62b4a4813ab8cf22726c9808" + integrity sha512-bHz59NlBbtS0NhftmR8+ExBEekE7br0e01jw+kk0NDro7TtZzBYZ5ScGPs3OmwnpyfHTHOtr1Y6uedCdrIldtg== errno@^0.1.3, errno@~0.1.7: version "0.1.7" @@ -4383,39 +4698,40 @@ error-ex@^1.2.0, error-ex@^1.3.1: dependencies: is-arrayish "^0.2.1" -es-abstract@^1.12.0, es-abstract@^1.13.0, es-abstract@^1.15.0, es-abstract@^1.5.1, es-abstract@^1.7.0: - version "1.15.0" - resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.15.0.tgz#8884928ec7e40a79e3c9bc812d37d10c8b24cc57" - integrity sha512-bhkEqWJ2t2lMeaJDuk7okMkJWI/yqgH/EoGwpcvv0XW9RWQsRspI4wt6xuyuvMvvQE3gg/D9HXppgk21w78GyQ== +es-abstract@^1.17.0, es-abstract@^1.17.0-next.1, es-abstract@^1.17.2, es-abstract@^1.17.4, es-abstract@^1.17.5: + version "1.17.5" + resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.17.5.tgz#d8c9d1d66c8981fb9200e2251d799eee92774ae9" + integrity sha512-BR9auzDbySxOcfog0tLECW8l28eRGpDpU3Dm3Hp4q/N+VtLTmyj4EUN088XZWQDW/hzj6sYRDXeOFsaAODKvpg== dependencies: - es-to-primitive "^1.2.0" + es-to-primitive "^1.2.1" function-bind "^1.1.1" has "^1.0.3" - has-symbols "^1.0.0" - is-callable "^1.1.4" - is-regex "^1.0.4" - object-inspect "^1.6.0" + has-symbols "^1.0.1" + is-callable "^1.1.5" + is-regex "^1.0.5" + object-inspect "^1.7.0" object-keys "^1.1.1" - string.prototype.trimleft "^2.1.0" - string.prototype.trimright "^2.1.0" + object.assign "^4.1.0" + string.prototype.trimleft "^2.1.1" + string.prototype.trimright "^2.1.1" -es-to-primitive@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/es-to-primitive/-/es-to-primitive-1.2.0.tgz#edf72478033456e8dda8ef09e00ad9650707f377" - integrity sha512-qZryBOJjV//LaxLTV6UC//WewneB3LcXOL9NP++ozKVXsIIIpm/2c13UDiD9Jp2eThsecw9m3jPqDwTyobcdbg== +es-to-primitive@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/es-to-primitive/-/es-to-primitive-1.2.1.tgz#e55cd4c9cdc188bcefb03b366c736323fc5c898a" + integrity sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA== dependencies: is-callable "^1.1.4" is-date-object "^1.0.1" is-symbol "^1.0.2" -es5-ext@^0.10.35, es5-ext@^0.10.50, es5-ext@^0.10.51: - version "0.10.51" - resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.51.tgz#ed2d7d9d48a12df86e0299287e93a09ff478842f" - integrity sha512-oRpWzM2WcLHVKpnrcyB7OW8j/s67Ba04JCm0WnNv3RiABSvs7mrQlutB8DBv793gKcp0XENR8Il8WxGTlZ73gQ== +es5-ext@^0.10.35, es5-ext@^0.10.50: + version "0.10.53" + resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.53.tgz#93c5a3acfdbef275220ad72644ad02ee18368de1" + integrity sha512-Xs2Stw6NiNHWypzRTY1MtaG/uJlwCk8kH81920ma8mvN8Xq1gsfhZvpkImLQArw8AHnv8MT2I45J3c0R8slE+Q== dependencies: es6-iterator "~2.0.3" - es6-symbol "~3.1.1" - next-tick "^1.0.0" + es6-symbol "~3.1.3" + next-tick "~1.0.0" es6-iterator@2.0.3, es6-iterator@~2.0.3: version "2.0.3" @@ -4438,13 +4754,13 @@ es6-promisify@^5.0.0: dependencies: es6-promise "^4.0.3" -es6-symbol@^3.1.1, es6-symbol@~3.1.1: - version "3.1.2" - resolved "https://registry.yarnpkg.com/es6-symbol/-/es6-symbol-3.1.2.tgz#859fdd34f32e905ff06d752e7171ddd4444a7ed1" - integrity sha512-/ZypxQsArlv+KHpGvng52/Iz8by3EQPxhmbuz8yFG89N/caTFBSbcXONDw0aMjy827gQg26XAjP4uXFvnfINmQ== +es6-symbol@^3.1.1, es6-symbol@~3.1.3: + version "3.1.3" + resolved "https://registry.yarnpkg.com/es6-symbol/-/es6-symbol-3.1.3.tgz#bad5d3c1bcdac28269f4cb331e431c78ac705d18" + integrity sha512-NJ6Yn3FuDinBaBRWl/q5X/s4koRHBrgKAu+yGI6JCBeiu3qrcbJhwT2GeR/EXVfylRk8dpQVJoLEFhK+Mu31NA== dependencies: d "^1.0.1" - es5-ext "^0.10.51" + ext "^1.1.2" escape-html@^1.0.3, escape-html@~1.0.3: version "1.0.3" @@ -4457,11 +4773,11 @@ escape-string-regexp@1.0.5, escape-string-regexp@^1.0.2, escape-string-regexp@^1 integrity sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ= escodegen@^1.11.0, escodegen@^1.9.1: - version "1.12.0" - resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.12.0.tgz#f763daf840af172bb3a2b6dd7219c0e17f7ff541" - integrity sha512-TuA+EhsanGcme5T3R0L80u4t8CpbXQjegRmf7+FPTJrtCTErXFeelblRgHQa1FofEzqYYJmJ/OqjTwREp9qgmg== + version "1.14.1" + resolved "https://registry.yarnpkg.com/escodegen/-/escodegen-1.14.1.tgz#ba01d0c8278b5e95a9a45350142026659027a457" + integrity sha512-Bmt7NcRySdIfNPfU2ZoXDrrXsG9ZjvDxcAlMfDUgRBjLOWTuIACXPBFJH7Z+cLb40JeQco5toikyc9t9P8E9SQ== dependencies: - esprima "^3.1.3" + esprima "^4.0.1" estraverse "^4.2.0" esutils "^2.0.2" optionator "^0.8.1" @@ -4469,19 +4785,19 @@ escodegen@^1.11.0, escodegen@^1.9.1: source-map "~0.6.1" eslint-config-react-app@^5.0.2: - version "5.0.2" - resolved "https://registry.yarnpkg.com/eslint-config-react-app/-/eslint-config-react-app-5.0.2.tgz#df40d73a1402986030680c040bbee520db5a32a4" - integrity sha512-VhlESAQM83uULJ9jsvcKxx2Ab0yrmjUt8kDz5DyhTQufqWE0ssAnejlWri5LXv25xoXfdqOyeDPdfJS9dXKagQ== + version "5.2.1" + resolved "https://registry.yarnpkg.com/eslint-config-react-app/-/eslint-config-react-app-5.2.1.tgz#698bf7aeee27f0cea0139eaef261c7bf7dd623df" + integrity sha512-pGIZ8t0mFLcV+6ZirRgYK6RVqUIKRIi9MmgzUEmrIknsn3AdO0I32asO86dJgloHq+9ZPl8UIg8mYrvgP5u2wQ== dependencies: confusing-browser-globals "^1.0.9" eslint-import-resolver-node@^0.3.2: - version "0.3.2" - resolved "https://registry.yarnpkg.com/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.2.tgz#58f15fb839b8d0576ca980413476aab2472db66a" - integrity sha512-sfmTqJfPSizWu4aymbPr4Iidp5yKm8yDkHp+Ir3YiTHiiDfxh69mOUsmiqW6RZ9zRXFaF64GtYmN7e+8GHBv6Q== + version "0.3.3" + resolved "https://registry.yarnpkg.com/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.3.tgz#dbaa52b6b2816b50bc6711af75422de808e98404" + integrity sha512-b8crLDo0M5RSe5YG8Pu2DYBj71tSB6OvXkfzwbJU2w7y8P4/yo0MyF8jU26IEuEuHF2K5/gcAJE3LhQGqBBbVg== dependencies: debug "^2.6.9" - resolve "^1.5.0" + resolve "^1.13.1" eslint-loader@3.0.2: version "3.0.2" @@ -4495,11 +4811,11 @@ eslint-loader@3.0.2: schema-utils "^2.2.0" eslint-module-utils@^2.4.0: - version "2.4.1" - resolved "https://registry.yarnpkg.com/eslint-module-utils/-/eslint-module-utils-2.4.1.tgz#7b4675875bf96b0dbf1b21977456e5bb1f5e018c" - integrity sha512-H6DOj+ejw7Tesdgbfs4jeS4YMFrT8uI8xwd1gtQqXssaR0EQ26L+2O/w6wkYFy2MymON0fTwHmXBvvfLNZVZEw== + version "2.6.0" + resolved "https://registry.yarnpkg.com/eslint-module-utils/-/eslint-module-utils-2.6.0.tgz#579ebd094f56af7797d19c9866c9c9486629bfa6" + integrity sha512-6j9xxegbqe8/kZY8cYpcp0xhbK0EgJlg3g9mib3/miLaExuuwc3n5UEfSnU6hWMbT0FAYVvDbL9RrRgpUeQIvA== dependencies: - debug "^2.6.8" + debug "^2.6.9" pkg-dir "^2.0.0" eslint-plugin-flowtype@3.13.0: @@ -4577,12 +4893,19 @@ eslint-scope@^5.0.0: esrecurse "^4.1.0" estraverse "^4.1.1" -eslint-utils@^1.4.2: - version "1.4.2" - resolved "https://registry.yarnpkg.com/eslint-utils/-/eslint-utils-1.4.2.tgz#166a5180ef6ab7eb462f162fd0e6f2463d7309ab" - integrity sha512-eAZS2sEUMlIeCjBeubdj45dmBHQwPHWyBcT1VSYB7o9x9WRRqKxyUoiXlRjyAwzN7YEzHJlYg0NmzDRWx6GP4Q== +eslint-utils@^1.4.3: + version "1.4.3" + resolved "https://registry.yarnpkg.com/eslint-utils/-/eslint-utils-1.4.3.tgz#74fec7c54d0776b6f67e0251040b5806564e981f" + integrity sha512-fbBN5W2xdY45KulGXmLHZ3c3FHfVYmKg0IrAKGOkT/464PQsx2UeIzfz1RmEci+KLm1bBaAzZAh8+/E+XAeZ8Q== dependencies: - eslint-visitor-keys "^1.0.0" + eslint-visitor-keys "^1.1.0" + +eslint-utils@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/eslint-utils/-/eslint-utils-2.0.0.tgz#7be1cc70f27a72a76cd14aa698bcabed6890e1cd" + integrity sha512-0HCPuJv+7Wv1bACm8y5/ECVfYdfsAm9xmVb7saeFlxjPYALefjhbYoCkBjPdPzGH8wWyTpAez82Fh3VKYEZ8OA== + dependencies: + eslint-visitor-keys "^1.1.0" eslint-visitor-keys@^1.0.0, eslint-visitor-keys@^1.1.0: version "1.1.0" @@ -4590,9 +4913,9 @@ eslint-visitor-keys@^1.0.0, eslint-visitor-keys@^1.1.0: integrity sha512-8y9YjtM1JBJU/A9Kc+SbaOV4y29sSWckBwMHa+FGtVj5gN/sbnKDf6xJUl+8g7FAij9LVaP8C24DUiH/f/2Z9A== eslint@^6.1.0: - version "6.5.1" - resolved "https://registry.yarnpkg.com/eslint/-/eslint-6.5.1.tgz#828e4c469697d43bb586144be152198b91e96ed6" - integrity sha512-32h99BoLYStT1iq1v2P9uwpyznQ4M2jRiFB6acitKz52Gqn+vPaMDUTB1bYi1WN4Nquj2w+t+bimYUG83DC55A== + version "6.8.0" + resolved "https://registry.yarnpkg.com/eslint/-/eslint-6.8.0.tgz#62262d6729739f9275723824302fb227c8c93ffb" + integrity sha512-K+Iayyo2LtyYhDSYwz5D5QdWw0hCacNzyq1Y821Xna2xSJj7cijoLLYmLxTQgcgZ9mC61nryMy9S7GRbYpI5Ig== dependencies: "@babel/code-frame" "^7.0.0" ajv "^6.10.0" @@ -4601,19 +4924,19 @@ eslint@^6.1.0: debug "^4.0.1" doctrine "^3.0.0" eslint-scope "^5.0.0" - eslint-utils "^1.4.2" + eslint-utils "^1.4.3" eslint-visitor-keys "^1.1.0" - espree "^6.1.1" + espree "^6.1.2" esquery "^1.0.1" esutils "^2.0.2" file-entry-cache "^5.0.1" functional-red-black-tree "^1.0.1" glob-parent "^5.0.0" - globals "^11.7.0" + globals "^12.1.0" ignore "^4.0.6" import-fresh "^3.0.0" imurmurhash "^0.1.4" - inquirer "^6.4.1" + inquirer "^7.0.0" is-glob "^4.0.0" js-yaml "^3.13.1" json-stable-stringify-without-jsonify "^1.0.1" @@ -4622,7 +4945,7 @@ eslint@^6.1.0: minimatch "^3.0.4" mkdirp "^0.5.1" natural-compare "^1.4.0" - optionator "^0.8.2" + optionator "^0.8.3" progress "^2.0.0" regexpp "^2.0.1" semver "^6.1.2" @@ -4632,31 +4955,26 @@ eslint@^6.1.0: text-table "^0.2.0" v8-compile-cache "^2.0.3" -espree@^6.1.1: - version "6.1.1" - resolved "https://registry.yarnpkg.com/espree/-/espree-6.1.1.tgz#7f80e5f7257fc47db450022d723e356daeb1e5de" - integrity sha512-EYbr8XZUhWbYCqQRW0duU5LxzL5bETN6AjKBGy1302qqzPaCH10QbRg3Wvco79Z8x9WbiE8HYB4e75xl6qUYvQ== +espree@^6.1.2: + version "6.2.1" + resolved "https://registry.yarnpkg.com/espree/-/espree-6.2.1.tgz#77fc72e1fd744a2052c20f38a5b575832e82734a" + integrity sha512-ysCxRQY3WaXJz9tdbWOwuWr5Y/XrPTGX9Kiz3yoUXwW0VZ4w30HTkQLaGx/+ttFjF8i+ACbArnB4ce68a9m5hw== dependencies: - acorn "^7.0.0" - acorn-jsx "^5.0.2" + acorn "^7.1.1" + acorn-jsx "^5.2.0" eslint-visitor-keys "^1.1.0" -esprima@^3.1.3: - version "3.1.3" - resolved "https://registry.yarnpkg.com/esprima/-/esprima-3.1.3.tgz#fdca51cee6133895e3c88d535ce49dbff62a4633" - integrity sha1-/cpRzuYTOJXjyI1TXOSdv/YqRjM= - -esprima@^4.0.0: +esprima@^4.0.0, esprima@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/esprima/-/esprima-4.0.1.tgz#13b04cdb3e6c5d19df91ab6987a8695619b0aa71" integrity sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A== esquery@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.0.1.tgz#406c51658b1f5991a5f9b62b1dc25b00e3e5c708" - integrity sha512-SmiyZ5zIWH9VM+SRUReLS5Q8a7GxtRdxEBVZpm98rJM7Sb+A9DVCndXfkeFUd3byderg+EbDkfnevfCwynWaNA== + version "1.3.1" + resolved "https://registry.yarnpkg.com/esquery/-/esquery-1.3.1.tgz#b78b5828aa8e214e29fb74c4d5b752e1c033da57" + integrity sha512-olpvt9QG0vniUBZspVRN6lwB7hOZoTRtT+jzR+tS4ffYx2mzbw+z0XCOk44aaLYKApNX5nMm+E+P6o25ip/DHQ== dependencies: - estraverse "^4.0.0" + estraverse "^5.1.0" esrecurse@^4.1.0: version "4.2.1" @@ -4665,12 +4983,17 @@ esrecurse@^4.1.0: dependencies: estraverse "^4.1.0" -estraverse@^4.0.0, estraverse@^4.1.0, estraverse@^4.1.1, estraverse@^4.2.0: +estraverse@^4.1.0, estraverse@^4.1.1, estraverse@^4.2.0: version "4.3.0" resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-4.3.0.tgz#398ad3f3c5a24948be7725e83d11a7de28cdbd1d" integrity sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw== -esutils@^2.0.0, esutils@^2.0.2: +estraverse@^5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/estraverse/-/estraverse-5.1.0.tgz#374309d39fd935ae500e7b92e8a6b4c720e59642" + integrity sha512-FyohXK+R0vE+y1nHLoBM7ZTyqRpqAlhdZHCWIWEviFLiGB8b04H6bQs8G+XTthacvT8VuwvteiP7RJSxMs8UEw== + +esutils@^2.0.2: version "2.0.3" resolved "https://registry.yarnpkg.com/esutils/-/esutils-2.0.3.tgz#74d2eb4de0b8da1293711910d50775b9b710ef64" integrity sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g== @@ -4686,14 +5009,14 @@ event-target-shim@^5.0.0: integrity sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ== eventemitter3@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-4.0.0.tgz#d65176163887ee59f386d64c82610b696a4a74eb" - integrity sha512-qerSRB0p+UDEssxTtm6EDKcE7W4OaoisfIMl4CngyEhjpYglocpNg6UEqCvemdGhosAsg4sO2dXJOdyBifPGCg== + version "4.0.4" + resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-4.0.4.tgz#b5463ace635a083d018bdc7c917b4c5f10a85384" + integrity sha512-rlaVLnVxtxvoyLsQQFBx53YmXHDxRIzzTLbdfxqi4yocpSjAxXwkU0cScM5JgSKMqEhrZpnvQ2D9gjylR0AimQ== events@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/events/-/events-3.0.0.tgz#9a0a0dfaf62893d92b875b8f2698ca4114973e88" - integrity sha512-Dc381HFWJzEOhQ+d8pkNon++bk9h6cdAoAj4iE6Q4y6xgTzySWXlKn05/TVNpjnfRqi/X0EpJEJohPjNI3zpVA== + version "3.1.0" + resolved "https://registry.yarnpkg.com/events/-/events-3.1.0.tgz#84279af1b34cb75aa88bf5ff291f6d0bd9b31a59" + integrity sha512-Rv+u8MLHNOdMjTAFeT3nCjHn2aGlx435FP/sDHNaRhDEMwyI/aB22Kj2qIN8R0cw3z28psEQLYwxVKLsKrMgWg== eventsource@^1.0.7: version "1.0.7" @@ -4711,9 +5034,9 @@ evp_bytestokey@^1.0.0, evp_bytestokey@^1.0.3: safe-buffer "^5.1.1" exec-sh@^0.3.2: - version "0.3.2" - resolved "https://registry.yarnpkg.com/exec-sh/-/exec-sh-0.3.2.tgz#6738de2eb7c8e671d0366aea0b0db8c6f7d7391b" - integrity sha512-9sLAvzhI5nc8TpuQUh4ahMdCrWT00wPWz7j47/emR5+2qEfoZP5zzUXvx+vdx+H6ohhnsYC31iX04QLYJK8zTg== + version "0.3.4" + resolved "https://registry.yarnpkg.com/exec-sh/-/exec-sh-0.3.4.tgz#3a018ceb526cc6f6df2bb504b2bfe8e3a4934ec5" + integrity sha512-sEFIkc61v75sWeOe72qyrqg2Qg0OuLESziUDk/O/z2qgS15y2gWVFrI6f2Qn/qw/0/NCfCEsmNA4zOjkwEZT1A== execa@^0.7.0: version "0.7.0" @@ -4766,10 +5089,10 @@ expand-tilde@^1.2.2: dependencies: os-homedir "^1.0.1" -expect-puppeteer@^4.3.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/expect-puppeteer/-/expect-puppeteer-4.3.0.tgz#732a3c94ab44af0c7d947040ad3e3637a0359bf3" - integrity sha512-p8N/KSVPG9PAOJlftK5f1n3JrULJ6Qq1EQ8r/n9xzkX2NmXbK8PcnJnkSAEzEHrMycELKGnlJV7M5nkgm+wEWA== +expect-puppeteer@^4.4.0: + version "4.4.0" + resolved "https://registry.yarnpkg.com/expect-puppeteer/-/expect-puppeteer-4.4.0.tgz#1c948af08acdd6c8cbdb7f90e617f44d86888886" + integrity sha512-6Ey4Xy2xvmuQu7z7YQtMsaMV0EHJRpVxIDOd5GRrm04/I3nkTKIutELfECsLp6le+b3SSa3cXhPiw6PgqzxYWA== expect@^24.9.0: version "24.9.0" @@ -4794,12 +5117,12 @@ express-prometheus-middleware@^0.8.5: url-value-parser "^2.0.0" express-winston@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/express-winston/-/express-winston-4.0.1.tgz#98c74d099b9a7fdeedc56eb839c223968bc33990" - integrity sha512-HQZ/d2UPuZIr/PNiLOHX+CF2Q9srfBy1GDK7yIJ+MvX6MU49ggM25XynSNmC5RRPlD2ju3Zic+mCTQtixP1gzQ== + version "4.0.3" + resolved "https://registry.yarnpkg.com/express-winston/-/express-winston-4.0.3.tgz#7160ddc6eb8efaa1bfc95a246124b05286096699" + integrity sha512-qzLLaTYAhajzfbR1d/hKT+N4kEoqDXC9wBqth0ygPg+DrM4QRipXDHLkIkaKSeiQ1L/ulezrT+T7lrKS+OcT7g== dependencies: chalk "^2.4.1" - lodash "^4.17.10" + lodash "^4.17.15" express@^4.16.2, express@^4.16.3, express@^4.17.1: version "4.17.1" @@ -4837,6 +5160,13 @@ express@^4.16.2, express@^4.16.3, express@^4.17.1: utils-merge "1.0.1" vary "~1.1.2" +ext@^1.1.2: + version "1.4.0" + resolved "https://registry.yarnpkg.com/ext/-/ext-1.4.0.tgz#89ae7a07158f79d35517882904324077e4379244" + integrity sha512-Key5NIsUxdqKg3vIsdw9dSuXpPCQ297y6wBjL30edxwPgt2E44WcWBZey/ZvUc6sERLTxKdyCu4gZFmUbk1Q7A== + dependencies: + type "^2.0.0" + extend-shallow@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/extend-shallow/-/extend-shallow-2.0.1.tgz#51af7d614ad9a9f610ea1bafbb989d6b1c56890f" @@ -4881,14 +5211,14 @@ extglob@^2.0.4: to-regex "^3.0.1" extract-zip@^1.6.6: - version "1.6.7" - resolved "https://registry.yarnpkg.com/extract-zip/-/extract-zip-1.6.7.tgz#a840b4b8af6403264c8db57f4f1a74333ef81fe9" - integrity sha1-qEC0uK9kAyZMjbV/Txp0Mz74H+k= + version "1.7.0" + resolved "https://registry.yarnpkg.com/extract-zip/-/extract-zip-1.7.0.tgz#556cc3ae9df7f452c493a0cfb51cc30277940927" + integrity sha512-xoh5G1W/PB0/27lXgMQyIhP5DSY/LhoCsOyZgb+6iMmRtCwVBo55uKaMoEYrDCKQhWvqEip5ZPKAc6eFNyf/MA== dependencies: - concat-stream "1.6.2" - debug "2.6.9" - mkdirp "0.5.1" - yauzl "2.4.1" + concat-stream "^1.6.2" + debug "^2.6.9" + mkdirp "^0.5.4" + yauzl "^2.10.0" extsprintf@1.3.0: version "1.3.0" @@ -4900,10 +5230,10 @@ extsprintf@^1.2.0: resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.4.0.tgz#e2689f8f356fad62cca65a3a91c5df5f9551692f" integrity sha1-4mifjzVvrWLMplo6kcXfX5VRaS8= -fast-deep-equal@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-2.0.1.tgz#7b05218ddf9667bf7f370bf7fdb2cb15fdd0aa49" - integrity sha1-ewUhjd+WZ79/Nwv3/bLLFf3Qqkk= +fast-deep-equal@^3.1.1: + version "3.1.1" + resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.1.tgz#545145077c501491e33b15ec408c294376e94ae4" + integrity sha512-8UEa58QDLauDNfpbrX55Q9jrGHThw2ZMdOky5Gl1CDtVeJDPVrG4Jxx1N8jw2gkWaff5UUuX1KJd+9zGe2B+ZA== fast-glob@^2.0.2: version "2.2.7" @@ -4917,17 +5247,12 @@ fast-glob@^2.0.2: merge2 "^1.2.3" micromatch "^3.1.10" -fast-json-stable-stringify@2.x, fast-json-stable-stringify@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz#d5142c0caee6b1189f87d3a76111064f86c8bbf2" - integrity sha1-1RQsDK7msRifh9OnYREGT4bIu/I= - -fast-json-stable-stringify@^2.1.0: +fast-json-stable-stringify@2.x, fast-json-stable-stringify@^2.0.0, fast-json-stable-stringify@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz#874bf69c6f404c2b5d99c481341399fd55892633" integrity sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw== -fast-levenshtein@~2.0.4: +fast-levenshtein@~2.0.6: version "2.0.6" resolved "https://registry.yarnpkg.com/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz#3d8a5c66883a16a30ca8643e851f19baa7797917" integrity sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc= @@ -4938,9 +5263,9 @@ fast-safe-stringify@^2.0.4: integrity sha512-Utm6CdzT+6xsDk2m8S6uL8VHxNwI6Jub+e9NYTcAms28T84pTa25GJQV9j0CY0N1rM8hK4x6grpF2BQf+2qwVA== fast-text-encoding@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/fast-text-encoding/-/fast-text-encoding-1.0.0.tgz#3e5ce8293409cfaa7177a71b9ca84e1b1e6f25ef" - integrity sha512-R9bHCvweUxxwkDwhjav5vxpFvdPGlVngtqmx4pIZfSUhM/Q4NiIUHB456BAf+Q1Nwu3HEZYONtu+Rya+af4jiQ== + version "1.0.2" + resolved "https://registry.yarnpkg.com/fast-text-encoding/-/fast-text-encoding-1.0.2.tgz#ff1ad5677bde049e0f8656aa6083a7ef2c5836e2" + integrity sha512-5rQdinSsycpzvAoHga2EDn+LRX1d5xLFsuNG0Kg61JrAT/tASXcLL0nf/33v+sAxlQcfYmWbTURa1mmAf55jGw== faye-websocket@^0.10.0: version "0.10.0" @@ -4957,16 +5282,16 @@ faye-websocket@~0.11.1: websocket-driver ">=0.5.1" fb-watchman@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/fb-watchman/-/fb-watchman-2.0.0.tgz#54e9abf7dfa2f26cd9b1636c588c1afc05de5d58" - integrity sha1-VOmr99+i8mzZsWNsWIwa/AXeXVg= + version "2.0.1" + resolved "https://registry.yarnpkg.com/fb-watchman/-/fb-watchman-2.0.1.tgz#fc84fb39d2709cf3ff6d743706157bb5708a8a85" + integrity sha512-DkPJKQeY6kKwmuMretBhr7G6Vodr7bFwDYTXIkfG1gjvNpaxBTQV3PbXg6bR1c1UP4jPOX0jHUbbHANL9vRjVg== dependencies: - bser "^2.0.0" + bser "2.1.1" -fd-slicer@~1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/fd-slicer/-/fd-slicer-1.0.1.tgz#8b5bcbd9ec327c5041bf9ab023fd6750f1177e65" - integrity sha1-i1vL2ewyfFBBv5qwI/1nUPEXfmU= +fd-slicer@~1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/fd-slicer/-/fd-slicer-1.1.0.tgz#25c7c89cb1f9077f8891bbe61d8f390eae256f1e" + integrity sha1-JcfInLH5B3+IkbvmHY85Dq4lbx4= dependencies: pend "~1.2.0" @@ -4976,9 +5301,9 @@ fecha@^2.3.3: integrity sha512-lUGBnIamTAwk4znq5BcqsDaxSmZ9nDVJaij6NvRt/Tg4R69gERA+otPKbS86ROw9nxVMw2/mp1fnaiWqbs6Sdg== figgy-pudding@^3.5.1: - version "3.5.1" - resolved "https://registry.yarnpkg.com/figgy-pudding/-/figgy-pudding-3.5.1.tgz#862470112901c727a0e495a80744bd5baa1d6790" - integrity sha512-vNKxJHTEKNThjfrdJwHc7brvM6eVevuO5nTj6ez8ZQ1qbXTvGthucRF7S4vf2cr71QVnT70V34v0S1DyQsti0w== + version "3.5.2" + resolved "https://registry.yarnpkg.com/figgy-pudding/-/figgy-pudding-3.5.2.tgz#b4eee8148abb01dcf1d1ac34367d59e12fa61d6e" + integrity sha512-0btnI/H8f2pavGMN8w40mlSKOfTK2SVJmBfBeVIj3kNw0swwgzyRq0d5TJVOwodFmtvpPeWPN/MCcfuWF0Ezbw== figures@^2.0.0: version "2.0.0" @@ -4987,6 +5312,13 @@ figures@^2.0.0: dependencies: escape-string-regexp "^1.0.5" +figures@^3.0.0: + version "3.2.0" + resolved "https://registry.yarnpkg.com/figures/-/figures-3.2.0.tgz#625c18bd293c604dc4a8ddb2febf0c88341746af" + integrity sha512-yaduQFRKLXYOGgEn6AZau90j3ggSOyiqXU0F9JZfeXYhNa+Jk4X+s45A2zg5jns87GAFa34BBm2kXw4XpNcbdg== + dependencies: + escape-string-regexp "^1.0.5" + file-entry-cache@^5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/file-entry-cache/-/file-entry-cache-5.0.1.tgz#ca0f6efa6dd3d561333fb14515065c2fafdf439c" @@ -5002,6 +5334,11 @@ file-loader@3.0.1: loader-utils "^1.0.2" schema-utils "^1.0.0" +file-uri-to-path@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz#553a7b8446ff6f684359c445f1e37a05dacc33dd" + integrity sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw== + filesize@3.6.1: version "3.6.1" resolved "https://registry.yarnpkg.com/filesize/-/filesize-3.6.1.tgz#090bb3ee01b6f801a8a8be99d31710b3422bb317" @@ -5070,10 +5407,10 @@ find-pkg@^0.1.2: dependencies: find-file-up "^0.1.2" -find-process@^1.4.2: - version "1.4.2" - resolved "https://registry.yarnpkg.com/find-process/-/find-process-1.4.2.tgz#8703cbb542df0e4cd646f581fbcce860d0131c31" - integrity sha512-O83EVJr4dWvHJ7QpUzANNAMeQVKukRzRqRx4AIzdLYRrQorRdbqDwLPigkd9PYPhJRhmNPAoVjOm9bcwSmcZaw== +find-process@^1.4.3: + version "1.4.3" + resolved "https://registry.yarnpkg.com/find-process/-/find-process-1.4.3.tgz#25f9105dc32e42abad4636752c37c51cd57dce45" + integrity sha512-+IA+AUsQCf3uucawyTwMWcY+2M3FXq3BRvw3S+j5Jvydjk31f/+NPWpYZOJs+JUs2GvxH4Yfr6Wham0ZtRLlPA== dependencies: chalk "^2.0.1" commander "^2.11.0" @@ -5111,14 +5448,14 @@ flat-cache@^2.0.1: write "1.0.3" flatted@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/flatted/-/flatted-2.0.1.tgz#69e57caa8f0eacbc281d2e2cb458d46fdb449e08" - integrity sha512-a1hQMktqW9Nmqr5aktAux3JMNqaucxGcjtjWnZLHX7yyPCmlSV3M54nGYbqT8K+0GhF3NBgmJCc3ma+WOgX8Jg== + version "2.0.2" + resolved "https://registry.yarnpkg.com/flatted/-/flatted-2.0.2.tgz#4575b21e2bcee7434aa9be662f4b7b5f9c2b5138" + integrity sha512-r5wGx7YeOwNWNlCA0wQ86zKyDLMQr+/RB8xy74M4hTphfmjlijTSSXGuH8rnvKZnfT9i+75zmd8jcKdMR4O6jA== flatten@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/flatten/-/flatten-1.0.2.tgz#dae46a9d78fbe25292258cc1e780a41d95c03782" - integrity sha1-2uRqnXj74lKSJYzB54CkHZXAN4I= + version "1.0.3" + resolved "https://registry.yarnpkg.com/flatten/-/flatten-1.0.3.tgz#c1283ac9f27b368abc1e36d1ff7b04501a30356b" + integrity sha512-dVsPA/UwQ8+2uoFe5GHtiBMu48dWLTdsuEd7CKGlZlD78r1TTWBvDuFaFGKCo/ZfEr95Uk56vZoX86OsHkUeIg== flush-write-stream@^1.0.0: version "1.1.1" @@ -5136,9 +5473,9 @@ follow-redirects@1.5.10: debug "=3.1.0" follow-redirects@^1.0.0: - version "1.9.0" - resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.9.0.tgz#8d5bcdc65b7108fe1508649c79c12d732dcedb4f" - integrity sha512-CRcPzsSIbXyVDl0QI01muNDu69S8trU4jArW9LpOt2WtC6LyUJetcIrmfHsRBx7/Jb6GHJUiuqyYxPooFfNt6A== + version "1.11.0" + resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.11.0.tgz#afa14f08ba12a52963140fe43212658897bc0ecb" + integrity sha512-KZm0V+ll8PfBrKwMzdo5D13b1bur9Iq9Zd/RMmAoQQcl2PxxFml8cxXPaaPYVbV0RjNjq1CU7zIzAOqtUPudmA== dependencies: debug "^3.0.0" @@ -5178,6 +5515,15 @@ fork-ts-checker-webpack-plugin@1.5.0: tapable "^1.0.0" worker-rpc "^0.1.0" +form-data@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/form-data/-/form-data-3.0.0.tgz#31b7e39c85f1355b7139ee0c647cf0de7f83c682" + integrity sha512-CKMFDglpbMi6PyN+brwB9Q/GOw0eAnsrEZDgcsH5Krhz5Od/haKHAX0NmQfha2zPPz0JpWzA7GJHGSnvCRLWsg== + dependencies: + asynckit "^0.4.0" + combined-stream "^1.0.8" + mime-types "^2.1.12" + form-data@~2.3.2: version "2.3.3" resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.3.tgz#dcce52c05f644f298c6a7ab936bd724ceffbf3a6" @@ -5244,13 +5590,6 @@ fs-extra@^8.1.0: jsonfile "^4.0.0" universalify "^0.1.0" -fs-minipass@^1.2.5: - version "1.2.7" - resolved "https://registry.yarnpkg.com/fs-minipass/-/fs-minipass-1.2.7.tgz#ccff8570841e7fe4265693da88936c55aed7f7c7" - integrity sha512-GWSSJGFy4e9GUeCcbIkED+bgAoFyj7XF1mV8rma3QW4NIqX9Kyx79N/PF61H5udOV3aY1IaMLs6pGbH71nlCTA== - dependencies: - minipass "^2.6.0" - fs-write-stream-atomic@^1.0.8: version "1.0.10" resolved "https://registry.yarnpkg.com/fs-write-stream-atomic/-/fs-write-stream-atomic-1.0.10.tgz#b47df53493ef911df75731e70a9ded0189db40c9" @@ -5272,12 +5611,17 @@ fsevents@2.0.7: integrity sha512-a7YT0SV3RB+DjYcppwVDLtn13UQnmg0SWZS7ezZD0UjnLwXmy8Zm21GMVGLaFGimIqcvyMQaOJBrop8MyOp1kQ== fsevents@^1.2.7: - version "1.2.9" - resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.2.9.tgz#3f5ed66583ccd6f400b5a00db6f7e861363e388f" - integrity sha512-oeyj2H3EjjonWcFjD5NvZNE9Rqe4UW+nQBU2HNeKw0koVLEFIhtyETyAakeAM3de7Z/SW5kcA+fZUait9EApnw== + version "1.2.13" + resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-1.2.13.tgz#f325cb0455592428bcf11b383370ef70e3bfcc38" + integrity sha512-oWb1Z6mkHIskLzEJ/XWX0srkpkTQ7vaopMQkyaEIoq0fmtFVxOthb8cCxeT+p3ynTdkk/RZwbgG4brR5BeWECw== dependencies: + bindings "^1.5.0" nan "^2.12.1" - node-pre-gyp "^0.12.0" + +fsevents@~2.1.2: + version "2.1.3" + resolved "https://registry.yarnpkg.com/fsevents/-/fsevents-2.1.3.tgz#fb738703ae8d2f9fe900c33836ddebee8b97f23e" + integrity sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ== fstream@^1.0.0, fstream@^1.0.12: version "1.0.12" @@ -5295,24 +5639,23 @@ function-bind@^1.1.1: integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== function.prototype.name@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/function.prototype.name/-/function.prototype.name-1.1.1.tgz#6d252350803085abc2ad423d4fe3be2f9cbda392" - integrity sha512-e1NzkiJuw6xqVH7YSdiW/qDHebcmMhPNe6w+4ZYYEg0VA+LaLzx37RimbPLuonHhYGFGPx1ME2nSi74JiaCr/Q== + version "1.1.2" + resolved "https://registry.yarnpkg.com/function.prototype.name/-/function.prototype.name-1.1.2.tgz#5cdf79d7c05db401591dfde83e3b70c5123e9a45" + integrity sha512-C8A+LlHBJjB2AdcRPorc5JvJ5VUoWlXdEHLOJdCI7kjHEtGTpHQUiqMvCIKUwIsGwZX2jZJy761AXsn356bJQg== dependencies: define-properties "^1.1.3" - function-bind "^1.1.1" - functions-have-names "^1.1.1" - is-callable "^1.1.4" + es-abstract "^1.17.0-next.1" + functions-have-names "^1.2.0" functional-red-black-tree@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" integrity sha1-GwqzvVU7Kg1jmdKcDj6gslIHgyc= -functions-have-names@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/functions-have-names/-/functions-have-names-1.1.1.tgz#79d35927f07b8e7103d819fed475b64ccf7225ea" - integrity sha512-U0kNHUoxwPNPWOJaMG7Z00d4a/qZVrFtzWJRaK8V9goaVOCXBSQSJpt3MYGNtkScKEBKovxLjnNdC9MlXwo5Pw== +functions-have-names@^1.2.0: + version "1.2.1" + resolved "https://registry.yarnpkg.com/functions-have-names/-/functions-have-names-1.2.1.tgz#a981ac397fa0c9964551402cdc5533d7a4d52f91" + integrity sha512-j48B/ZI7VKs3sgeI2cZp7WXWmZXu7Iq5pl5/vptV5N2mq+DGFuS/ulaDjtaoLpYzuD6u8UgrUKHfgo7fDTSiBA== gauge@~2.7.3: version "2.7.4" @@ -5328,14 +5671,25 @@ gauge@~2.7.3: strip-ansi "^3.0.1" wide-align "^1.1.0" -gaxios@^2.0.0, gaxios@^2.0.1, gaxios@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/gaxios/-/gaxios-2.1.0.tgz#b5d04ec19bf853d4589ccc2e7d61f0f2ab62afee" - integrity sha512-Gtpb5sdQmb82sgVkT2GnS2n+Kx4dlFwbeMYcDlD395aEvsLCSQXJJcHt7oJ2LrGxDEAeiOkK79Zv2A8Pzt6CFg== +gaxios@^2.0.0, gaxios@^2.1.0: + version "2.3.4" + resolved "https://registry.yarnpkg.com/gaxios/-/gaxios-2.3.4.tgz#eea99353f341c270c5f3c29fc46b8ead56f0a173" + integrity sha512-US8UMj8C5pRnao3Zykc4AAVr+cffoNKRTg9Rsf2GiuZCW69vgJj38VK2PzlPuQU73FZ/nTk9/Av6/JGcE1N9vA== dependencies: abort-controller "^3.0.0" extend "^3.0.2" - https-proxy-agent "^3.0.0" + https-proxy-agent "^5.0.0" + is-stream "^2.0.0" + node-fetch "^2.3.0" + +gaxios@^3.0.0: + version "3.0.3" + resolved "https://registry.yarnpkg.com/gaxios/-/gaxios-3.0.3.tgz#497730758f5b0d43a32ebdbebe5f1bd9f7db7aed" + integrity sha512-PkzQludeIFhd535/yucALT/Wxyj/y2zLyrMwPcJmnLHDugmV49NvAi/vb+VUq/eWztATZCNcb8ue+ywPG+oLuw== + dependencies: + abort-controller "^3.0.0" + extend "^3.0.2" + https-proxy-agent "^5.0.0" is-stream "^2.0.0" node-fetch "^2.3.0" @@ -5346,18 +5700,18 @@ gaze@^1.0.0: dependencies: globule "^1.0.0" -gcp-metadata@^3.2.0: - version "3.2.0" - resolved "https://registry.yarnpkg.com/gcp-metadata/-/gcp-metadata-3.2.0.tgz#27d59660f11de411d35b1edb8a41e81389cab5f6" - integrity sha512-ympv+yQ6k5QuWCuwQqnGEvFGS7MBKdcQdj1i188v3bW9QLFIchTGaBCEZxSQapT0jffdn1vdt8oJhB5VBWQO1Q== +gcp-metadata@^3.4.0: + version "3.5.0" + resolved "https://registry.yarnpkg.com/gcp-metadata/-/gcp-metadata-3.5.0.tgz#6d28343f65a6bbf8449886a0c0e4a71c77577055" + integrity sha512-ZQf+DLZ5aKcRpLzYUyBS3yo3N0JSa82lNDO8rj3nMSlovLcz2riKFBsYgDzeXcv75oo5eqB2lx+B14UvPoCRnA== dependencies: - gaxios "^2.0.1" + gaxios "^2.1.0" json-bigint "^0.3.0" gcs-resumable-upload@^2.2.4: - version "2.3.0" - resolved "https://registry.yarnpkg.com/gcs-resumable-upload/-/gcs-resumable-upload-2.3.0.tgz#7d7eef01df5f45f66975ebc0c268d17d9a2c3b9c" - integrity sha512-PclXJiEngrVx0c4K0LfE1XOxhmOkBEy39Rrhspdn6jAbbwe4OQMZfjo7Z1LHBrh57+bNZeIN4M+BooYppCoHSg== + version "2.3.3" + resolved "https://registry.yarnpkg.com/gcs-resumable-upload/-/gcs-resumable-upload-2.3.3.tgz#02c616ed17eff6676e789910aeab3907d412c5f8" + integrity sha512-sf896I5CC/1AxeaGfSFg3vKMjUq/r+A3bscmVzZm10CElyRanN0XwPu/MxeIO4LSP+9uF6yKzXvNsaTsMXUG6Q== dependencies: abort-controller "^3.0.0" configstore "^5.0.0" @@ -5366,6 +5720,11 @@ gcs-resumable-upload@^2.2.4: pumpify "^2.0.0" stream-events "^1.0.4" +gensync@^1.0.0-beta.1: + version "1.0.0-beta.1" + resolved "https://registry.yarnpkg.com/gensync/-/gensync-1.0.0-beta.1.tgz#58f4361ff987e5ff6e1e7a210827aa371eaac269" + integrity sha512-r8EC6NO1sngH/zdD9fiRDLdcgnbayXah+mLgManTaIZJqEC1MZstmnox8KpnI2/fxQwrp5OpCOYWLp4rBl4Jcg== + get-caller-file@^1.0.1: version "1.0.3" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-1.0.3.tgz#f978fa4c90d1dfe7ff2d6beda2a515e713bdcf4a" @@ -5377,9 +5736,9 @@ get-caller-file@^2.0.1: integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== get-own-enumerable-property-symbols@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/get-own-enumerable-property-symbols/-/get-own-enumerable-property-symbols-3.0.1.tgz#6f7764f88ea11e0b514bd9bd860a132259992ca4" - integrity sha512-09/VS4iek66Dh2bctjRkowueRJbY1JDGR1L/zRxO1Qk8Uxs6PnqaNSqalpizPT+CDjre3hnEsuzvhgomz9qYrA== + version "3.0.2" + resolved "https://registry.yarnpkg.com/get-own-enumerable-property-symbols/-/get-own-enumerable-property-symbols-3.0.2.tgz#b5fde77f22cbe35f390b4e089922c50bce6ef664" + integrity sha512-I0UBV/XOz1XkIJHEUDMZAbzCThU/H8DxmSfmdGcKPnVhu2VfFqr34jr9777IyaTYvxjedWhqVIilEDsCdP5G6g== get-stdin@^4.0.1: version "4.0.1" @@ -5418,10 +5777,10 @@ glob-parent@^3.1.0: is-glob "^3.1.0" path-dirname "^1.0.0" -glob-parent@^5.0.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.0.tgz#5f4c1d1e748d30cd73ad2944b3577a81b081e8c2" - integrity sha512-qjtRgnIVmOfnKUE3NJAQEdk+lKrxfw8t5ke7SXtfMTHcjsBfOfWXCQfdb30zfDoZQ2IRSIiidmjtbHZPZ++Ihw== +glob-parent@^5.0.0, glob-parent@~5.1.0: + version "5.1.1" + resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.1.tgz#b6c1ef417c4e5663ea498f1c45afac6916bbc229" + integrity sha512-FnI+VGOpnlGHWZxthPGR+QhR78fuiK0sNLkHQv+bL9fQi57lNNdquIbna/WrfROrolq8GK5Ek6BiMwqL/voRYQ== dependencies: is-glob "^4.0.1" @@ -5430,19 +5789,7 @@ glob-to-regexp@^0.3.0: resolved "https://registry.yarnpkg.com/glob-to-regexp/-/glob-to-regexp-0.3.0.tgz#8c5a1494d2066c570cc3bfe4496175acc4d502ab" integrity sha1-jFoUlNIGbFcMw7/kSWF1rMTVAqs= -glob@^7.0.0, glob@^7.0.3, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3, glob@^7.1.4, glob@~7.1.1: - version "7.1.4" - resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.4.tgz#aa608a2f6c577ad357e1ae5a5c26d9a8d1969255" - integrity sha512-hkLPepehmnKk41pUGm3sYxoFs/umurYfYJCerbXEyFIWcAzvpipAgVkBqqT9RBKMGjnq6kMuyYwha6csxbiM1A== - dependencies: - fs.realpath "^1.0.0" - inflight "^1.0.4" - inherits "2" - minimatch "^3.0.4" - once "^1.3.0" - path-is-absolute "^1.0.0" - -glob@^7.0.5, glob@^7.1.6: +glob@^7.0.0, glob@^7.0.3, glob@^7.0.5, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3, glob@^7.1.4, glob@^7.1.6, glob@~7.1.1: version "7.1.6" resolved "https://registry.yarnpkg.com/glob/-/glob-7.1.6.tgz#141f33b81a7c2492e125594307480c46679278a6" integrity sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA== @@ -5495,11 +5842,18 @@ global-prefix@^3.0.0: kind-of "^6.0.2" which "^1.3.1" -globals@^11.1.0, globals@^11.7.0: +globals@^11.1.0: version "11.12.0" resolved "https://registry.yarnpkg.com/globals/-/globals-11.12.0.tgz#ab8795338868a0babd8525758018c2a7eb95c42e" integrity sha512-WOBp/EEGUiIsJSp7wcv/y6MO+lV9UoncWqxuFfm8eBwzWNgyfBd6Gz+IeKQ9jCmyhoH99g15M3T+QaVHFjizVA== +globals@^12.1.0: + version "12.4.0" + resolved "https://registry.yarnpkg.com/globals/-/globals-12.4.0.tgz#a18813576a41b00a24a97e7f815918c2e19925f8" + integrity sha512-BWICuzzDvDoH54NHKCseDanAhE3CeDorgDL5MT6LMXXj2WCnd9UC2szdk4AWLfjdgNBCXLUanXYcpBBKOSWGwg== + dependencies: + type-fest "^0.8.1" + globby@8.0.2: version "8.0.2" resolved "https://registry.yarnpkg.com/globby/-/globby-8.0.2.tgz#5697619ccd95c5275dbb2d6faa42087c1a941d8d" @@ -5525,32 +5879,33 @@ globby@^6.1.0: pinkie-promise "^2.0.0" globule@^1.0.0: - version "1.2.1" - resolved "https://registry.yarnpkg.com/globule/-/globule-1.2.1.tgz#5dffb1b191f22d20797a9369b49eab4e9839696d" - integrity sha512-g7QtgWF4uYSL5/dn71WxubOrS7JVGCnFPEnoeChJmBnyR9Mw8nGoEwOgJL/RC2Te0WhbsEUCejfH8SZNJ+adYQ== + version "1.3.1" + resolved "https://registry.yarnpkg.com/globule/-/globule-1.3.1.tgz#90a25338f22b7fbeb527cee63c629aea754d33b9" + integrity sha512-OVyWOHgw29yosRHCHo7NncwR1hW5ew0W/UrvtwvjefVJeQ26q4/8r8FmPsSF1hJ93IgWkyv16pCTz6WblMzm/g== dependencies: glob "~7.1.1" - lodash "~4.17.10" + lodash "~4.17.12" minimatch "~3.0.2" google-auth-library@^5.0.0, google-auth-library@^5.5.0: - version "5.5.1" - resolved "https://registry.yarnpkg.com/google-auth-library/-/google-auth-library-5.5.1.tgz#2bf5ade93cb9d00c860d3fb15798db33b39a53a7" - integrity sha512-zCtjQccWS/EHYyFdXRbfeSGM/gW+d7uMAcVnvXRnjBXON5ijo6s0nsObP0ifqileIDSbZjTlLtgo+UoN8IFJcg== + version "5.10.1" + resolved "https://registry.yarnpkg.com/google-auth-library/-/google-auth-library-5.10.1.tgz#504ec75487ad140e68dd577c21affa363c87ddff" + integrity sha512-rOlaok5vlpV9rSiUu5EpR0vVpc+PhN62oF4RyX/6++DG1VsaulAFEMlDYBLjJDDPI6OcNOCGAKy9UVB/3NIDXg== dependencies: arrify "^2.0.0" base64-js "^1.3.0" + ecdsa-sig-formatter "^1.0.11" fast-text-encoding "^1.0.0" gaxios "^2.1.0" - gcp-metadata "^3.2.0" + gcp-metadata "^3.4.0" gtoken "^4.1.0" - jws "^3.1.5" + jws "^4.0.0" lru-cache "^5.0.0" google-p12-pem@^2.0.0: - version "2.0.2" - resolved "https://registry.yarnpkg.com/google-p12-pem/-/google-p12-pem-2.0.2.tgz#39cae8f6fcbe66a01f00be4ddf2d56b95926fa7b" - integrity sha512-UfnEARfJKI6pbmC1hfFFm+UAcZxeIwTiEcHfqKe/drMsXD/ilnVjF7zgOGpHXyhuvX6jNJK3S8A0hOQjwtFxEw== + version "2.0.4" + resolved "https://registry.yarnpkg.com/google-p12-pem/-/google-p12-pem-2.0.4.tgz#036462394e266472632a78b685f0cc3df4ef337b" + integrity sha512-S4blHBQWZRnEW44OcR7TL9WR+QCqByRvhNDZ/uuQfpxywfupikf/miba8js1jZi6ZOGv5slgSuoshCWh6EMDzg== dependencies: node-forge "^0.9.0" @@ -5572,9 +5927,9 @@ got@^6.7.1: url-parse-lax "^1.0.0" graceful-fs@^4.1.11, graceful-fs@^4.1.15, graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.2.0: - version "4.2.2" - resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.2.tgz#6f0952605d0140c1cfdb138ed005775b92d67b02" - integrity sha512-IItsdsea19BoLC7ELy13q1iJFNmd7ofZH5+X/pJr90/nRoPEX0DJo1dHDbgtYWOhJhcCgMDTOw84RZ72q6lB+Q== + version "4.2.4" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.4.tgz#2256bde14d3632958c465ebc96dc467ca07a29fb" + integrity sha512-WjKPNJF79dtJAVniUlGGWHYGz2jWxT6VhN/4m1NdkbZ2nOsEF+cI1Edgql5zCRhs/VsQYRvrXctxktVXZUkixw== growly@^1.3.0: version "1.3.0" @@ -5582,13 +5937,13 @@ growly@^1.3.0: integrity sha1-8QdIy+dq+WS3yWyTxrzCivEgwIE= gtoken@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/gtoken/-/gtoken-4.1.0.tgz#0b315dd1a925e3ad3c82db1eb5b9e89bae875ba8" - integrity sha512-wqyn2gf5buzEZN4QNmmiiW2i2JkEdZnL7Z/9p44RtZqgt4077m4khRgAYNuu8cBwHWCc6MsP6eDUn/KkF6jFIw== + version "4.1.4" + resolved "https://registry.yarnpkg.com/gtoken/-/gtoken-4.1.4.tgz#925ff1e7df3aaada06611d30ea2d2abf60fcd6a7" + integrity sha512-VxirzD0SWoFUo5p8RDP8Jt2AGyOmyYcT/pOUgDKJCK+iSw0TMqwrVfY37RXTNmoKwrzmDHSk0GMT9FsgVmnVSA== dependencies: - gaxios "^2.0.0" + gaxios "^2.1.0" google-p12-pem "^2.0.0" - jws "^3.1.5" + jws "^4.0.0" mime "^2.2.0" gzip-size@5.1.1: @@ -5600,27 +5955,16 @@ gzip-size@5.1.1: pify "^4.0.1" handle-thing@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/handle-thing/-/handle-thing-2.0.0.tgz#0e039695ff50c93fc288557d696f3c1dc6776754" - integrity sha512-d4sze1JNC454Wdo2fkuyzCr6aHcbL6PGGuFAz0Li/NcOm1tCHGnWDRmJP85dh9IhQErTc2svWFEX5xHIOo//kQ== - -handlebars@^4.1.2: - version "4.4.3" - resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.4.3.tgz#180bae52c1d0e9ec0c15d7e82a4362d662762f6e" - integrity sha512-B0W4A2U1ww3q7VVthTKfh+epHx+q4mCt6iK+zEAzbMBpWQAwxCeKxEGpj/1oQTpzPXDNSOG7hmG14TsISH50yw== - dependencies: - neo-async "^2.6.0" - optimist "^0.6.1" - source-map "^0.6.1" - optionalDependencies: - uglify-js "^3.1.4" + version "2.0.1" + resolved "https://registry.yarnpkg.com/handle-thing/-/handle-thing-2.0.1.tgz#857f79ce359580c340d43081cc648970d0bb234e" + integrity sha512-9Qn4yBxelxoh2Ow62nP+Ka/kMnOXRi8BXnRaUwezLNhqelnN49xKz4F/dPP8OYLxLxq6JDtZb2i9XznUQbNPTg== har-schema@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" integrity sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI= -har-validator@~5.1.0: +har-validator@~5.1.3: version "5.1.3" resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.1.3.tgz#1ef89ebd3e4996557675eed9893110dc350fa080" integrity sha512-sNvOCzEQNr/qrvJgc3UG/kD4QtlHycrzwS+6mfTrrSq97BvaYcPZZI1ZSqGSPR73Cxn4LKTD4PttRwfU7jWq5g== @@ -5645,10 +5989,15 @@ has-flag@^3.0.0: resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" integrity sha1-tdRU3CGZriJWmfNGfloH87lVuv0= -has-symbols@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.0.tgz#ba1a8f1af2a0fc39650f5c850367704122063b44" - integrity sha1-uhqPGvKg/DllD1yFA2dwQSIGO0Q= +has-flag@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" + integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== + +has-symbols@^1.0.0, has-symbols@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.1.tgz#9f5214758a44196c406d9bd76cebf81ec2dd31e8" + integrity sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg== has-unicode@^2.0.0: version "2.0.1" @@ -5686,7 +6035,7 @@ has-values@^1.0.0: is-number "^3.0.0" kind-of "^4.0.0" -has@^1.0.0, has@^1.0.1, has@^1.0.3: +has@^1.0.0, has@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== @@ -5694,17 +6043,18 @@ has@^1.0.0, has@^1.0.1, has@^1.0.3: function-bind "^1.1.1" hash-base@^3.0.0: - version "3.0.4" - resolved "https://registry.yarnpkg.com/hash-base/-/hash-base-3.0.4.tgz#5fc8686847ecd73499403319a6b0a3f3f6ae4918" - integrity sha1-X8hoaEfs1zSZQDMZprCj8/auSRg= + version "3.1.0" + resolved "https://registry.yarnpkg.com/hash-base/-/hash-base-3.1.0.tgz#55c381d9e06e1d2997a883b4a3fddfe7f0d3af33" + integrity sha512-1nmYp/rhMDiE7AYkDw+lLwlAzz0AntGIe51F3RfFfEqyQ3feY2eI/NcwC6umIQVOASPMsWJLJScWKSSvzL9IVA== dependencies: - inherits "^2.0.1" - safe-buffer "^5.0.1" + inherits "^2.0.4" + readable-stream "^3.6.0" + safe-buffer "^5.2.0" hash-stream-validation@^0.2.2: - version "0.2.2" - resolved "https://registry.yarnpkg.com/hash-stream-validation/-/hash-stream-validation-0.2.2.tgz#6b34c4fce5e9fce265f1d3380900049d92a10090" - integrity sha512-cMlva5CxWZOrlS/cY0C+9qAzesn5srhFA8IT1VPiHc9bWWBLkJfEUIZr7MWoi89oOOGmpg8ymchaOjiArsGu5A== + version "0.2.3" + resolved "https://registry.yarnpkg.com/hash-stream-validation/-/hash-stream-validation-0.2.3.tgz#44e3479d1767c4f1d6924cc2da61eca08ebba8af" + integrity sha512-OEohGLoUOh+bwsIpHpdvhIXFyRGjeLqJbT8Yc5QTZPbRM7LKywagTQxnX/6mghLDOrD9YGz88hy5mLN2eKflYQ== dependencies: through2 "^2.0.0" @@ -5736,9 +6086,9 @@ hmac-drbg@^1.0.0: minimalistic-crypto-utils "^1.0.1" hoist-non-react-statics@^3.3.0: - version "3.3.0" - resolved "https://registry.yarnpkg.com/hoist-non-react-statics/-/hoist-non-react-statics-3.3.0.tgz#b09178f0122184fb95acf525daaecb4d8f45958b" - integrity sha512-0XsbTXxgiaCDYDIWFcwkmerZPSwywfUqYmwT4jzewKTQSWoE6FCMoUVOeBJWK3E/CrWbxRG3m5GzY4lnIwGRBA== + version "3.3.2" + resolved "https://registry.yarnpkg.com/hoist-non-react-statics/-/hoist-non-react-statics-3.3.2.tgz#ece0acaf71d62c2969c2ec59feff42a4b1a85b45" + integrity sha512-/gGivxi8JPKWNm/W0jSmzcMPpfpPLc3dY/6GxhX2hQ9iGj3aDfklV4ET7NjKpSinLpJ5vafa9iiGIEZg10SfBw== dependencies: react-is "^16.7.0" @@ -5750,9 +6100,9 @@ homedir-polyfill@^1.0.0: parse-passwd "^1.0.0" hosted-git-info@^2.1.4: - version "2.8.5" - resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.8.5.tgz#759cfcf2c4d156ade59b0b2dfabddc42a6b9c70c" - integrity sha512-kssjab8CvdXfcXMXVcvsXum4Hwdq9XGtRD3TteMEvEbq0LXyiNQr6AprqKqfeaDXze7SxWvRxdpwE6ku7ikLkg== + version "2.8.8" + resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.8.8.tgz#7539bd4bc1e0e0a895815a2e0262420b12858488" + integrity sha512-f/wzC2QaWBs7t9IYqB4T3sR1xviIViXJRJTWBlx2Gf3g0Xi5vI7Yy4koXQ1c9OYDGHN9sBy1DQ2AB8fqZBWhUg== hpack.js@^2.1.6: version "2.1.6" @@ -5787,9 +6137,14 @@ html-encoding-sniffer@^1.0.2: whatwg-encoding "^1.0.1" html-entities@^1.2.0: - version "1.2.1" - resolved "https://registry.yarnpkg.com/html-entities/-/html-entities-1.2.1.tgz#0df29351f0721163515dfb9e5543e5f6eed5162f" - integrity sha1-DfKTUfByEWNRXfueVUPl9u7VFi8= + version "1.3.1" + resolved "https://registry.yarnpkg.com/html-entities/-/html-entities-1.3.1.tgz#fb9a1a4b5b14c5daba82d3e34c6ae4fe701a0e44" + integrity sha512-rhE/4Z3hIhzHAUKbW8jVcCyuT5oJCXXqhN/6mXXVCpzTmvJnoH2HL/bt3EZ6p55jbFJBeAe1ZNpL5BugLujxNA== + +html-escaper@^2.0.0: + version "2.0.2" + resolved "https://registry.yarnpkg.com/html-escaper/-/html-escaper-2.0.2.tgz#dfd60027da36a36dfcbe236262c00a5822681453" + integrity sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg== html-minifier@^3.5.20: version "3.5.21" @@ -5816,7 +6171,7 @@ html-webpack-plugin@4.0.0-beta.5: tapable "^1.1.0" util.promisify "1.0.0" -htmlparser2@^3.10.0, htmlparser2@^3.3.0: +htmlparser2@^3.3.0: version "3.10.1" resolved "https://registry.yarnpkg.com/htmlparser2/-/htmlparser2-3.10.1.tgz#bd679dc3f59897b6a34bb10749c855bb53a9392f" integrity sha512-IgieNijUMbkDovyoKObU1DUhm1iwNYE/fuifEoEHfd1oZKZDaONBSkal7Y01shxsM49R4XaMdGez3WnF9UfiCQ== @@ -5828,6 +6183,16 @@ htmlparser2@^3.10.0, htmlparser2@^3.3.0: inherits "^2.0.1" readable-stream "^3.1.1" +htmlparser2@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/htmlparser2/-/htmlparser2-4.1.0.tgz#9a4ef161f2e4625ebf7dfbe6c0a2f52d18a59e78" + integrity sha512-4zDq1a1zhE4gQso/c5LP1OtrhYTncXNSpvJYtWJBtXAETPlMfi3IFNjGuQbYLuVY4ZR0QMqRVvo4Pdy9KLyP8Q== + dependencies: + domelementtype "^2.0.1" + domhandler "^3.0.0" + domutils "^2.0.0" + entities "^2.0.0" + http-deceiver@^1.2.7: version "1.2.7" resolved "https://registry.yarnpkg.com/http-deceiver/-/http-deceiver-1.2.7.tgz#fa7168944ab9a519d337cb0bec7284dc3e723d87" @@ -5865,25 +6230,26 @@ http-errors@~1.7.2: statuses ">= 1.5.0 < 2" toidentifier "1.0.0" -"http-parser-js@>=0.4.0 <0.4.11": - version "0.4.10" - resolved "https://registry.yarnpkg.com/http-parser-js/-/http-parser-js-0.4.10.tgz#92c9c1374c35085f75db359ec56cc257cbb93fa4" - integrity sha1-ksnBN0w1CF912zWexWzCV8u5P6Q= +http-parser-js@>=0.5.1: + version "0.5.2" + resolved "https://registry.yarnpkg.com/http-parser-js/-/http-parser-js-0.5.2.tgz#da2e31d237b393aae72ace43882dd7e270a8ff77" + integrity sha512-opCO9ASqg5Wy2FNo7A0sxy71yGbbkJJXLdgMK04Tcypw9jr2MgWbyubb0+WdmDmGnFflO7fRbqbaihh/ENDlRQ== -http-proxy-agent@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/http-proxy-agent/-/http-proxy-agent-2.1.0.tgz#e4821beef5b2142a2026bd73926fe537631c5405" - integrity sha512-qwHbBLV7WviBl0rQsOzH6o5lwyOIvwp/BdFnvVxXORldu5TmjFfjzBcWUWS5kWAZhmv+JtiDhSuQCp4sBfbIgg== +http-proxy-agent@^4.0.0: + version "4.0.1" + resolved "https://registry.yarnpkg.com/http-proxy-agent/-/http-proxy-agent-4.0.1.tgz#8a8c8ef7f5932ccf953c296ca8291b95aa74aa3a" + integrity sha512-k0zdNgqWTGA6aeIRVpvfVob4fL52dTfaehylg0Y4UvSySvOq/Y+BOyPrgpUrA7HylqvU8vIZGsRuXmspskV0Tg== dependencies: - agent-base "4" - debug "3.1.0" + "@tootallnate/once" "1" + agent-base "6" + debug "4" http-proxy-middleware@^0.19.1: - version "0.19.1" - resolved "https://registry.yarnpkg.com/http-proxy-middleware/-/http-proxy-middleware-0.19.1.tgz#183c7dc4aa1479150306498c210cdaf96080a43a" - integrity sha512-yHYTgWMQO8VvwNS22eLLloAkvungsKdKTLO8AJlftYIKNfJr3GK3zK0ZCfzDDGUBttdGc8xFy1mCitvNKQtC3Q== + version "0.19.2" + resolved "https://registry.yarnpkg.com/http-proxy-middleware/-/http-proxy-middleware-0.19.2.tgz#ee73dcc8348165afefe8de2ff717751d181608ee" + integrity sha512-aYk1rTKqLTus23X3L96LGNCGNgWpG4cG0XoZIT1GUPhhulEHX/QalnO6Vbo+WmKWi4AL2IidjuC0wZtbpg0yhQ== dependencies: - http-proxy "^1.17.0" + http-proxy "^1.18.1" is-glob "^4.0.0" lodash "^4.17.11" micromatch "^3.1.10" @@ -5898,10 +6264,10 @@ http-proxy-middleware@^0.20.0: lodash "^4.17.14" micromatch "^4.0.2" -http-proxy@^1.17.0: - version "1.18.0" - resolved "https://registry.yarnpkg.com/http-proxy/-/http-proxy-1.18.0.tgz#dbe55f63e75a347db7f3d99974f2692a314a6a3a" - integrity sha512-84I2iJM/n1d4Hdgc6y2+qY5mDaz2PUVjlg9znE9byl+q0uC3DeByqBGReQu5tpLK0TAqTIXScRUV+dg7+bUPpQ== +http-proxy@^1.17.0, http-proxy@^1.18.1: + version "1.18.1" + resolved "https://registry.yarnpkg.com/http-proxy/-/http-proxy-1.18.1.tgz#401541f0534884bbf95260334e72f88ee3976549" + integrity sha512-7mz/721AbnJwIVbnaSv1Cz3Am0ZLT/UBwkC92VlxhXv/k/BBQfM2fXElQNC27BVGr0uwUpplYPQM9LnaBMR5NQ== dependencies: eventemitter3 "^4.0.0" follow-redirects "^1.0.0" @@ -5922,22 +6288,22 @@ https-browserify@^1.0.0: integrity sha1-7AbBDgo0wPL68Zn3/X/Hj//QPHM= https-proxy-agent@^2.2.1: - version "2.2.3" - resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-2.2.3.tgz#fb6cd98ed5b9c35056b5a73cd01a8a721d7193d1" - integrity sha512-Ytgnz23gm2DVftnzqRRz2dOXZbGd2uiajSw/95bPp6v53zPRspQjLm/AfBgqbJ2qfeRXWIOMVLpp86+/5yX39Q== + version "2.2.4" + resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-2.2.4.tgz#4ee7a737abd92678a293d9b34a1af4d0d08c787b" + integrity sha512-OmvfoQ53WLjtA9HeYP9RNrWMJzzAz1JGaSFr1nijg0PVR1JaD/xbJq1mdEIIlxGpXp9eSe/O2LgU9DJmTPd0Eg== dependencies: agent-base "^4.3.0" debug "^3.1.0" -https-proxy-agent@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-3.0.0.tgz#0106efa5d63d6d6f3ab87c999fa4877a3fd1ff97" - integrity sha512-y4jAxNEihqvBI5F3SaO2rtsjIOnnNA8sEbuiP+UhJZJHeM2NRm6c09ax2tgqme+SgUUvjao2fJXF4h3D6Cb2HQ== +https-proxy-agent@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/https-proxy-agent/-/https-proxy-agent-5.0.0.tgz#e2a90542abb68a762e0a0850f6c9edadfd8506b2" + integrity sha512-EkYm5BcKUGiduxzSt3Eppko+PiNWNEpa4ySk9vTC6wDsQJW9rHSa+UhGNJoRYp7bz6Ht1eaRIa6QaJqO5rCFbA== dependencies: - agent-base "^4.3.0" - debug "^3.1.0" + agent-base "6" + debug "4" -iconv-lite@0.4.24, iconv-lite@^0.4.24, iconv-lite@^0.4.4: +iconv-lite@0.4.24, iconv-lite@^0.4.24: version "0.4.24" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" integrity sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA== @@ -5978,13 +6344,6 @@ ignore-by-default@^1.0.1: resolved "https://registry.yarnpkg.com/ignore-by-default/-/ignore-by-default-1.0.1.tgz#48ca6d72f6c6a3af00a9ad4ae6876be3889e2b09" integrity sha1-SMptcvbGo68Aqa1K5odr44ieKwk= -ignore-walk@^3.0.1: - version "3.0.3" - resolved "https://registry.yarnpkg.com/ignore-walk/-/ignore-walk-3.0.3.tgz#017e2447184bfeade7c238e4aefdd1e8f95b1e37" - integrity sha512-m7o6xuOaT1aqheYHKf8W6J5pYH85ZI9w077erOzLje3JsB1gkafkAhHHY19dqjulgIZHFm32Cp5uNZgcQqdJKw== - dependencies: - minimatch "^3.0.4" - ignore@^3.3.5: version "3.3.10" resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.10.tgz#0a97fb876986e8081c631160f8f9f389157f0043" @@ -6015,10 +6374,10 @@ import-fresh@^2.0.0: caller-path "^2.0.0" resolve-from "^3.0.0" -import-fresh@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.1.0.tgz#6d33fa1dcef6df930fae003446f33415af905118" - integrity sha512-PpuksHKGt8rXfWEr9m9EHIpgyyaltBy8+eF6GJM0QCAxMgxCfucMF3mjecK2QsJr0amJW7gTqh5/wht0z2UhEQ== +import-fresh@^3.0.0, import-fresh@^3.1.0: + version "3.2.1" + resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.2.1.tgz#633ff618506e793af5ac91bf48b72677e15cbe66" + integrity sha512-6e1q1cnWP2RXD9/keSkxHScg508CdXqXWgWBaETNhyuBFz+kUZlKboh+ISK+bU++DmbHimVBrOz/zzPe0sZ3sQ== dependencies: parent-module "^1.0.0" resolve-from "^4.0.0" @@ -6049,9 +6408,9 @@ imurmurhash@^0.1.4: integrity sha1-khi5srkoojixPcT7a21XbyMUU+o= in-publish@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/in-publish/-/in-publish-2.0.0.tgz#e20ff5e3a2afc2690320b6dc552682a9c7fadf51" - integrity sha1-4g/146KvwmkDILbcVSaCqcf631E= + version "2.0.1" + resolved "https://registry.yarnpkg.com/in-publish/-/in-publish-2.0.1.tgz#948b1a535c8030561cea522f73f78f4be357e00c" + integrity sha512-oDM0kUSNFC31ShNxHKUyfZKy8ZeXZBWMjMdZHKLOk13uvT27VTL/QzRGfRUcevJhpkZAvlhPYuXkF7eNWrtyxQ== indent-string@^2.1.0: version "2.1.0" @@ -6078,7 +6437,7 @@ inflight@^1.0.4: once "^1.3.0" wrappy "1" -inherits@2, inherits@2.0.4, inherits@^2.0.1, inherits@^2.0.3, inherits@~2.0.0, inherits@~2.0.1, inherits@~2.0.3: +inherits@2, inherits@2.0.4, inherits@^2.0.1, inherits@^2.0.3, inherits@^2.0.4, inherits@~2.0.0, inherits@~2.0.1, inherits@~2.0.3: version "2.0.4" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== @@ -6117,23 +6476,23 @@ inquirer@6.5.0: strip-ansi "^5.1.0" through "^2.3.6" -inquirer@^6.4.1: - version "6.5.2" - resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-6.5.2.tgz#ad50942375d036d327ff528c08bd5fab089928ca" - integrity sha512-cntlB5ghuB0iuO65Ovoi8ogLHiWGs/5yNrtUcKjFhSSiVeAIVpD7koaSU9RM8mpXw5YDi9RdYXGQMaOURB7ycQ== +inquirer@^7.0.0: + version "7.1.0" + resolved "https://registry.yarnpkg.com/inquirer/-/inquirer-7.1.0.tgz#1298a01859883e17c7264b82870ae1034f92dd29" + integrity sha512-5fJMWEmikSYu0nv/flMc475MhGbB7TSPd/2IpFV4I4rMklboCH2rQjYY5kKiYGHqUF9gvaambupcJFFG9dvReg== dependencies: - ansi-escapes "^3.2.0" - chalk "^2.4.2" - cli-cursor "^2.1.0" + ansi-escapes "^4.2.1" + chalk "^3.0.0" + cli-cursor "^3.1.0" cli-width "^2.0.0" external-editor "^3.0.3" - figures "^2.0.0" - lodash "^4.17.12" - mute-stream "0.0.7" - run-async "^2.2.0" - rxjs "^6.4.0" - string-width "^2.1.0" - strip-ansi "^5.1.0" + figures "^3.0.0" + lodash "^4.17.15" + mute-stream "0.0.8" + run-async "^2.4.0" + rxjs "^6.5.3" + string-width "^4.1.0" + strip-ansi "^6.0.0" through "^2.3.6" internal-ip@^4.2.0: @@ -6151,11 +6510,6 @@ invariant@^2.2.2, invariant@^2.2.4: dependencies: loose-envify "^1.0.0" -invert-kv@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-1.0.0.tgz#104a8e4aaca6d3d8cd157a8ef8bfab2d7a3ffdb6" - integrity sha1-EEqOSqym09jNFXqO+L+rLXo//bY= - invert-kv@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/invert-kv/-/invert-kv-2.0.0.tgz#7393f5afa59ec9ff5f67a27620d11c226e3eec02" @@ -6171,12 +6525,7 @@ ip@^1.1.0, ip@^1.1.5: resolved "https://registry.yarnpkg.com/ip/-/ip-1.1.5.tgz#bdded70114290828c0a039e72ef25f5aaec4354a" integrity sha1-vd7XARQpCCjAoDnnLvJfWq7ENUo= -ipaddr.js@1.9.0: - version "1.9.0" - resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.9.0.tgz#37df74e430a0e47550fe54a2defe30d8acd95f65" - integrity sha512-M4Sjn6N/+O6/IXSJseKqHoFc+5FdGJ22sXqnjTpdZweHK64MzEPAyQZyEU3R/KRv2GLoa7nNtg/C2Ev6m7z+eA== - -ipaddr.js@^1.9.0: +ipaddr.js@1.9.1, ipaddr.js@^1.9.0: version "1.9.1" resolved "https://registry.yarnpkg.com/ipaddr.js/-/ipaddr.js-1.9.1.tgz#bff38543eeb8984825079ff3a2a8e6cbd46781b3" integrity sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g== @@ -6222,20 +6571,22 @@ is-binary-path@^1.0.0: dependencies: binary-extensions "^1.0.0" +is-binary-path@~2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/is-binary-path/-/is-binary-path-2.1.0.tgz#ea1f7f3b80f064236e83470f86c09c254fb45b09" + integrity sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw== + dependencies: + binary-extensions "^2.0.0" + is-buffer@^1.0.2, is-buffer@^1.1.5: version "1.1.6" resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-1.1.6.tgz#efaa2ea9daa0d7ab2ea13a97b2b8ad51fefbe8be" integrity sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w== -is-buffer@^2.0.2: - version "2.0.4" - resolved "https://registry.yarnpkg.com/is-buffer/-/is-buffer-2.0.4.tgz#3e572f23c8411a5cfd9557c849e3665e0b290623" - integrity sha512-Kq1rokWXOPXWuaMAqZiJW4XxsmD9zGx9q4aePabbn3qCRGedtH7Cm+zV8WETitMfu1wdh+Rvd6w5egwSngUX2A== - -is-callable@^1.1.4: - version "1.1.4" - resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.4.tgz#1e1adf219e1eeb684d691f9d6a05ff0d30a24d75" - integrity sha512-r5p9sxJjYnArLjObpjA4xu5EKI3CuKHkJXMhT7kwbpUyIFD1n5PMAsoPvWnvtZiNz7LjkYDRZhd7FlI0eMijEA== +is-callable@^1.1.4, is-callable@^1.1.5: + version "1.1.5" + resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.5.tgz#f7e46b596890456db74e7f6e976cb3273d06faab" + integrity sha512-ESKv5sMCJB2jnHTWZ3O5itG+O128Hsus4K4Qh1h2/cgn2vbgnLSVqfV46AeJA9D5EeeLa9w81KUXMtn34zhX+Q== is-ci@^1.0.10: version "1.2.1" @@ -6278,9 +6629,9 @@ is-data-descriptor@^1.0.0: kind-of "^6.0.0" is-date-object@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/is-date-object/-/is-date-object-1.0.1.tgz#9aa20eb6aeebbff77fbd33e74ca01b33581d3a16" - integrity sha1-mqIOtq7rv/d/vTPnTKAbM1gdOhY= + version "1.0.2" + resolved "https://registry.yarnpkg.com/is-date-object/-/is-date-object-1.0.2.tgz#bda736f2cd8fd06d32844e7743bfa7494c3bfd7e" + integrity sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g== is-descriptor@^0.1.0: version "0.1.6" @@ -6323,11 +6674,9 @@ is-extglob@^2.1.0, is-extglob@^2.1.1: integrity sha1-qIwCU1eR8C7TfHahueqXc8gz+MI= is-finite@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-finite/-/is-finite-1.0.2.tgz#cc6677695602be550ef11e8b4aa6305342b6d0aa" - integrity sha1-zGZ3aVYCvlUO8R6LSqYwU0K20Ko= - dependencies: - number-is-nan "^1.0.0" + version "1.1.0" + resolved "https://registry.yarnpkg.com/is-finite/-/is-finite-1.1.0.tgz#904135c77fb42c0641d6aa1bcdbc4daa8da082f3" + integrity sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w== is-fullwidth-code-point@^1.0.0: version "1.0.0" @@ -6341,6 +6690,11 @@ is-fullwidth-code-point@^2.0.0: resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" integrity sha1-o7MKXE8ZkYMWeqq5O+764937ZU8= +is-fullwidth-code-point@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz#f116f8064fe90b3f7844a38997c0b75051269f1d" + integrity sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg== + is-generator-fn@^2.0.0: version "2.1.0" resolved "https://registry.yarnpkg.com/is-generator-fn/-/is-generator-fn-2.1.0.tgz#7d140adc389aaf3011a8f2a2a4cfa6faadffb118" @@ -6353,7 +6707,7 @@ is-glob@^3.1.0: dependencies: is-extglob "^2.1.0" -is-glob@^4.0.0, is-glob@^4.0.1: +is-glob@^4.0.0, is-glob@^4.0.1, is-glob@~4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.1.tgz#7567dbe9f2f5e2467bc77ab83c4a29482407a5dc" integrity sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg== @@ -6426,22 +6780,17 @@ is-plain-object@^2.0.1, is-plain-object@^2.0.3, is-plain-object@^2.0.4: dependencies: isobject "^3.0.1" -is-promise@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.1.0.tgz#79a2a9ece7f096e80f36d2b2f3bc16c1ff4bf3fa" - integrity sha1-eaKp7OfwlugPNtKy87wWwf9L8/o= - is-redirect@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-redirect/-/is-redirect-1.0.0.tgz#1d03dded53bd8db0f30c26e4f95d36fc7c87dc24" integrity sha1-HQPd7VO9jbDzDCbk+V02/HyH3CQ= -is-regex@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.0.4.tgz#5517489b547091b0930e095654ced25ee97e9491" - integrity sha1-VRdIm1RwkbCTDglWVM7SXul+lJE= +is-regex@^1.0.4, is-regex@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.0.5.tgz#39d589a358bf18967f726967120b8fc1aed74eae" + integrity sha512-vlKW17SNq44owv5AQR3Cq0bQPEb8+kF3UKZ2fiZNOWtztYE5i0CzCZxFDwO58qAOWtxdBRVO/V5Qin1wjCqFYQ== dependencies: - has "^1.0.1" + has "^1.0.3" is-regexp@^1.0.0: version "1.0.0" @@ -6473,6 +6822,11 @@ is-stream@^2.0.0: resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.0.tgz#bde9c32680d6fae04129d6ac9d921ce7815f78e3" integrity sha512-XCoy+WlUr7d1+Z8GgSuXmpuUFC9fOhRXglJMx+dwLKTkL44Cjd4W1Z5P+BQZpr+cR93aGP4S/s7Ftw6Nd/kiEw== +is-string@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/is-string/-/is-string-1.0.5.tgz#40493ed198ef3ff477b8c7f92f644ec82a5cd3a6" + integrity sha512-buY6VNRjhQMiF1qWDouloZlQbRhDPCebwxSjxMjxgemYT46YMd2NR0/H+fBhEfWX4A/w9TBJ+ol+okqJKFE6vQ== + is-svg@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/is-svg/-/is-svg-3.0.0.tgz#9321dbd29c212e5ca99c4fa9794c714bcafa2f75" @@ -6481,11 +6835,11 @@ is-svg@^3.0.0: html-comment-regex "^1.1.0" is-symbol@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.2.tgz#a055f6ae57192caee329e7a860118b497a950f38" - integrity sha512-HS8bZ9ox60yCJLH9snBpIwv9pYUAkcuLhSA1oero1UB5y9aiQpRA8y2ex945AOtCZL1lJDeIk3G5LthswI46Lw== + version "1.0.3" + resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.3.tgz#38e1014b9e6329be0de9d24a414fd7441ec61937" + integrity sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ== dependencies: - has-symbols "^1.0.0" + has-symbols "^1.0.1" is-typedarray@^1.0.0, is-typedarray@~1.0.0: version "1.0.0" @@ -6498,9 +6852,9 @@ is-utf8@^0.2.0: integrity sha1-Sw2hRCEE0bM2NA6AeX6GXPOffXI= is-what@^3.3.1: - version "3.3.1" - resolved "https://registry.yarnpkg.com/is-what/-/is-what-3.3.1.tgz#79502181f40226e2d8c09226999db90ef7c1bcbe" - integrity sha512-seFn10yAXy+yJlTRO+8VfiafC+0QJanGLMPTBWLrJm/QPauuchy0UXh8B6H5o9VA8BAzk0iYievt6mNp6gfaqA== + version "3.8.0" + resolved "https://registry.yarnpkg.com/is-what/-/is-what-3.8.0.tgz#610bc46a524355f2424eb85eedc6ebbbf7e1ff8c" + integrity sha512-UKeBoQfV8bjlM4pmx1FLDHdxslW/1mTksEs8ReVsilPmUv5cORd4+2/wFcviI3cUjrLybxCjzc8DnodAzJ/Wrg== is-windows@^0.2.0: version "0.2.0" @@ -6583,11 +6937,11 @@ istanbul-lib-source-maps@^3.0.1: source-map "^0.6.1" istanbul-reports@^2.2.6: - version "2.2.6" - resolved "https://registry.yarnpkg.com/istanbul-reports/-/istanbul-reports-2.2.6.tgz#7b4f2660d82b29303a8fe6091f8ca4bf058da1af" - integrity sha512-SKi4rnMyLBKe0Jy2uUdx28h8oG7ph2PPuQPvIAh31d+Ci+lSiEu4C+h3oBPuJ9+mPKhOyW0M8gY4U5NM1WLeXA== + version "2.2.7" + resolved "https://registry.yarnpkg.com/istanbul-reports/-/istanbul-reports-2.2.7.tgz#5d939f6237d7b48393cc0959eab40cd4fd056931" + integrity sha512-uu1F/L1o5Y6LzPVSVZXNOoD/KXpJue9aeLRd0sM9uMXfZvzomB0WxVamWb5ue8kA2vVWEmW7EG+A5n3f1kqHKg== dependencies: - handlebars "^4.1.2" + html-escaper "^2.0.0" jest-changed-files@^24.9.0: version "24.9.0" @@ -6640,19 +6994,29 @@ jest-config@^24.9.0: pretty-format "^24.9.0" realpath-native "^1.1.0" -jest-dev-server@^4.3.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/jest-dev-server/-/jest-dev-server-4.3.0.tgz#27c9cdc96d9f735bc90a309ca39305b76f2c0edd" - integrity sha512-bC9flKY2G1honQ/UI0gEhb0wFnDhpFr7xidC8Nk+evi7TgnNtfsGIzzF2dcIhF1G9BGF0n/M7CJrMAzwQhyTPA== +jest-dev-server@^4.4.0: + version "4.4.0" + resolved "https://registry.yarnpkg.com/jest-dev-server/-/jest-dev-server-4.4.0.tgz#557113faae2877452162696aa94c1e44491ab011" + integrity sha512-STEHJ3iPSC8HbrQ3TME0ozGX2KT28lbT4XopPxUm2WimsX3fcB3YOptRh12YphQisMhfqNSNTZUmWyT3HEXS2A== dependencies: - chalk "^2.4.2" + chalk "^3.0.0" cwd "^0.10.0" - find-process "^1.4.2" - prompts "^2.1.0" - spawnd "^4.0.0" - tree-kill "^1.2.1" + find-process "^1.4.3" + prompts "^2.3.0" + spawnd "^4.4.0" + tree-kill "^1.2.2" wait-on "^3.3.0" +jest-diff@*: + version "26.0.1" + resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-26.0.1.tgz#c44ab3cdd5977d466de69c46929e0e57f89aa1de" + integrity sha512-odTcHyl5X+U+QsczJmOjWw5tPvww+y9Yim5xzqxVl/R1j4z71+fHW4g8qu1ugMmKdFdxw+AtQgs5mupPnzcIBQ== + dependencies: + chalk "^4.0.0" + diff-sequences "^26.0.0" + jest-get-type "^26.0.0" + pretty-format "^26.0.1" + jest-diff@^24.3.0, jest-diff@^24.9.0: version "24.9.0" resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-24.9.0.tgz#931b7d0d5778a1baf7452cb816e325e3724055da" @@ -6713,14 +7077,14 @@ jest-environment-node@^24.9.0: jest-mock "^24.9.0" jest-util "^24.9.0" -jest-environment-puppeteer@^4.3.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/jest-environment-puppeteer/-/jest-environment-puppeteer-4.3.0.tgz#49ac781c4b50459485af031cfb16ad1fd75d31ac" - integrity sha512-ZighMsU39bnacn2ylyHb88CB+ldgCfXGD3lS78k4PEo8A8xyt6+2mxmSR62FH3Y7K+W2gPDu5+QM3/LZuq42fQ== +jest-environment-puppeteer@^4.4.0: + version "4.4.0" + resolved "https://registry.yarnpkg.com/jest-environment-puppeteer/-/jest-environment-puppeteer-4.4.0.tgz#d82a37e0e0c51b63cc6b15dea101d53967508860" + integrity sha512-iV8S8+6qkdTM6OBR/M9gKywEk8GDSOe05hspCs5D8qKSwtmlUfdtHfB4cakdc68lC6YfK3AUsLirpfgodCHjzQ== dependencies: - chalk "^2.4.2" + chalk "^3.0.0" cwd "^0.10.0" - jest-dev-server "^4.3.0" + jest-dev-server "^4.4.0" merge-deep "^3.0.2" jest-get-type@^24.9.0: @@ -6728,6 +7092,11 @@ jest-get-type@^24.9.0: resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-24.9.0.tgz#1684a0c8a50f2e4901b6644ae861f579eed2ef0e" integrity sha512-lUseMzAley4LhIcpSP9Jf+fTrQ4a1yHQwLNeeVa2cEmbCGeoZAtYPOIv8JaxLD/sUpKxetKGP+gsHl8f8TSj8Q== +jest-get-type@^26.0.0: + version "26.0.0" + resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-26.0.0.tgz#381e986a718998dbfafcd5ec05934be538db4039" + integrity sha512-zRc1OAPnnws1EVfykXOj19zo2EMw5Hi6HLbFCSjpuJiXtOWAYIjNsHVSbpQ8bDX7L5BGYGI8m+HmKdjHYFF0kg== + jest-haste-map@^24.9.0: version "24.9.0" resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-24.9.0.tgz#b38a5d64274934e21fa417ae9a9fbeb77ceaac7d" @@ -6814,12 +7183,12 @@ jest-pnp-resolver@^1.2.1: integrity sha512-pgFw2tm54fzgYvc/OHrnysABEObZCUNFnhjoRjaVOCN8NYc032/gVjPaHD4Aq6ApkSieWtfKAFQtmDKAmhupnQ== jest-puppeteer@^4.3.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/jest-puppeteer/-/jest-puppeteer-4.3.0.tgz#432273c2c2c75fbec40d7659b75cbcc7c4ae57ad" - integrity sha512-WXhaWlbQl01xadZyNmdZntrtIr8uWUmgjPogDih7dOnr3G/xRr3A034SCqdjwV6fE0tqz7c5hwO8oBTyGZPRgA== + version "4.4.0" + resolved "https://registry.yarnpkg.com/jest-puppeteer/-/jest-puppeteer-4.4.0.tgz#4b906e638a5e3782ed865e7b673c82047b85952e" + integrity sha512-ZaiCTlPZ07B9HW0erAWNX6cyzBqbXMM7d2ugai4epBDKpKvRDpItlRQC6XjERoJELKZsPziFGS0OhhUvTvQAXA== dependencies: - expect-puppeteer "^4.3.0" - jest-environment-puppeteer "^4.3.0" + expect-puppeteer "^4.4.0" + jest-environment-puppeteer "^4.4.0" jest-regex-util@^24.3.0, jest-regex-util@^24.9.0: version "24.9.0" @@ -6996,14 +7365,9 @@ jest@24.9.0, jest@^24.9.0: jest-cli "^24.9.0" js-base64@^2.1.8: - version "2.5.1" - resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-2.5.1.tgz#1efa39ef2c5f7980bb1784ade4a8af2de3291121" - integrity sha512-M7kLczedRMYX4L8Mdh4MzyAMM9O5osx+4FcOQuTvr3A9F2D9S5JXheN0ewNbrvK2UatkTRhL5ejGmGSjNMiZuw== - -js-levenshtein@^1.1.3: - version "1.1.6" - resolved "https://registry.yarnpkg.com/js-levenshtein/-/js-levenshtein-1.1.6.tgz#c6cee58eb3550372df8deb85fad5ce66ce01d59d" - integrity sha512-X2BB11YZtrRqY4EnQcLX5Rh373zbK4alC1FW7D7MBhL2gtcC17cTnr6DmfHZeS0s2rTHjUTMMHfG7gO8SSdw+g== + version "2.5.2" + resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-2.5.2.tgz#313b6274dda718f714d00b3330bbae6e38e90209" + integrity sha512-Vg8czh0Q7sFBSUMWWArX/miJeBWYBPpdU/3M/DKSaekLMqrqVPaedp+5mZhie/r0lgrcaYBfwXatEew6gwgiQQ== "js-tokens@^3.0.0 || ^4.0.0", js-tokens@^4.0.0: version "4.0.0" @@ -7016,9 +7380,9 @@ js-tokens@^3.0.2: integrity sha1-mGbfOVECEw449/mWvOtlRDIJwls= js-yaml@^3.13.1: - version "3.13.1" - resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.13.1.tgz#aff151b30bfdfa8e49e05da22e7415e9dfa37847" - integrity sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw== + version "3.14.0" + resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-3.14.0.tgz#a7a34170f26a21bb162424d8adacb4113a69e482" + integrity sha512-/4IbIeHcD9VMHFqDR/gQ7EdZdLimOvW2DdcxFjdyyZ9NsbS+ccrXqVWDtab/lRl5AlUqmpBx8EhPaWR+OtY17A== dependencies: argparse "^1.0.7" esprima "^4.0.0" @@ -7146,12 +7510,12 @@ json3@^3.3.2: resolved "https://registry.yarnpkg.com/json3/-/json3-3.3.3.tgz#7fc10e375fc5ae42c4705a5cc0aa6f62be305b81" integrity sha512-c7/8mbUsKigAbLkD5B010BK4D9LZm7A1pNItkEwiUZRpIN66exu/e7YQWysGun+TRKaJp8MhemM+VkfWv42aCA== -json5@2.x, json5@^2.1.0: - version "2.1.1" - resolved "https://registry.yarnpkg.com/json5/-/json5-2.1.1.tgz#81b6cb04e9ba496f1c7005d07b4368a2638f90b6" - integrity sha512-l+3HXD0GEI3huGq1njuqtzYK8OYJyXMkOLtQ53pjWh89tvWS2h6l+1zMkYWqlb57+SiQodKZyvMEFb2X+KrFhQ== +json5@2.x, json5@^2.1.0, json5@^2.1.2: + version "2.1.3" + resolved "https://registry.yarnpkg.com/json5/-/json5-2.1.3.tgz#c9b0f7fa9233bfe5807fe66fcf3a5617ed597d43" + integrity sha512-KXPvOm8K9IJKFM0bmdn8QXh7udDh1g/giieX0NLCaMnb4hEiVFqnop2ImTXCc5e0/oHz3LTqmHGtExn5hfMkOA== dependencies: - minimist "^1.2.0" + minimist "^1.2.5" json5@^1.0.1: version "1.0.1" @@ -7183,28 +7547,28 @@ jsprim@^1.2.2: verror "1.10.0" jsx-ast-utils@^2.1.0, jsx-ast-utils@^2.2.1: - version "2.2.1" - resolved "https://registry.yarnpkg.com/jsx-ast-utils/-/jsx-ast-utils-2.2.1.tgz#4d4973ebf8b9d2837ee91a8208cc66f3a2776cfb" - integrity sha512-v3FxCcAf20DayI+uxnCuw795+oOIkVu6EnJ1+kSzhqqTZHNkTZ7B66ZgLp4oLJ/gbA64cI0B7WRoHZMSRdyVRQ== + version "2.3.0" + resolved "https://registry.yarnpkg.com/jsx-ast-utils/-/jsx-ast-utils-2.3.0.tgz#edd727794ea284d7fda575015ed1b0cde0289ab6" + integrity sha512-3HNoc7nZ1hpZIKB3hJ7BlFRkzCx2BynRtfSwbkqZdpRdvAPsGMnzclPwrvDBS7/lalHTj21NwIeaEpysHBOudg== dependencies: - array-includes "^3.0.3" + array-includes "^3.1.1" object.assign "^4.1.0" -jwa@^1.4.1: - version "1.4.1" - resolved "https://registry.yarnpkg.com/jwa/-/jwa-1.4.1.tgz#743c32985cb9e98655530d53641b66c8645b039a" - integrity sha512-qiLX/xhEEFKUAJ6FiBMbes3w9ATzyk5W7Hvzpa/SLYdxNtng+gcurvrI7TbACjIXlsJyr05/S1oUhZrc63evQA== +jwa@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/jwa/-/jwa-2.0.0.tgz#a7e9c3f29dae94027ebcaf49975c9345593410fc" + integrity sha512-jrZ2Qx916EA+fq9cEAeCROWPTfCwi1IVHqT2tapuqLEVVDKFDENFw1oL+MwrTvH6msKxsd1YTDVw6uKEcsrLEA== dependencies: buffer-equal-constant-time "1.0.1" ecdsa-sig-formatter "1.0.11" safe-buffer "^5.0.1" -jws@^3.1.5: - version "3.2.2" - resolved "https://registry.yarnpkg.com/jws/-/jws-3.2.2.tgz#001099f3639468c9414000e99995fa52fb478304" - integrity sha512-YHlZCB6lMTllWDtSPHz/ZXTsi8S00usEV6v1tjq8tOUZzw7DpSDWVXjXDre6ed1w/pd495ODpHZYSdkRTsa0HA== +jws@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/jws/-/jws-4.0.0.tgz#2d4e8cf6a318ffaa12615e9dec7e86e6c97310f4" + integrity sha512-KDncfTmOZoOMTFG4mBlG0qUIOlc03fmzH+ru6RgYVZhPkyiy/92Owlt/8UEN+a4TXR1FQetfIpJE8ApdvdVxTg== dependencies: - jwa "^1.4.1" + jwa "^2.0.0" safe-buffer "^5.0.1" killable@^1.0.0: @@ -7239,9 +7603,9 @@ kind-of@^5.0.0: integrity sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw== kind-of@^6.0.0, kind-of@^6.0.2: - version "6.0.2" - resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.2.tgz#01146b36a6218e64e58f3a8d66de5d7fc6f6d051" - integrity sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA== + version "6.0.3" + resolved "https://registry.yarnpkg.com/kind-of/-/kind-of-6.0.3.tgz#07c05034a6c349fa06e24fa35aa76db4580ce4dd" + integrity sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw== kleur@^3.0.3: version "3.0.3" @@ -7280,13 +7644,6 @@ lazy-cache@^1.0.3: resolved "https://registry.yarnpkg.com/lazy-cache/-/lazy-cache-1.0.4.tgz#a1d78fc3a50474cb80845d3b3b6e1da49a446e8e" integrity sha1-odePw6UEdMuAhF07O24dpJpEbo4= -lcid@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/lcid/-/lcid-1.0.0.tgz#308accafa0bc483a3867b4b6f2b9506251d1b835" - integrity sha1-MIrMr6C8SDo4Z7S28rlQYlHRuDU= - dependencies: - invert-kv "^1.0.0" - lcid@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/lcid/-/lcid-2.0.0.tgz#6ef5d2df60e52f82eb228a4c373e8d1f397253cf" @@ -7304,6 +7661,13 @@ leven@^3.1.0: resolved "https://registry.yarnpkg.com/leven/-/leven-3.1.0.tgz#77891de834064cccba82ae7842bb6b14a13ed7f2" integrity sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A== +levenary@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/levenary/-/levenary-1.1.1.tgz#842a9ee98d2075aa7faeedbe32679e9205f46f77" + integrity sha512-mkAdOIt79FD6irqjYSs4rdbnlT5vRonMEvBVPVb3XmevfS8kgRXwfes0dhPdEtzTWD/1eNE/Bm/G1iRt6DcnQQ== + dependencies: + leven "^3.1.0" + levn@^0.3.0, levn@~0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/levn/-/levn-0.3.0.tgz#3b09924edf9f083c0490fdd4c0bc4421e04764ee" @@ -7324,6 +7688,11 @@ libsodium@0.7.6: resolved "https://registry.yarnpkg.com/libsodium/-/libsodium-0.7.6.tgz#018b80c5728054817845fbffa554274441bda277" integrity sha512-hPb/04sEuLcTRdWDtd+xH3RXBihpmbPCsKW/Jtf4PsvdyKh+D6z2D2gvp/5BfoxseP+0FCOg66kE+0oGUE/loQ== +lines-and-columns@^1.1.6: + version "1.1.6" + resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.1.6.tgz#1c00c743b433cd0a4e80758f7b64a57440d9ff00" + integrity sha1-HADHQ7QzzQpOgHWPe2SldEDZ/wA= + load-json-file@^1.0.0: version "1.1.0" resolved "https://registry.yarnpkg.com/load-json-file/-/load-json-file-1.1.0.tgz#956905708d58b4bab4c2261b04f59f31c99374c0" @@ -7356,19 +7725,19 @@ load-json-file@^4.0.0: strip-bom "^3.0.0" loader-fs-cache@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/loader-fs-cache/-/loader-fs-cache-1.0.2.tgz#54cedf6b727e1779fd8f01205f05f6e88706f086" - integrity sha512-70IzT/0/L+M20jUlEqZhZyArTU6VKLRTYRDAYN26g4jfzpJqjipLL3/hgYpySqI9PwsVRHHFja0LfEmsx9X2Cw== + version "1.0.3" + resolved "https://registry.yarnpkg.com/loader-fs-cache/-/loader-fs-cache-1.0.3.tgz#f08657646d607078be2f0a032f8bd69dd6f277d9" + integrity sha512-ldcgZpjNJj71n+2Mf6yetz+c9bM4xpKtNds4LbqXzU/PTdeAX0g3ytnU1AJMEcTk2Lex4Smpe3Q/eCTsvUBxbA== dependencies: find-cache-dir "^0.1.1" - mkdirp "0.5.1" + mkdirp "^0.5.1" loader-runner@^2.4.0: version "2.4.0" resolved "https://registry.yarnpkg.com/loader-runner/-/loader-runner-2.4.0.tgz#ed47066bfe534d7e84c4c7b9998c2a75607d9357" integrity sha512-Jsmr89RcXGIwivFY21FcRrisYZfvLMTWx5kOLc+JTxtpBOG6xML0vzbc6SEQG2FO9/4Fc3wW4LVcB5DmGflaRw== -loader-utils@1.2.3, loader-utils@^1.0.1, loader-utils@^1.0.2, loader-utils@^1.1.0, loader-utils@^1.2.3: +loader-utils@1.2.3: version "1.2.3" resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-1.2.3.tgz#1ff5dc6911c9f0a062531a4c04b609406108c2c7" integrity sha512-fkpz8ejdnEMG3s37wGL07iSBDg99O9D5yflE9RGNH3hRdx9SOwYfnGYdZOUIZitN8E+E2vkq3MUMYMvPYl5ZZA== @@ -7377,6 +7746,15 @@ loader-utils@1.2.3, loader-utils@^1.0.1, loader-utils@^1.0.2, loader-utils@^1.1. emojis-list "^2.0.0" json5 "^1.0.1" +loader-utils@^1.0.1, loader-utils@^1.0.2, loader-utils@^1.1.0, loader-utils@^1.2.3: + version "1.4.0" + resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-1.4.0.tgz#c579b5e34cb34b1a74edc6c1fb36bfa371d5a613" + integrity sha512-qH0WSMBtn/oHuwjy/NucEgbx5dbxxnxup9s4PVXJUDHZBQY+s0NWA9rJf53RBnQZxfch7euUui7hpoAPvALZdA== + dependencies: + big.js "^5.2.2" + emojis-list "^3.0.0" + json5 "^1.0.1" + locate-path@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-2.0.0.tgz#2b568b265eec944c6d9c0de9c3dbbbca0354cd8e" @@ -7423,7 +7801,7 @@ lodash.memoize@4.x, lodash.memoize@^4.1.2: resolved "https://registry.yarnpkg.com/lodash.memoize/-/lodash.memoize-4.1.2.tgz#bcc6c49a42a2840ed997f323eada5ecd182e0bfe" integrity sha1-vMbEmkKihA7Zl/Mj6tpezRguC/4= -lodash.mergewith@^4.6.1: +lodash.mergewith@^4.6.2: version "4.6.2" resolved "https://registry.yarnpkg.com/lodash.mergewith/-/lodash.mergewith-4.6.2.tgz#617121f89ac55f59047c7aec1ccd6654c6590f55" integrity sha512-GK3g5RPZWTRSeLSpgP8Xhra+pnjBC56q9FZYe1d5RN3TJ35dbkGy3YqBSMbyCrlbi+CM9Z3Jk5yTL7RCsqboyQ== @@ -7448,22 +7826,17 @@ lodash.templatesettings@^4.0.0: dependencies: lodash._reinterpolate "^3.0.0" -lodash.unescape@4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/lodash.unescape/-/lodash.unescape-4.0.1.tgz#bf2249886ce514cda112fae9218cdc065211fc9c" - integrity sha1-vyJJiGzlFM2hEvrpIYzcBlIR/Jw= - lodash.uniq@^4.5.0: version "4.5.0" resolved "https://registry.yarnpkg.com/lodash.uniq/-/lodash.uniq-4.5.0.tgz#d0225373aeb652adc1bc82e4945339a842754773" integrity sha1-0CJTc662Uq3BvILklFM5qEJ1R3M= -"lodash@>=3.5 <5", lodash@^4.0.0, lodash@^4.17.10, lodash@^4.17.11, lodash@^4.17.12, lodash@^4.17.13, lodash@^4.17.14, lodash@^4.17.15, lodash@^4.17.5, lodash@^4.2.0, lodash@~4.17.10: +"lodash@>=3.5 <5", lodash@^4.0.0, lodash@^4.17.11, lodash@^4.17.12, lodash@^4.17.13, lodash@^4.17.14, lodash@^4.17.15, lodash@^4.17.5, lodash@^4.2.0, lodash@~4.17.12: version "4.17.15" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.15.tgz#b447f6670a0455bbfeedd11392eff330ea097548" integrity sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A== -logform@^2.1.1: +logform@*, logform@^2.1.1: version "2.1.2" resolved "https://registry.yarnpkg.com/logform/-/logform-2.1.2.tgz#957155ebeb67a13164069825ce67ddb5bb2dd360" integrity sha512-+lZh4OpERDBLqjiwDLpAWNQu6KMjnlXH2ByZwCuSqVPJletw0kTWJf5CgSNAUKn1KUkv3m2cUz/LK8zyEy7wzQ== @@ -7475,9 +7848,9 @@ logform@^2.1.1: triple-beam "^1.3.0" loglevel@^1.4.1: - version "1.6.4" - resolved "https://registry.yarnpkg.com/loglevel/-/loglevel-1.6.4.tgz#f408f4f006db8354d0577dcf6d33485b3cb90d56" - integrity sha512-p0b6mOGKcGa+7nnmKbpzR6qloPbrgLcnio++E+14Vo/XffOGwZtRpUhr8dTH/x2oCMmEoIU0Zwm3ZauhvYD17g== + version "1.6.8" + resolved "https://registry.yarnpkg.com/loglevel/-/loglevel-1.6.8.tgz#8a25fb75d092230ecd4457270d80b54e28011171" + integrity sha512-bsU7+gc9AJ2SqpzxwU3+1fedl8zAntbtC5XYlt3s2j1hJcn2PsXSmgN8TaLG/J1/2mod4+cE/3vNL70/c1RNCA== loose-envify@^1.0.0, loose-envify@^1.1.0, loose-envify@^1.4.0: version "1.4.0" @@ -7535,16 +7908,16 @@ make-dir@^2.0.0, make-dir@^2.1.0: semver "^5.6.0" make-dir@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-3.0.0.tgz#1b5f39f6b9270ed33f9f054c5c0f84304989f801" - integrity sha512-grNJDhb8b1Jm1qeqW5R/O63wUo4UXo2v2HMic6YT9i/HBlF93S8jkMgH7yugvY9ABDShH4VZMn8I+U8+fCNegw== + version "3.1.0" + resolved "https://registry.yarnpkg.com/make-dir/-/make-dir-3.1.0.tgz#415e967046b3a7f1d185277d84aa58203726a13f" + integrity sha512-g3FeP20LNwhALb/6Cz6Dd4F2ngze0jz7tbzrD2wAV+o9FeNHe4rL+yK2md0J/fiSf1sa1ADhXqi5+oVwOM/eGw== dependencies: semver "^6.0.0" make-error@1.x, make-error@^1.1.1: - version "1.3.5" - resolved "https://registry.yarnpkg.com/make-error/-/make-error-1.3.5.tgz#efe4e81f6db28cadd605c70f29c831b58ef776c8" - integrity sha512-c3sIjNUow0+8swNwVpqoH4YCShKNFkMaw6oH1mNS2haDZQqkeZFlHS3dhoeEbKKmJB4vXpJucU6oH75aDYeE9g== + version "1.3.6" + resolved "https://registry.yarnpkg.com/make-error/-/make-error-1.3.6.tgz#2eb2e37ea9b67c4891f684a1394799af484cf7a2" + integrity sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw== makeerror@1.0.x: version "1.0.11" @@ -7596,10 +7969,10 @@ mdn-data@2.0.4: resolved "https://registry.yarnpkg.com/mdn-data/-/mdn-data-2.0.4.tgz#699b3c38ac6f1d728091a64650b65d388502fd5b" integrity sha512-iV3XNKw06j5Q7mi6h+9vbx23Tv7JkjEVgKHW4pimwyDGWm0OIQntJJ+u1C6mg6mK1EaTv42XQ7w76yuzH7M2cA== -mdn-data@~1.1.0: - version "1.1.4" - resolved "https://registry.yarnpkg.com/mdn-data/-/mdn-data-1.1.4.tgz#50b5d4ffc4575276573c4eedb8780812a8419f01" - integrity sha512-FSYbp3lyKjyj3E7fMl6rYvUdX0FBXaluGqlFoYESWQlyUTq8R+wp0rkFxoYFqZlHCvsUXGjyJmLQSnXToYhOSA== +mdn-data@2.0.6: + version "2.0.6" + resolved "https://registry.yarnpkg.com/mdn-data/-/mdn-data-2.0.6.tgz#852dc60fcaa5daa2e8cf6c9189c440ed3e042978" + integrity sha512-rQvjv71olwNHgiTbfPZFkJtjNMciWgswYeciZhtvWLO8bmX3TnhyA62I6sTWOyZssWHJJjY6/KiWwqQsWWsqOA== media-typer@0.3.0: version "0.3.0" @@ -7653,9 +8026,9 @@ meow@^3.7.0: trim-newlines "^1.0.0" merge-anything@^2.2.4: - version "2.4.1" - resolved "https://registry.yarnpkg.com/merge-anything/-/merge-anything-2.4.1.tgz#e9bccaec1e49ec6cb5f77ca78c5770d1a35315e6" - integrity sha512-dYOIAl9GFCJNctSIHWOj9OJtarCjsD16P8ObCl6oxrujAG+kOvlwJuOD9/O9iYZ9aTi1RGpGTG9q9etIvuUikQ== + version "2.4.4" + resolved "https://registry.yarnpkg.com/merge-anything/-/merge-anything-2.4.4.tgz#6226b2ac3d3d3fc5fb9e8d23aa400df25f98fdf0" + integrity sha512-l5XlriUDJKQT12bH+rVhAHjwIuXWdAIecGwsYjv2LJo+dA1AeRTmeQS+3QBpO6lEthBMDi2IUMpLC1yyRvGlwQ== dependencies: is-what "^3.3.1" @@ -7728,22 +8101,17 @@ miller-rabin@^4.0.0: bn.js "^4.0.0" brorand "^1.0.1" -mime-db@1.40.0: - version "1.40.0" - resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.40.0.tgz#a65057e998db090f732a68f6c276d387d4126c32" - integrity sha512-jYdeOMPy9vnxEqFRRo6ZvTZ8d9oPb+k18PKoYNYUe2stVEBPPwsln/qWzdbmaIvnhZ9v2P+CuecK+fpUfsV2mA== - -"mime-db@>= 1.40.0 < 2": - version "1.42.0" - resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.42.0.tgz#3e252907b4c7adb906597b4b65636272cf9e7bac" - integrity sha512-UbfJCR4UAVRNgMpfImz05smAXK7+c+ZntjaA26ANtkXLlOe947Aag5zdIcKQULAiF9Cq4WxBi9jUs5zkA84bYQ== +mime-db@1.44.0, "mime-db@>= 1.43.0 < 2": + version "1.44.0" + resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.44.0.tgz#fa11c5eb0aca1334b4233cb4d52f10c5a6272f92" + integrity sha512-/NOTfLrsPBVeH7YtFPgsVWveuL+4SjjYxaQ1xtM1KMFj7HdxlBlxeyNLzhyJVx7r4rZGJAZ/6lkKCitSc/Nmpg== mime-types@^2.0.8, mime-types@^2.1.12, mime-types@~2.1.17, mime-types@~2.1.19, mime-types@~2.1.24: - version "2.1.24" - resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.24.tgz#b6f8d0b3e951efb77dedeca194cff6d16f676f81" - integrity sha512-WaFHS3MCl5fapm3oLxU4eYDw77IQM2ACcxQ9RIxfaC3ooc6PFuBMGZZsYpvoXS5D5QTWPieo1jjLdAm3TBP3cQ== + version "2.1.27" + resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.27.tgz#47949f98e279ea53119f5722e0f34e529bec009f" + integrity sha512-JIhqnCasI9yD+SsmkquHBxTSEuZdQX5BuQnS2Vc7puQQQ+8yiP5AY5uWhpdv4YL4VM5c6iliiYWPgJ/nJQLp7w== dependencies: - mime-db "1.40.0" + mime-db "1.44.0" mime@1.6.0: version "1.6.0" @@ -7751,9 +8119,9 @@ mime@1.6.0: integrity sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg== mime@^2.0.3, mime@^2.2.0, mime@^2.4.4: - version "2.4.4" - resolved "https://registry.yarnpkg.com/mime/-/mime-2.4.4.tgz#bd7b91135fc6b01cde3e9bae33d659b63d8857e5" - integrity sha512-LRxmNwziLPT828z+4YkNzloCFC2YM4wrB99k+AV5ZbEyfGNWfG8SO1FUXLmLDBSo89NrJZ4DIWeLjy1CHGhMGA== + version "2.4.5" + resolved "https://registry.yarnpkg.com/mime/-/mime-2.4.5.tgz#d8de2ecb92982dedbb6541c9b6841d7f218ea009" + integrity sha512-3hQhEUF027BuxZjQA3s7rIv/7VCQPa27hN9u9g87sEkWaKwQPuXOkVKtOeiyUrnWqTDiOs8Ed2rwg733mB0R5w== mimic-fn@^1.0.0: version "1.2.0" @@ -7792,35 +8160,10 @@ minimatch@3.0.4, minimatch@^3.0.4, minimatch@~3.0.2: dependencies: brace-expansion "^1.1.7" -minimist@0.0.8: - version "0.0.8" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d" - integrity sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0= - -minimist@^1.1.1, minimist@^1.1.3, minimist@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.0.tgz#a35008b20f41383eec1fb914f4cd5df79a264284" - integrity sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ= - -minimist@~0.0.1: - version "0.0.10" - resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.10.tgz#de3f98543dbf96082be48ad1a0c7cda836301dcf" - integrity sha1-3j+YVD2/lggr5IrRoMfNqDYwHc8= - -minipass@^2.6.0, minipass@^2.8.6, minipass@^2.9.0: - version "2.9.0" - resolved "https://registry.yarnpkg.com/minipass/-/minipass-2.9.0.tgz#e713762e7d3e32fed803115cf93e04bca9fcc9a6" - integrity sha512-wxfUjg9WebH+CUDX/CdbRlh5SmfZiy/hpkxaRI16Y9W56Pa75sWgd/rvFilSgrauD9NyFymP/+JFV3KwzIsJeg== - dependencies: - safe-buffer "^5.1.2" - yallist "^3.0.0" - -minizlib@^1.2.1: - version "1.3.3" - resolved "https://registry.yarnpkg.com/minizlib/-/minizlib-1.3.3.tgz#2290de96818a34c29551c8a8d301216bd65a861d" - integrity sha512-6ZYMOEnmVsdCeTJVE0W9ZD+pVnE8h9Hma/iOwwRDsdQoePpoX56/8B6z3P9VNwppJuBKNRuFDRNRqRWexT9G9Q== - dependencies: - minipass "^2.9.0" +minimist@^1.1.1, minimist@^1.1.3, minimist@^1.2.0, minimist@^1.2.5: + version "1.2.5" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602" + integrity sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw== mississippi@^3.0.0: version "3.0.0" @@ -7854,12 +8197,12 @@ mixin-object@^2.0.1: for-in "^0.1.3" is-extendable "^0.1.1" -mkdirp@0.5.1, mkdirp@0.5.x, mkdirp@0.x, "mkdirp@>=0.5 0", mkdirp@^0.5.0, mkdirp@^0.5.1, mkdirp@~0.5.1: - version "0.5.1" - resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.1.tgz#30057438eac6cf7f8c4767f38648d6697d75c903" - integrity sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM= +mkdirp@0.x, "mkdirp@>=0.5 0", mkdirp@^0.5.0, mkdirp@^0.5.1, mkdirp@^0.5.4, mkdirp@~0.5.1: + version "0.5.5" + resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.5.tgz#d91cefd62d1436ca0f41620e251288d420099def" + integrity sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ== dependencies: - minimist "0.0.8" + minimist "^1.2.5" "monaco-editor@npm:@ligolang/monaco-editor@0.18.1": version "0.18.1" @@ -7911,10 +8254,15 @@ mute-stream@0.0.7: resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.7.tgz#3075ce93bc21b8fab43e1bc4da7e8115ed1e7bab" integrity sha1-MHXOk7whuPq0PhvE2n6BFe0ee6s= +mute-stream@0.0.8: + version "0.0.8" + resolved "https://registry.yarnpkg.com/mute-stream/-/mute-stream-0.0.8.tgz#1630c42b2251ff81e2a283de96a5497ea92e5e0d" + integrity sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA== + nan@^2.12.1, nan@^2.13.2: - version "2.14.0" - resolved "https://registry.yarnpkg.com/nan/-/nan-2.14.0.tgz#7818f722027b2459a86f0295d434d1fc2336c52c" - integrity sha512-INOFj37C7k3AfaNTtX8RhsTw7qRy7eLET14cROi9+5HAVbbHuIWUHEauBv5qT4Av2tWasiTY1Jw6puUNqRJXQg== + version "2.14.1" + resolved "https://registry.yarnpkg.com/nan/-/nan-2.14.1.tgz#d7be34dfa3105b91494c3147089315eff8874b01" + integrity sha512-isWHgVjnFjh2x2yuJ/tj3JbwoHu3UC2dX5G/88Cm24yB6YopVgxvBObDY7n5xW6ExmFhJpSEQqFPvq9zaXc8Jw== nanomatch@^1.2.9: version "1.2.13" @@ -7938,26 +8286,17 @@ natural-compare@^1.4.0: resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" integrity sha1-Sr6/7tdUHywnrPspvbvRXI1bpPc= -needle@^2.2.1: - version "2.4.0" - resolved "https://registry.yarnpkg.com/needle/-/needle-2.4.0.tgz#6833e74975c444642590e15a750288c5f939b57c" - integrity sha512-4Hnwzr3mi5L97hMYeNl8wRW/Onhy4nUKR/lVemJ8gJedxxUyBLm9kkrDColJvoSfwi0jCNhD+xCdOtiGDQiRZg== - dependencies: - debug "^3.2.6" - iconv-lite "^0.4.4" - sax "^1.2.4" - negotiator@0.6.2: version "0.6.2" resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.2.tgz#feacf7ccf525a77ae9634436a64883ffeca346fb" integrity sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw== -neo-async@^2.5.0, neo-async@^2.6.0, neo-async@^2.6.1: +neo-async@^2.5.0, neo-async@^2.6.1: version "2.6.1" resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.1.tgz#ac27ada66167fa8849a6addd837f6b189ad2081c" integrity sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw== -next-tick@^1.0.0: +next-tick@~1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/next-tick/-/next-tick-1.0.0.tgz#ca86d1fe8828169b0120208e3dc8424b9db8342c" integrity sha1-yobR/ogoFpsBICCOPchCS524NCw= @@ -8057,33 +8396,15 @@ node-notifier@^5.4.2: shellwords "^0.1.1" which "^1.3.0" -node-pre-gyp@^0.12.0: - version "0.12.0" - resolved "https://registry.yarnpkg.com/node-pre-gyp/-/node-pre-gyp-0.12.0.tgz#39ba4bb1439da030295f899e3b520b7785766149" - integrity sha512-4KghwV8vH5k+g2ylT+sLTjy5wmUOb9vPhnM8NHvRf9dHmnW/CndrFXy2aRPaPST6dugXSdHXfeaHQm77PIz/1A== - dependencies: - detect-libc "^1.0.2" - mkdirp "^0.5.1" - needle "^2.2.1" - nopt "^4.0.1" - npm-packlist "^1.1.6" - npmlog "^4.0.2" - rc "^1.2.7" - rimraf "^2.6.1" - semver "^5.3.0" - tar "^4" - -node-releases@^1.1.29: - version "1.1.35" - resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-1.1.35.tgz#32a74a3cd497aa77f23d509f483475fd160e4c48" - integrity sha512-JGcM/wndCN/2elJlU0IGdVEJQQnJwsLbgPCFd2pY7V0mxf17bZ0Gb/lgOtL29ZQhvEX5shnVhxQyZz3ex94N8w== - dependencies: - semver "^6.3.0" +node-releases@^1.1.29, node-releases@^1.1.53: + version "1.1.56" + resolved "https://registry.yarnpkg.com/node-releases/-/node-releases-1.1.56.tgz#bc054a417d316e3adac90eafb7e1932802f28705" + integrity sha512-EVo605FhWLygH8a64TjgpjyHYOihkxECwX1bHHr8tETJKWEiWS2YJjPbvsX2jFjnjTNEgBCmk9mLjKG1Mf11cw== node-sass@^4.12.0: - version "4.12.0" - resolved "https://registry.yarnpkg.com/node-sass/-/node-sass-4.12.0.tgz#0914f531932380114a30cc5fa4fa63233a25f017" - integrity sha512-A1Iv4oN+Iel6EPv77/HddXErL2a+gZ4uBeZUy+a8O35CFYTXhgA8MgLCWBtwpGZdCvTvQ9d+bQxX/QC36GDPpQ== + version "4.14.1" + resolved "https://registry.yarnpkg.com/node-sass/-/node-sass-4.14.1.tgz#99c87ec2efb7047ed638fb4c9db7f3a42e2217b5" + integrity sha512-sjCuOlvGyCJS40R8BscF5vhVlQjNN069NtQ1gSxyK1u9iqvn6tf7O1R4GNowVZfiZUCRt5MmMs1xd+4V/7Yr0g== dependencies: async-foreach "^0.1.3" chalk "^1.1.1" @@ -8092,29 +8413,29 @@ node-sass@^4.12.0: get-stdin "^4.0.1" glob "^7.0.3" in-publish "^2.0.0" - lodash "^4.17.11" + lodash "^4.17.15" meow "^3.7.0" mkdirp "^0.5.1" nan "^2.13.2" node-gyp "^3.8.0" npmlog "^4.0.0" request "^2.88.0" - sass-graph "^2.2.4" + sass-graph "2.2.5" stdout-stream "^1.4.0" "true-case-path" "^1.0.2" nodemon@^1.19.3: - version "1.19.3" - resolved "https://registry.yarnpkg.com/nodemon/-/nodemon-1.19.3.tgz#db71b3e62aef2a8e1283a9fa00164237356102c0" - integrity sha512-TBNKRmJykEbxpTniZBusqRrUTHIEqa2fpecbTQDQj1Gxjth7kKAPP296ztR0o5gPUWsiYbuEbt73/+XMYab1+w== + version "1.19.4" + resolved "https://registry.yarnpkg.com/nodemon/-/nodemon-1.19.4.tgz#56db5c607408e0fdf8920d2b444819af1aae0971" + integrity sha512-VGPaqQBNk193lrJFotBU8nvWZPqEZY2eIzymy2jjY0fJ9qIsxA0sxQ8ATPl0gZC645gijYEc1jtZvpS8QWzJGQ== dependencies: - chokidar "^2.1.5" - debug "^3.1.0" + chokidar "^2.1.8" + debug "^3.2.6" ignore-by-default "^1.0.1" minimatch "^3.0.4" - pstree.remy "^1.1.6" - semver "^5.5.0" - supports-color "^5.2.0" + pstree.remy "^1.1.7" + semver "^5.7.1" + supports-color "^5.5.0" touch "^3.1.0" undefsafe "^2.0.2" update-notifier "^2.5.0" @@ -8126,14 +8447,6 @@ nodemon@^1.19.3: dependencies: abbrev "1" -nopt@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/nopt/-/nopt-4.0.1.tgz#d0d4685afd5415193c8c7505602d0d17cd64474d" - integrity sha1-0NRoWv1UFRk8jHUFYC0NF81kR00= - dependencies: - abbrev "1" - osenv "^0.1.4" - nopt@~1.0.10: version "1.0.10" resolved "https://registry.yarnpkg.com/nopt/-/nopt-1.0.10.tgz#6ddd21bd2a31417b92727dd585f8a6f37608ebee" @@ -8158,7 +8471,7 @@ normalize-path@^2.1.1: dependencies: remove-trailing-separator "^1.0.1" -normalize-path@^3.0.0: +normalize-path@^3.0.0, normalize-path@~3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== @@ -8183,19 +8496,6 @@ normalize-url@^3.0.0: resolved "https://registry.yarnpkg.com/normalize-url/-/normalize-url-3.3.0.tgz#b2e1c4dc4f7c6d57743df733a4f5978d18650559" integrity sha512-U+JJi7duF1o+u2pynbp2zXDW2/PADgC30f0GsHZtRh+HOcXHnw137TrNlyxxRvWW5fjKd3bcLHPxofWuCjaeZg== -npm-bundled@^1.0.1: - version "1.0.6" - resolved "https://registry.yarnpkg.com/npm-bundled/-/npm-bundled-1.0.6.tgz#e7ba9aadcef962bb61248f91721cd932b3fe6bdd" - integrity sha512-8/JCaftHwbd//k6y2rEWp6k1wxVfpFzB6t1p825+cUb7Ym2XQfhwIC5KwhrvzZRJu+LtDE585zVaS32+CGtf0g== - -npm-packlist@^1.1.6: - version "1.4.6" - resolved "https://registry.yarnpkg.com/npm-packlist/-/npm-packlist-1.4.6.tgz#53ba3ed11f8523079f1457376dd379ee4ea42ff4" - integrity sha512-u65uQdb+qwtGvEJh/DgQgW1Xg7sqeNbmxYyrvlNznaVTjV3E5P6F/EFjM+BVHXl7JJlsdG8A64M0XI8FI/IOlg== - dependencies: - ignore-walk "^3.0.1" - npm-bundled "^1.0.1" - npm-run-path@^2.0.0: version "2.0.2" resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-2.0.2.tgz#35a9232dfa35d7067b4cb2ddf2357b1871536c5f" @@ -8203,7 +8503,7 @@ npm-run-path@^2.0.0: dependencies: path-key "^2.0.0" -"npmlog@0 || 1 || 2 || 3 || 4", npmlog@^4.0.0, npmlog@^4.0.2: +"npmlog@0 || 1 || 2 || 3 || 4", npmlog@^4.0.0: version "4.1.2" resolved "https://registry.yarnpkg.com/npmlog/-/npmlog-4.1.2.tgz#08a7f2a8bf734604779a9efa4ad5cc717abb954b" integrity sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg== @@ -8231,16 +8531,16 @@ number-is-nan@^1.0.0: integrity sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0= nwsapi@^2.0.7, nwsapi@^2.1.3: - version "2.1.4" - resolved "https://registry.yarnpkg.com/nwsapi/-/nwsapi-2.1.4.tgz#e006a878db23636f8e8a67d33ca0e4edf61a842f" - integrity sha512-iGfd9Y6SFdTNldEy2L0GUhcarIutFmk+MPWIn9dmj8NMIup03G08uUF2KGbbmv/Ux4RT0VZJoP/sVbWA6d/VIw== + version "2.2.0" + resolved "https://registry.yarnpkg.com/nwsapi/-/nwsapi-2.2.0.tgz#204879a9e3d068ff2a55139c2c772780681a38b7" + integrity sha512-h2AatdwYH+JHiZpv7pt/gSX1XoRGb7L/qSIeuqA6GwYoF9w1vP1cw42TO0aI2pNyshRK5893hNSl+1//vHK7hQ== oauth-sign@~0.9.0: version "0.9.0" resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.9.0.tgz#47a7b016baa68b5fa0ecf3dee08a85c679ac6455" integrity sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ== -object-assign@4.1.1, object-assign@^4, object-assign@^4.0.1, object-assign@^4.1.0, object-assign@^4.1.1: +object-assign@^4, object-assign@^4.0.1, object-assign@^4.1.0, object-assign@^4.1.1: version "4.1.1" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" integrity sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM= @@ -8259,15 +8559,18 @@ object-hash@^1.3.1: resolved "https://registry.yarnpkg.com/object-hash/-/object-hash-1.3.1.tgz#fde452098a951cb145f039bb7d455449ddc126df" integrity sha512-OSuu/pU4ENM9kmREg0BdNrUDIl1heYa4mBZacJc+vVWz4GtAwu7jO8s4AIt2aGRUTqxykpWzI3Oqnsm13tTMDA== -object-inspect@^1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.6.0.tgz#c70b6cbf72f274aab4c34c0c82f5167bf82cf15b" - integrity sha512-GJzfBZ6DgDAmnuaM3104jR4s1Myxr3Y3zfIyN4z3UdqN69oSRacNK8UhnobDdC+7J2AHCjGwxQubNJfE70SXXQ== +object-inspect@^1.7.0: + version "1.7.0" + resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.7.0.tgz#f4f6bd181ad77f006b5ece60bd0b6f398ff74a67" + integrity sha512-a7pEHdh1xKIAgTySUGgLMx/xwDZskN1Ud6egYYN3EdRW4ZMPNEDUTF+hwy2LUC+Bl+SyLXANnwz/jyh/qutKUw== object-is@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/object-is/-/object-is-1.0.1.tgz#0aa60ec9989a0b3ed795cf4d06f62cf1ad6539b6" - integrity sha1-CqYOyZiaCz7Xlc9NBvYs8a1lObY= + version "1.1.2" + resolved "https://registry.yarnpkg.com/object-is/-/object-is-1.1.2.tgz#c5d2e87ff9e119f78b7a088441519e2eec1573b6" + integrity sha512-5lHCz+0uufF6wZ7CRFWJN3hp8Jqblpgve06U5CMQ3f//6iDjPr2PEo9MWCjEssDsa+UZEL4PkFpr+BMop6aKzQ== + dependencies: + define-properties "^1.1.3" + es-abstract "^1.17.5" object-keys@^1.0.11, object-keys@^1.0.12, object-keys@^1.1.1: version "1.1.1" @@ -8297,32 +8600,31 @@ object.assign@^4.1.0: object-keys "^1.0.11" object.entries@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/object.entries/-/object.entries-1.1.0.tgz#2024fc6d6ba246aee38bdb0ffd5cfbcf371b7519" - integrity sha512-l+H6EQ8qzGRxbkHOd5I/aHRhHDKoQXQ8g0BYt4uSweQU1/J6dZUOyWh9a2Vky35YCKjzmgxOzta2hH6kf9HuXA== + version "1.1.2" + resolved "https://registry.yarnpkg.com/object.entries/-/object.entries-1.1.2.tgz#bc73f00acb6b6bb16c203434b10f9a7e797d3add" + integrity sha512-BQdB9qKmb/HyNdMNWVr7O3+z5MUIx3aiegEIJqjMBbBf0YT9RRxTJSim4mzFqtyr7PDAHigq0N9dO0m0tRakQA== dependencies: define-properties "^1.1.3" - es-abstract "^1.12.0" - function-bind "^1.1.1" + es-abstract "^1.17.5" has "^1.0.3" object.fromentries@^2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/object.fromentries/-/object.fromentries-2.0.1.tgz#050f077855c7af8ae6649f45c80b16ee2d31e704" - integrity sha512-PUQv8Hbg3j2QX0IQYv3iAGCbGcu4yY4KQ92/dhA4sFSixBmSmp13UpDLs6jGK8rBtbmhNNIK99LD2k293jpiGA== + version "2.0.2" + resolved "https://registry.yarnpkg.com/object.fromentries/-/object.fromentries-2.0.2.tgz#4a09c9b9bb3843dd0f89acdb517a794d4f355ac9" + integrity sha512-r3ZiBH7MQppDJVLx6fhD618GKNG40CZYH9wgwdhKxBDDbQgjeWGGd4AtkZad84d291YxvWe7bJGuE65Anh0dxQ== dependencies: define-properties "^1.1.3" - es-abstract "^1.15.0" + es-abstract "^1.17.0-next.1" function-bind "^1.1.1" has "^1.0.3" -object.getownpropertydescriptors@^2.0.3: - version "2.0.3" - resolved "https://registry.yarnpkg.com/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.0.3.tgz#8758c846f5b407adab0f236e0986f14b051caa16" - integrity sha1-h1jIRvW0B62rDyNuCYbxSwUcqhY= +object.getownpropertydescriptors@^2.0.3, object.getownpropertydescriptors@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/object.getownpropertydescriptors/-/object.getownpropertydescriptors-2.1.0.tgz#369bf1f9592d8ab89d712dced5cb81c7c5352649" + integrity sha512-Z53Oah9A3TdLoblT7VKJaTDdXdT+lQO+cNpKVnya5JDe9uLvzu1YyY1yFDFrcxrlRgWrEFH0jJtD/IbuwjcEVg== dependencies: - define-properties "^1.1.2" - es-abstract "^1.5.1" + define-properties "^1.1.3" + es-abstract "^1.17.0-next.1" object.pick@^1.3.0: version "1.3.0" @@ -8332,12 +8634,12 @@ object.pick@^1.3.0: isobject "^3.0.1" object.values@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/object.values/-/object.values-1.1.0.tgz#bf6810ef5da3e5325790eaaa2be213ea84624da9" - integrity sha512-8mf0nKLAoFX6VlNVdhGj31SVYpaNFtUnuoOXWyFEstsWRgU837AK+JYM0iAxwkSzGRbwn8cbFmgbyxj1j4VbXg== + version "1.1.1" + resolved "https://registry.yarnpkg.com/object.values/-/object.values-1.1.1.tgz#68a99ecde356b7e9295a3c5e0ce31dc8c953de5e" + integrity sha512-WTa54g2K8iu0kmS/us18jEmdv1a4Wi//BZ/DTVYEcH0XhLM5NYdpDHja3gt57VrZLcNAO2WGA+KpWsDBaHt6eA== dependencies: define-properties "^1.1.3" - es-abstract "^1.12.0" + es-abstract "^1.17.0-next.1" function-bind "^1.1.1" has "^1.0.3" @@ -8398,14 +8700,6 @@ opn@^5.1.0: dependencies: is-wsl "^1.1.0" -optimist@^0.6.1: - version "0.6.1" - resolved "https://registry.yarnpkg.com/optimist/-/optimist-0.6.1.tgz#da3ea74686fa21a19a111c326e90eb15a0196686" - integrity sha1-2j6nRob6IaGaERwybpDrFaAZZoY= - dependencies: - minimist "~0.0.1" - wordwrap "~0.0.2" - optimize-css-assets-webpack-plugin@5.0.3: version "5.0.3" resolved "https://registry.yarnpkg.com/optimize-css-assets-webpack-plugin/-/optimize-css-assets-webpack-plugin-5.0.3.tgz#e2f1d4d94ad8c0af8967ebd7cf138dcb1ef14572" @@ -8414,17 +8708,17 @@ optimize-css-assets-webpack-plugin@5.0.3: cssnano "^4.1.10" last-call-webpack-plugin "^3.0.0" -optionator@^0.8.1, optionator@^0.8.2: - version "0.8.2" - resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.2.tgz#364c5e409d3f4d6301d6c0b4c05bba50180aeb64" - integrity sha1-NkxeQJ0/TWMB1sC0wFu6UBgK62Q= +optionator@^0.8.1, optionator@^0.8.3: + version "0.8.3" + resolved "https://registry.yarnpkg.com/optionator/-/optionator-0.8.3.tgz#84fa1d036fe9d3c7e21d99884b601167ec8fb495" + integrity sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA== dependencies: deep-is "~0.1.3" - fast-levenshtein "~2.0.4" + fast-levenshtein "~2.0.6" levn "~0.3.0" prelude-ls "~1.1.2" type-check "~0.3.2" - wordwrap "~1.0.0" + word-wrap "~1.2.3" original@^1.0.0: version "1.0.2" @@ -8443,13 +8737,6 @@ os-homedir@^1.0.0, os-homedir@^1.0.1: resolved "https://registry.yarnpkg.com/os-homedir/-/os-homedir-1.0.2.tgz#ffbc4988336e0e833de0c168c7ef152121aa7fb3" integrity sha1-/7xJiDNuDoM94MFox+8VISGqf7M= -os-locale@^1.4.0: - version "1.4.0" - resolved "https://registry.yarnpkg.com/os-locale/-/os-locale-1.4.0.tgz#20f9f17ae29ed345e8bde583b13d2009803c14d9" - integrity sha1-IPnxeuKe00XoveWDsT0gCYA8FNk= - dependencies: - lcid "^1.0.0" - os-locale@^3.0.0: version "3.1.0" resolved "https://registry.yarnpkg.com/os-locale/-/os-locale-3.1.0.tgz#a802a6ee17f24c10483ab9935719cef4ed16bf1a" @@ -8464,7 +8751,7 @@ os-tmpdir@^1.0.0, os-tmpdir@~1.0.2: resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" integrity sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ= -osenv@0, osenv@^0.1.4: +osenv@0: version "0.1.5" resolved "https://registry.yarnpkg.com/osenv/-/osenv-0.1.5.tgz#85cdfafaeb28e8677f416e287592b5f3f49ea410" integrity sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g== @@ -8502,9 +8789,9 @@ p-limit@^1.1.0: p-try "^1.0.0" p-limit@^2.0.0, p-limit@^2.2.0: - version "2.2.1" - resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-2.2.1.tgz#aa07a788cc3151c939b5131f63570f0dd2009537" - integrity sha512-85Tk+90UCVWvbDavCLKPOLC9vvY8OwEX/RtKF+/1OADJMVlFfEHOiMTPVyxg7mk/dKa+ipdHm0OUkTvCpMTuwg== + version "2.3.0" + resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-2.3.0.tgz#3dd33c647a214fdfffd835933eb086da0dc21db1" + integrity sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w== dependencies: p-try "^2.0.0" @@ -8553,9 +8840,9 @@ package-json@^4.0.0: semver "^5.1.0" pako@~1.0.5: - version "1.0.10" - resolved "https://registry.yarnpkg.com/pako/-/pako-1.0.10.tgz#4328badb5086a426aa90f541977d4955da5c9732" - integrity sha512-0DTvPVU3ed8+HNXOu5Bs+o//Mbdj9VNQMUOe9oKCwh8l0GNwpTDMKCWbRjgtD291AWnkAgkqA/LOnQS8AmS1tw== + version "1.0.11" + resolved "https://registry.yarnpkg.com/pako/-/pako-1.0.11.tgz#6c9599d340d54dfd3946380252a35705a6b992bf" + integrity sha512-4hLB8Py4zZce5s4yd9XzopqwVv/yGNhV1Bl8NTmCq1763HeK2+EwVTv+leGeL13Dnh2wfbqowVPXCIO0z4taYw== parallel-transform@^1.1.0: version "1.2.0" @@ -8580,7 +8867,7 @@ parent-module@^1.0.0: dependencies: callsites "^3.0.0" -parse-asn1@^5.0.0: +parse-asn1@^5.0.0, parse-asn1@^5.1.5: version "5.1.5" resolved "https://registry.yarnpkg.com/parse-asn1/-/parse-asn1-5.1.5.tgz#003271343da58dc94cace494faef3d2147ecea0e" integrity sha512-jkMYn1dcJqF6d5CpU689bq7w/b5ALS9ROVSpQDPrZsqqesUJii9qutvoT5ltGedNXMO2e16YUWIghG9KxaViTQ== @@ -8607,6 +8894,16 @@ parse-json@^4.0.0: error-ex "^1.3.1" json-parse-better-errors "^1.0.1" +parse-json@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-5.0.0.tgz#73e5114c986d143efa3712d4ea24db9a4266f60f" + integrity sha512-OOY5b7PAEFV0E2Fir1KOkxchnZNCdowAJgQ5NuxjpBKTRP3pQhwkrkxqQjeoKJ+fO7bCpmIZaogI4eZGDMEGOw== + dependencies: + "@babel/code-frame" "^7.0.0" + error-ex "^1.3.1" + json-parse-better-errors "^1.0.1" + lines-and-columns "^1.1.6" + parse-passwd@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/parse-passwd/-/parse-passwd-1.0.0.tgz#6d5b934a456993b23d37f40a382d6f1666a8e5c6" @@ -8702,6 +8999,11 @@ path-type@^3.0.0: dependencies: pify "^3.0.0" +path-type@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/path-type/-/path-type-4.0.0.tgz#84ed01c0a7ba380afe09d90a8c180dcd9d03043b" + integrity sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw== + pbkdf2@^3.0.17, pbkdf2@^3.0.3, pbkdf2@^3.0.9: version "3.0.17" resolved "https://registry.yarnpkg.com/pbkdf2/-/pbkdf2-3.0.17.tgz#976c206530617b14ebb32114239f7b09336e93a6" @@ -8723,10 +9025,10 @@ performance-now@^2.1.0: resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" integrity sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns= -picomatch@^2.0.5: - version "2.0.7" - resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.0.7.tgz#514169d8c7cd0bdbeecc8a2609e34a7163de69f6" - integrity sha512-oLHIdio3tZ0qH76NybpeneBhYVj0QFTfXEFTc/B3zKQspYfYYkWYgFsmzo+4kvId/bQRcNkVeguI3y+CD22BtA== +picomatch@^2.0.4, picomatch@^2.0.5, picomatch@^2.2.1: + version "2.2.2" + resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.2.2.tgz#21f333e9b6b8eaff02468f5146ea406d345f4dad" + integrity sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg== pify@^2.0.0: version "2.3.0" @@ -8783,7 +9085,7 @@ pkg-dir@^3.0.0: dependencies: find-up "^3.0.0" -pkg-up@2.0.0: +pkg-up@2.0.0, pkg-up@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/pkg-up/-/pkg-up-2.0.0.tgz#c819ac728059a461cab1c3889a2be3c49a004d7f" integrity sha1-yBmscoBZpGHKscOImivjxJoATX8= @@ -8808,13 +9110,13 @@ polished@^1.9.3: integrity sha512-4NmSD7fMFlM8roNxs7YXPv7UFRbYzb0gufR5zBxJLRzY54+zFsavxBo6zsQzP9ep6Hh3pC2pTyrpSTBEaB6IkQ== portfinder@^1.0.9: - version "1.0.24" - resolved "https://registry.yarnpkg.com/portfinder/-/portfinder-1.0.24.tgz#11efbc6865f12f37624b6531ead1d809ed965cfa" - integrity sha512-ekRl7zD2qxYndYflwiryJwMioBI7LI7rVXg3EnLK3sjkouT5eOuhS3gS255XxBksa30VG8UPZYZCdgfGOfkSUg== + version "1.0.26" + resolved "https://registry.yarnpkg.com/portfinder/-/portfinder-1.0.26.tgz#475658d56ca30bed72ac7f1378ed350bd1b64e70" + integrity sha512-Xi7mKxJHHMI3rIUrnm/jjUgwhbYMkp/XKEcZX3aG4BrumLpq3nmoQMX+ClYnDZnZ/New7IatC1no5RX0zo1vXQ== dependencies: - async "^1.5.2" - debug "^2.2.0" - mkdirp "0.5.x" + async "^2.6.2" + debug "^3.1.1" + mkdirp "^0.5.1" posix-character-classes@^0.1.0: version "0.1.1" @@ -8822,12 +9124,12 @@ posix-character-classes@^0.1.0: integrity sha1-AerA/jta9xoqbAL+q7jB/vfgDqs= postcss-attribute-case-insensitive@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/postcss-attribute-case-insensitive/-/postcss-attribute-case-insensitive-4.0.1.tgz#b2a721a0d279c2f9103a36331c88981526428cc7" - integrity sha512-L2YKB3vF4PetdTIthQVeT+7YiSzMoNMLLYxPXXppOOP7NoazEAy45sh2LvJ8leCQjfBcfkYQs8TtCcQjeZTp8A== + version "4.0.2" + resolved "https://registry.yarnpkg.com/postcss-attribute-case-insensitive/-/postcss-attribute-case-insensitive-4.0.2.tgz#d93e46b504589e94ac7277b0463226c68041a880" + integrity sha512-clkFxk/9pcdb4Vkn0hAHq3YnxBQ2p0CGD1dy24jN+reBck+EWxMbxSUqN4Yj7t0w8csl87K6p0gxBe1utkJsYA== dependencies: postcss "^7.0.2" - postcss-selector-parser "^5.0.0" + postcss-selector-parser "^6.0.2" postcss-browser-comments@^2.0.0: version "2.0.0" @@ -8837,14 +9139,13 @@ postcss-browser-comments@^2.0.0: postcss "^7.0.2" postcss-calc@^7.0.1: - version "7.0.1" - resolved "https://registry.yarnpkg.com/postcss-calc/-/postcss-calc-7.0.1.tgz#36d77bab023b0ecbb9789d84dcb23c4941145436" - integrity sha512-oXqx0m6tb4N3JGdmeMSc/i91KppbYsFZKdH0xMOqK8V1rJlzrKlTdokz8ozUXLVejydRN6u2IddxpcijRj2FqQ== + version "7.0.2" + resolved "https://registry.yarnpkg.com/postcss-calc/-/postcss-calc-7.0.2.tgz#504efcd008ca0273120568b0792b16cdcde8aac1" + integrity sha512-rofZFHUg6ZIrvRwPeFktv06GdbDYLcGqh9EwiMutZg+a0oePCCw1zHOEiji6LCpyRcjTREtPASuUqeAvYlEVvQ== dependencies: - css-unit-converter "^1.1.1" - postcss "^7.0.5" - postcss-selector-parser "^5.0.0-rc.4" - postcss-value-parser "^3.3.1" + postcss "^7.0.27" + postcss-selector-parser "^6.0.2" + postcss-value-parser "^4.0.2" postcss-color-functional-notation@^2.0.1: version "2.0.1" @@ -9026,9 +9327,9 @@ postcss-image-set-function@^3.0.1: postcss-values-parser "^2.0.0" postcss-initial@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/postcss-initial/-/postcss-initial-3.0.1.tgz#99d319669a13d6c06ef8e70d852f68cb1b399b61" - integrity sha512-I2Sz83ZSHybMNh02xQDK609lZ1/QOyYeuizCjzEhlMgeV/HcDJapQiH4yTqLjZss0X6/6VvKFXUeObaHpJoINw== + version "3.0.2" + resolved "https://registry.yarnpkg.com/postcss-initial/-/postcss-initial-3.0.2.tgz#f018563694b3c16ae8eaabe3c585ac6319637b2d" + integrity sha512-ugA2wKonC0xeNHgirR4D3VWHs2JcU08WAi1KFLVcnb7IN89phID6Qtg2RIctWbnvp1TM2BOmDtX8GGLCKdR8YA== dependencies: lodash.template "^4.5.0" postcss "^7.0.2" @@ -9153,9 +9454,9 @@ postcss-modules-local-by-default@^2.0.6: postcss-value-parser "^3.3.1" postcss-modules-scope@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/postcss-modules-scope/-/postcss-modules-scope-2.1.0.tgz#ad3f5bf7856114f6fcab901b0502e2a2bc39d4eb" - integrity sha512-91Rjps0JnmtUB0cujlc8KIKCsJXWjzuxGeT/+Q2i2HXKZ7nBUeF9YQTZZTNvHVoNYj1AthsjnGLtqDUE0Op79A== + version "2.2.0" + resolved "https://registry.yarnpkg.com/postcss-modules-scope/-/postcss-modules-scope-2.2.0.tgz#385cae013cc7743f5a7d7602d1073a89eaae62ee" + integrity sha512-YyEgsTMRpNd+HmyC7H/mh3y+MeFWevy7V1evVhJWewmMbjDHIbZbOXICC2y+m1xI1UVfIT1HMW/O04Hxyu9oXQ== dependencies: postcss "^7.0.6" postcss-selector-parser "^6.0.0" @@ -9399,15 +9700,15 @@ postcss-selector-not@^4.0.0: postcss "^7.0.2" postcss-selector-parser@^3.0.0: - version "3.1.1" - resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-3.1.1.tgz#4f875f4afb0c96573d5cf4d74011aee250a7e865" - integrity sha1-T4dfSvsMllc9XPTXQBGu4lCn6GU= + version "3.1.2" + resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-3.1.2.tgz#b310f5c4c0fdaf76f94902bbaa30db6aa84f5270" + integrity sha512-h7fJ/5uWuRVyOtkO45pnt1Ih40CEleeyCHzipqAZO2e5H20g25Y48uYnFUiShvY4rZWNJ/Bib/KVPmanaCtOhA== dependencies: - dot-prop "^4.1.1" + dot-prop "^5.2.0" indexes-of "^1.0.1" uniq "^1.0.1" -postcss-selector-parser@^5.0.0, postcss-selector-parser@^5.0.0-rc.3, postcss-selector-parser@^5.0.0-rc.4: +postcss-selector-parser@^5.0.0-rc.3, postcss-selector-parser@^5.0.0-rc.4: version "5.0.0" resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-5.0.0.tgz#249044356697b33b64f1a8f7c80922dddee7195c" integrity sha512-w+zLE5Jhg6Liz8+rQOWEAwtwkyqpfnmsinXjXg6cY7YIONZZtgvE0v2O0uhQBs0peNomOJwWRKt6JBfTdTd3OQ== @@ -9416,7 +9717,7 @@ postcss-selector-parser@^5.0.0, postcss-selector-parser@^5.0.0-rc.3, postcss-sel indexes-of "^1.0.1" uniq "^1.0.1" -postcss-selector-parser@^6.0.0: +postcss-selector-parser@^6.0.0, postcss-selector-parser@^6.0.2: version "6.0.2" resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-6.0.2.tgz#934cf799d016c83411859e09dcecade01286ec5c" integrity sha512-36P2QR59jDTOAiIkqEprfJDsoNrvwFei3eCqKd1Y0tUsBimsq39BLp7RD+JWny3WgB1zGhJX8XVePwm9k4wdBg== @@ -9449,10 +9750,10 @@ postcss-value-parser@^3.0.0, postcss-value-parser@^3.3.0, postcss-value-parser@^ resolved "https://registry.yarnpkg.com/postcss-value-parser/-/postcss-value-parser-3.3.1.tgz#9ff822547e2893213cf1c30efa51ac5fd1ba8281" integrity sha512-pISE66AbVkp4fDQ7VHBwRNXzAAKJjw4Vw7nWI/+Q3vuly7SNfgYXvm6i5IgFylHGK5sP/xHAbB7N49OS4gWNyQ== -postcss-value-parser@^4.0.2: - version "4.0.2" - resolved "https://registry.yarnpkg.com/postcss-value-parser/-/postcss-value-parser-4.0.2.tgz#482282c09a42706d1fc9a069b73f44ec08391dc9" - integrity sha512-LmeoohTpp/K4UiyQCwuGWlONxXamGzCMtFxLq4W1nZVGIQLYvMCJx3yAF9qyyuFpflABI9yVdtJAqbihOsCsJQ== +postcss-value-parser@^4.0.2, postcss-value-parser@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/postcss-value-parser/-/postcss-value-parser-4.1.0.tgz#443f6a20ced6481a2bda4fa8532a6e55d789a2cb" + integrity sha512-97DXOFbQJhk71ne5/Mt6cOu6yxsSfM0QGQyl0L25Gca4yGWEGJaig7l7gbCX623VqTBNGLRLaVUCnNkcedlRSQ== postcss-values-parser@^2.0.0, postcss-values-parser@^2.0.1: version "2.0.1" @@ -9472,10 +9773,10 @@ postcss@7.0.14: source-map "^0.6.1" supports-color "^6.1.0" -postcss@^7.0.0, postcss@^7.0.1, postcss@^7.0.14, postcss@^7.0.17, postcss@^7.0.18, postcss@^7.0.2, postcss@^7.0.5, postcss@^7.0.6: - version "7.0.18" - resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.18.tgz#4b9cda95ae6c069c67a4d933029eddd4838ac233" - integrity sha512-/7g1QXXgegpF+9GJj4iN7ChGF40sYuGYJ8WZu8DZWnmhQ/G36hfdk3q9LBJmoK+lZ+yzZ5KYpOoxq7LF1BxE8g== +postcss@^7.0.0, postcss@^7.0.1, postcss@^7.0.14, postcss@^7.0.17, postcss@^7.0.2, postcss@^7.0.27, postcss@^7.0.30, postcss@^7.0.5, postcss@^7.0.6: + version "7.0.30" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-7.0.30.tgz#cc9378beffe46a02cbc4506a0477d05fcea9a8e2" + integrity sha512-nu/0m+NtIzoubO+xdAlwZl/u5S5vi/y6BCsoL8D+8IxsD3XvBS8X4YEADNIVXKVuQvduiucnRv+vPIqj56EGMQ== dependencies: chalk "^2.4.2" source-map "^0.6.1" @@ -9514,7 +9815,17 @@ pretty-format@^24.9.0: ansi-styles "^3.2.0" react-is "^16.8.4" -private@^0.1.6: +pretty-format@^26.0.1: + version "26.0.1" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-26.0.1.tgz#a4fe54fe428ad2fd3413ca6bbd1ec8c2e277e197" + integrity sha512-SWxz6MbupT3ZSlL0Po4WF/KujhQaVehijR2blyRDCzk9e45EaYMVhMBn49fnRuHxtkSpXTes1GxNpVmH86Bxfw== + dependencies: + "@jest/types" "^26.0.1" + ansi-regex "^5.0.0" + ansi-styles "^4.0.0" + react-is "^16.12.0" + +private@^0.1.8: version "0.1.8" resolved "https://registry.yarnpkg.com/private/-/private-0.1.8.tgz#2381edb3689f7a53d653190060fcf822d2f368ff" integrity sha512-VvivMrbvd2nKkiG38qjULzlc+4Vx4wm/whI9pQD35YrARNnhxeiRktSOhSukRLFNlzg6Br/cJPet5J/u19r/mg== @@ -9546,20 +9857,20 @@ promise-inflight@^1.0.1: resolved "https://registry.yarnpkg.com/promise-inflight/-/promise-inflight-1.0.1.tgz#98472870bf228132fcbdd868129bad12c3c029e3" integrity sha1-mEcocL8igTL8vdhoEputEsPAKeM= -promise@8.0.3: - version "8.0.3" - resolved "https://registry.yarnpkg.com/promise/-/promise-8.0.3.tgz#f592e099c6cddc000d538ee7283bb190452b0bf6" - integrity sha512-HeRDUL1RJiLhyA0/grn+PTShlBAcLuh/1BJGtrvjwbvRDCTLLMEz9rOGCV+R3vHY4MixIuoMEd9Yq/XvsTPcjw== +promise@^8.0.3: + version "8.1.0" + resolved "https://registry.yarnpkg.com/promise/-/promise-8.1.0.tgz#697c25c3dfe7435dd79fcd58c38a135888eaf05e" + integrity sha512-W04AqnILOL/sPRXziNicCjSNRruLAuIHEOVBazepu0545DDNGYHz7ar9ZgZ1fMU8/MA4mVxp5rkBWRi6OXIy3Q== dependencies: asap "~2.0.6" -prompts@^2.0.1, prompts@^2.1.0: - version "2.2.1" - resolved "https://registry.yarnpkg.com/prompts/-/prompts-2.2.1.tgz#f901dd2a2dfee080359c0e20059b24188d75ad35" - integrity sha512-VObPvJiWPhpZI6C5m60XOzTfnYg/xc/an+r9VYymj9WJW3B/DIH+REzjpAACPf8brwPeP+7vz3bIim3S+AaMjw== +prompts@^2.0.1, prompts@^2.3.0: + version "2.3.2" + resolved "https://registry.yarnpkg.com/prompts/-/prompts-2.3.2.tgz#480572d89ecf39566d2bd3fe2c9fccb7c4c0b068" + integrity sha512-Q06uKs2CkNYVID0VqwfAl9mipo99zkBv/n2JtWY89Yxa3ZabWSrs0e2KTudKVa3peLUvYXMefDqIleLPVUBZMA== dependencies: kleur "^3.0.3" - sisteransi "^1.0.3" + sisteransi "^1.0.4" prop-types-exact@^1.2.0: version "1.2.0" @@ -9570,7 +9881,7 @@ prop-types-exact@^1.2.0: object.assign "^4.1.0" reflect.ownkeys "^0.2.0" -prop-types@^15.5.10, prop-types@^15.5.4, prop-types@^15.5.7, prop-types@^15.6.2, prop-types@^15.7.2: +prop-types@^15.5.4, prop-types@^15.5.7, prop-types@^15.6.2, prop-types@^15.7.2: version "15.7.2" resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.7.2.tgz#52c41e75b8c87e72b9d9360e0206b99dcbffa6c5" integrity sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ== @@ -9580,17 +9891,17 @@ prop-types@^15.5.10, prop-types@^15.5.4, prop-types@^15.5.7, prop-types@^15.6.2, react-is "^16.8.1" proxy-addr@~2.0.5: - version "2.0.5" - resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-2.0.5.tgz#34cbd64a2d81f4b1fd21e76f9f06c8a45299ee34" - integrity sha512-t/7RxHXPH6cJtP0pRG6smSr9QJidhB+3kXu0KgXnbGYMgzEnUxRQ4/LDdfOwZEMyIh3/xHb8PX3t+lfL9z+YVQ== + version "2.0.6" + resolved "https://registry.yarnpkg.com/proxy-addr/-/proxy-addr-2.0.6.tgz#fdc2336505447d3f2f2c638ed272caf614bbb2bf" + integrity sha512-dh/frvCBVmSsDYzw6n926jv974gddhkFPfiN8hPOi30Wax25QZyZEGveluCgliBnqmuM+UJmBErbAUFIoDbjOw== dependencies: forwarded "~0.1.2" - ipaddr.js "1.9.0" + ipaddr.js "1.9.1" proxy-from-env@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/proxy-from-env/-/proxy-from-env-1.0.0.tgz#33c50398f70ea7eb96d21f7b817630a55791c7ee" - integrity sha1-M8UDmPcOp+uW0h97gXYwpVeRx+4= + version "1.1.0" + resolved "https://registry.yarnpkg.com/proxy-from-env/-/proxy-from-env-1.1.0.tgz#e102f16ca355424865755d2c9e8ea4f24d58c3e2" + integrity sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg== prr@~1.0.1: version "1.0.1" @@ -9602,15 +9913,15 @@ pseudomap@^1.0.2: resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3" integrity sha1-8FKijacOYYkX7wqKw0wa5aaChrM= -psl@^1.1.24, psl@^1.1.28: - version "1.4.0" - resolved "https://registry.yarnpkg.com/psl/-/psl-1.4.0.tgz#5dd26156cdb69fa1fdb8ab1991667d3f80ced7c2" - integrity sha512-HZzqCGPecFLyoRj5HLfuDSKYTJkAfB5thKBIkRHtGjWwY7p1dAyveIbXIq4tO0KYfDF2tHqPUgY9SDnGm00uFw== +psl@^1.1.28: + version "1.8.0" + resolved "https://registry.yarnpkg.com/psl/-/psl-1.8.0.tgz#9326f8bcfb013adcc005fdff056acce020e51c24" + integrity sha512-RIdOzyoavK+hA18OGGWDqUTsCLhtA7IcZ/6NCs4fFJaHBDab+pDDmDIByWFRQJq2Cd7r1OoQxBGKOaztq+hjIQ== -pstree.remy@^1.1.6: - version "1.1.7" - resolved "https://registry.yarnpkg.com/pstree.remy/-/pstree.remy-1.1.7.tgz#c76963a28047ed61542dc361aa26ee55a7fa15f3" - integrity sha512-xsMgrUwRpuGskEzBFkH8NmTimbZ5PcPup0LA8JJkHIm2IMUbQcpo3yeLNWVrufEYjh8YwtSVh0xz6UeWc5Oh5A== +pstree.remy@^1.1.7: + version "1.1.8" + resolved "https://registry.yarnpkg.com/pstree.remy/-/pstree.remy-1.1.8.tgz#c242224f4a67c21f686839bbdb4ac282b8373d3a" + integrity sha512-77DZwxQmxKnu3aR542U+X8FypNzbfJ+C5XQDk3uWjWxn6151aIMGthWYRXTqT1E5oJvg+ljaa2OJi+VfvCOQ8w== public-encrypt@^4.0.0: version "4.0.3" @@ -9663,7 +9974,7 @@ punycode@1.3.2: resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.3.2.tgz#9653a036fb7c1ee42342f2325cceefea3926c48d" integrity sha1-llOgNvt8HuQjQvIyXM7v6jkmxI0= -punycode@^1.2.4, punycode@^1.4.1: +punycode@^1.2.4: version "1.4.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" integrity sha1-wNWmOycYgArY4esPpSachN1BhF4= @@ -9725,7 +10036,7 @@ querystringify@^2.1.1: resolved "https://registry.yarnpkg.com/querystringify/-/querystringify-2.1.1.tgz#60e5a5fd64a7f8bfa4d2ab2ed6fdf4c85bad154e" integrity sha512-w7fLxIRCRT7U8Qu53jQnJyPkYZIaR4n5151KMfcJlO/A9397Wxb1amJvROTK6TOnp7PfoAmg/qXiNHI+08jRfA== -raf@3.4.1: +raf@^3.4.1: version "3.4.1" resolved "https://registry.yarnpkg.com/raf/-/raf-3.4.1.tgz#0742e99a4a6552f445d73e3ee0328af0ff1ede39" integrity sha512-Sq4CW4QhwOHE8ucn6J34MqtZCeWFP2aQSmrlroYgqAV1PjStIhJXxYuTgUIfkEk7zTLjmIjLmU5q+fbD1NnOJA== @@ -9762,7 +10073,7 @@ raw-body@2.4.0: iconv-lite "0.4.24" unpipe "1.0.0" -rc@^1.0.1, rc@^1.1.6, rc@^1.2.7: +rc@^1.0.1, rc@^1.1.6: version "1.2.8" resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.8.tgz#cd924bf5200a075b83c188cd6b9e211b7fc0d3ed" integrity sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw== @@ -9773,16 +10084,16 @@ rc@^1.0.1, rc@^1.1.6, rc@^1.2.7: strip-json-comments "~2.0.1" react-app-polyfill@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/react-app-polyfill/-/react-app-polyfill-1.0.4.tgz#4dd2636846b585c2d842b1e44e1bc29044345874" - integrity sha512-5Vte6ki7jpNsNCUKaboyofAhmURmCn2Y6Hu7ydJ6Iu4dct1CIGoh/1FT7gUZKAbowVX2lxVPlijvp1nKxfAl4w== + version "1.0.6" + resolved "https://registry.yarnpkg.com/react-app-polyfill/-/react-app-polyfill-1.0.6.tgz#890f8d7f2842ce6073f030b117de9130a5f385f0" + integrity sha512-OfBnObtnGgLGfweORmdZbyEz+3dgVePQBb3zipiaDsMHV1NpWm0rDFYIVXFV/AK+x4VIIfWHhrdMIeoTLyRr2g== dependencies: - core-js "3.2.1" - object-assign "4.1.1" - promise "8.0.3" - raf "3.4.1" - regenerator-runtime "0.13.3" - whatwg-fetch "3.0.0" + core-js "^3.5.0" + object-assign "^4.1.1" + promise "^8.0.3" + raf "^3.4.1" + regenerator-runtime "^0.13.3" + whatwg-fetch "^3.0.0" react-dev-utils@^9.1.0: version "9.1.0" @@ -9815,25 +10126,25 @@ react-dev-utils@^9.1.0: strip-ansi "5.2.0" text-table "0.2.0" -react-dom@^16.10.2, react-dom@^16.5.1: - version "16.10.2" - resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-16.10.2.tgz#4840bce5409176bc3a1f2bd8cb10b92db452fda6" - integrity sha512-kWGDcH3ItJK4+6Pl9DZB16BXYAZyrYQItU4OMy0jAkv5aNqc+mAKb4TpFtAteI6TJZu+9ZlNhaeNQSVQDHJzkw== +react-dom@^16.10.2, react-dom@^16.12.0: + version "16.13.1" + resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-16.13.1.tgz#c1bd37331a0486c078ee54c4740720993b2e0e7f" + integrity sha512-81PIMmVLnCNLO/fFOQxdQkvEq/+Hfpv24XNJfpyZhTRfO0QcmQIF/PgCa1zCOj2w1hrn12MFLyaJ/G0+Mxtfag== dependencies: loose-envify "^1.1.0" object-assign "^4.1.1" prop-types "^15.6.2" - scheduler "^0.16.2" + scheduler "^0.19.1" react-error-overlay@^6.0.3: - version "6.0.3" - resolved "https://registry.yarnpkg.com/react-error-overlay/-/react-error-overlay-6.0.3.tgz#c378c4b0a21e88b2e159a3e62b2f531fd63bf60d" - integrity sha512-bOUvMWFQVk5oz8Ded9Xb7WVdEi3QGLC8tH7HmYP0Fdp4Bn3qw0tRFmr5TW6mvahzvmrK4a6bqWGfCevBflP+Xw== + version "6.0.7" + resolved "https://registry.yarnpkg.com/react-error-overlay/-/react-error-overlay-6.0.7.tgz#1dcfb459ab671d53f660a991513cb2f0a0553108" + integrity sha512-TAv1KJFh3RhqxNvhzxj6LeT5NWklP6rDr2a0jaTfsZ5wSZWHOGeqQyejUp3xxLfPt2UpyJEcVQB/zyPcmonNFA== -react-is@^16.6.0, react-is@^16.7.0, react-is@^16.8.1, react-is@^16.8.4, react-is@^16.9.0: - version "16.10.2" - resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.10.2.tgz#984120fd4d16800e9a738208ab1fba422d23b5ab" - integrity sha512-INBT1QEgtcCCgvccr5/86CfD71fw9EPmDxgiJX4I2Ddr6ZsV6iFXsuby+qWJPtmNuMY0zByTsG4468P7nHuNWA== +react-is@^16.12.0, react-is@^16.6.0, react-is@^16.7.0, react-is@^16.8.1, react-is@^16.8.4, react-is@^16.9.0: + version "16.13.1" + resolved "https://registry.yarnpkg.com/react-is/-/react-is-16.13.1.tgz#789729a4dc36de2999dc156dd6c1d9c18cea56a4" + integrity sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ== react-outside-click-handler@^1.3.0: version "1.3.0" @@ -9847,13 +10158,12 @@ react-outside-click-handler@^1.3.0: prop-types "^15.7.2" react-redux@^7.1.1: - version "7.1.1" - resolved "https://registry.yarnpkg.com/react-redux/-/react-redux-7.1.1.tgz#ce6eee1b734a7a76e0788b3309bf78ff6b34fa0a" - integrity sha512-QsW0vcmVVdNQzEkrgzh2W3Ksvr8cqpAv5FhEk7tNEft+5pp7rXxAudTz3VOPawRkLIepItpkEIyLcN/VVXzjTg== + version "7.2.0" + resolved "https://registry.yarnpkg.com/react-redux/-/react-redux-7.2.0.tgz#f970f62192b3981642fec46fd0db18a074fe879d" + integrity sha512-EvCAZYGfOLqwV7gh849xy9/pt55rJXPwmYvI4lilPM5rUT/1NxuuN59ipdBksRVSvz0KInbPnp4IfoXJXCqiDA== dependencies: "@babel/runtime" "^7.5.5" hoist-non-react-statics "^3.3.0" - invariant "^2.2.4" loose-envify "^1.4.0" prop-types "^15.7.2" react-is "^16.9.0" @@ -9920,19 +10230,20 @@ react-scripts@3.2.0: fsevents "2.0.7" react-spinners-kit@^1.9.0: - version "1.9.0" - resolved "https://registry.yarnpkg.com/react-spinners-kit/-/react-spinners-kit-1.9.0.tgz#66d55530268f8b5d53816d8fdf90fa7fe04115ef" - integrity sha512-0O38Pq+PIUHayxeujtsuloLwI+mhmkA1N2z7Kk5p03aY8ntGQuGIQYqtlAs+GHVTnL9JwlPQ4mqBGNu8sY0KuQ== + version "1.9.1" + resolved "https://registry.yarnpkg.com/react-spinners-kit/-/react-spinners-kit-1.9.1.tgz#516a7de8e80702def006be481062382ab3c38066" + integrity sha512-QtAvSD7b1WkThY3pRKu6Sr+DZafnEufoOvug/uHprkKyZK6bg6TG5LC3Sy3JaRh6A/HACIcTNEWG+Ls0YDoSHg== dependencies: polished "^1.9.3" prop-types "^15.6.2" - react "^16.5.2" - react-dom "^16.5.1" + react "^16.12.0" + react-dom "^16.12.0" + styled-components "^4.4.1" -react@^16.10.2, react@^16.5.2: - version "16.10.2" - resolved "https://registry.yarnpkg.com/react/-/react-16.10.2.tgz#a5ede5cdd5c536f745173c8da47bda64797a4cf0" - integrity sha512-MFVIq0DpIhrHFyqLU0S3+4dIcBhhOvBE8bJ/5kHPVOVaGdo0KuiQzpcjCPsf585WvhypqtrMILyoE2th6dT+Lw== +react@^16.10.2, react@^16.12.0: + version "16.13.1" + resolved "https://registry.yarnpkg.com/react/-/react-16.13.1.tgz#2e818822f1a9743122c063d6410d85c1e3afe48e" + integrity sha512-YMZQQq32xHLX0bz5Mnibv1/LHb3Sqzngu7xstSM+vrkE5Kzr9xE0yMByK5kMoTK30YVJE61WfbxIFFvfeDKT1w== dependencies: loose-envify "^1.1.0" object-assign "^4.1.1" @@ -9990,9 +10301,9 @@ read-pkg@^3.0.0: path-type "^3.0.0" "readable-stream@1 || 2", readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.6, readable-stream@^2.1.5, readable-stream@^2.2.2, readable-stream@^2.3.3, readable-stream@^2.3.6, readable-stream@~2.3.6: - version "2.3.6" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.6.tgz#b11c27d88b8ff1fbe070643cf94b0c79ae1b0aaf" - integrity sha512-tQtKA9WIAhBF3+VLAseyMqZeBjW0AHJoxOtYqSUZNJxauErmLbVm2FW1y+J/YA9dUrAC39ITejlZWhVIwawkKw== + version "2.3.7" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.7.tgz#1eca1cf711aef814c04f62252a36a62f6cb23b57" + integrity sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw== dependencies: core-util-is "~1.0.0" inherits "~2.0.3" @@ -10002,10 +10313,10 @@ read-pkg@^3.0.0: string_decoder "~1.1.1" util-deprecate "~1.0.1" -"readable-stream@2 || 3", readable-stream@^3.0.2, readable-stream@^3.0.6, readable-stream@^3.1.1, readable-stream@^3.4.0: - version "3.4.0" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-3.4.0.tgz#a51c26754658e0a3c21dbf59163bd45ba6f447fc" - integrity sha512-jItXPLmrSR8jmTRmRWJXCnGJsfy85mB3Wd/uINMXA65yrnFo0cPClFIUWzo2najVNSl+mx7/4W8ttlLWJe99pQ== +"readable-stream@2 || 3", readable-stream@^3.0.2, readable-stream@^3.0.6, readable-stream@^3.1.1, readable-stream@^3.4.0, readable-stream@^3.6.0: + version "3.6.0" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-3.6.0.tgz#337bbda3adc0706bd3e024426a286d4b4b2c9198" + integrity sha512-BViHy7LKeTz4oNnkcLJ+lVSL6vpiFeX6/d3oSH8zCW7UxP2onchk+vTGB143xuFjHS3deTgkKoXXymXqymiIdA== dependencies: inherits "^2.0.3" string_decoder "^1.1.1" @@ -10020,6 +10331,13 @@ readdirp@^2.2.1: micromatch "^3.1.10" readable-stream "^2.0.2" +readdirp@~3.4.0: + version "3.4.0" + resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-3.4.0.tgz#9fdccdf9e9155805449221ac645e8303ab5b9ada" + integrity sha512-0xe001vZBnJEK+uKcj8qOhyAKPzIT+gStxWr3LCB0DwcXR5NZJ3IaC+yGnHCYzB/S7ov3m3EEbZI2zeNvX+hGQ== + dependencies: + picomatch "^2.2.1" + realpath-native@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/realpath-native/-/realpath-native-1.1.0.tgz#2003294fea23fb0672f2476ebe22fcf498a2d65c" @@ -10065,9 +10383,9 @@ redux-thunk@^2.3.0: integrity sha512-km6dclyFnmcvxhAcrQV2AkZmPQjzPDjgVlQtR0EQjxZPyJ0BnMf3in1ryuR8A2qU0HldVRfxYXbFSKlI3N7Slw== redux@^4.0.0, redux@^4.0.4: - version "4.0.4" - resolved "https://registry.yarnpkg.com/redux/-/redux-4.0.4.tgz#4ee1aeb164b63d6a1bcc57ae4aa0b6e6fa7a3796" - integrity sha512-vKv4WdiJxOWKxK0yRoaK3Y4pxxB0ilzVx6dszU2W8wLxlb2yikRph4iV/ymtdJ6ZxpBLFbyrxklnT5yBbQSl3Q== + version "4.0.5" + resolved "https://registry.yarnpkg.com/redux/-/redux-4.0.5.tgz#4db5de5816e17891de8a80c424232d06f051d93f" + integrity sha512-VSz1uMAH24DM6MF72vcojpYPtrTUu3ByVWfPL1nPfVRb5mZVTve5GnNCUV53QM/BZ66xfWrm0CTWoM+Xlz8V1w== dependencies: loose-envify "^1.4.0" symbol-observable "^1.2.0" @@ -10077,10 +10395,10 @@ reflect.ownkeys@^0.2.0: resolved "https://registry.yarnpkg.com/reflect.ownkeys/-/reflect.ownkeys-0.2.0.tgz#749aceec7f3fdf8b63f927a04809e90c5c0b3460" integrity sha1-dJrO7H8/34tj+SegSAnpDFwLNGA= -regenerate-unicode-properties@^8.1.0: - version "8.1.0" - resolved "https://registry.yarnpkg.com/regenerate-unicode-properties/-/regenerate-unicode-properties-8.1.0.tgz#ef51e0f0ea4ad424b77bf7cb41f3e015c70a3f0e" - integrity sha512-LGZzkgtLY79GeXLm8Dp0BVLdQlWICzBnJz/ipWUgo59qBaZ+BHtq51P2q1uVZlppMuUAT37SDk39qUbjTWB7bA== +regenerate-unicode-properties@^8.2.0: + version "8.2.0" + resolved "https://registry.yarnpkg.com/regenerate-unicode-properties/-/regenerate-unicode-properties-8.2.0.tgz#e5de7111d655e7ba60c057dbe9ff37c87e65cdec" + integrity sha512-F9DjY1vKLo/tPePDycuH3dn9H1OTPIkVD9Kz4LODu+F2C75mgjAJ7x/gwy6ZcSNRAAkhNlJSOHRe8k3p+K9WhA== dependencies: regenerate "^1.4.0" @@ -10089,22 +10407,23 @@ regenerate@^1.4.0: resolved "https://registry.yarnpkg.com/regenerate/-/regenerate-1.4.0.tgz#4a856ec4b56e4077c557589cae85e7a4c8869a11" integrity sha512-1G6jJVDWrt0rK99kBjvEtziZNCICAuvIPkSiUFIQxVP06RCVpq3dmDo2oi6ABpYaDYaTRr67BEhL8r1wgEZZKg== -regenerator-runtime@0.13.3, regenerator-runtime@^0.13.2: - version "0.13.3" - resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.3.tgz#7cf6a77d8f5c6f60eb73c5fc1955b2ceb01e6bf5" - integrity sha512-naKIZz2GQ8JWh///G7L3X6LaQUAMp2lvb1rvwwsURe/VXwD6VMfr+/1NuNw3ag8v2kY1aQ/go5SNn79O9JU7yw== - regenerator-runtime@^0.11.0: version "0.11.1" resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz#be05ad7f9bf7d22e056f9726cee5017fbf19e2e9" integrity sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg== -regenerator-transform@^0.14.0: - version "0.14.1" - resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.14.1.tgz#3b2fce4e1ab7732c08f665dfdb314749c7ddd2fb" - integrity sha512-flVuee02C3FKRISbxhXl9mGzdbWUVHubl1SMaknjxkFB1/iqpJhArQUvRxOOPEc/9tAiX0BaQ28FJH10E4isSQ== +regenerator-runtime@^0.13.3, regenerator-runtime@^0.13.4: + version "0.13.5" + resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.5.tgz#d878a1d094b4306d10b9096484b33ebd55e26697" + integrity sha512-ZS5w8CpKFinUzOwW3c83oPeVXoNsrLsaCoLtJvAClH135j/R77RuymhiSErhm2lKcwSCIpmvIWSbDkIfAqKQlA== + +regenerator-transform@^0.14.2: + version "0.14.4" + resolved "https://registry.yarnpkg.com/regenerator-transform/-/regenerator-transform-0.14.4.tgz#5266857896518d1616a78a0479337a30ea974cc7" + integrity sha512-EaJaKPBI9GvKpvUz2mz4fhx7WPgvwRLY9v3hlNHWmAuJHI13T4nwKnNvm5RWJzEdnI5g5UwtOww+S8IdoUC2bw== dependencies: - private "^0.1.6" + "@babel/runtime" "^7.8.4" + private "^0.1.8" regex-not@^1.0.0, regex-not@^1.0.2: version "1.0.2" @@ -10120,28 +10439,34 @@ regex-parser@2.2.10: integrity sha512-8t6074A68gHfU8Neftl0Le6KTDwfGAj7IyjPIMSfikI2wJUTHDMaIq42bUsfVnj8mhx0R+45rdUXHGpN164avA== regexp.prototype.flags@^1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/regexp.prototype.flags/-/regexp.prototype.flags-1.2.0.tgz#6b30724e306a27833eeb171b66ac8890ba37e41c" - integrity sha512-ztaw4M1VqgMwl9HlPpOuiYgItcHlunW0He2fE6eNfT6E/CF2FtYi9ofOYe4mKntstYk0Fyh/rDRBdS3AnxjlrA== + version "1.3.0" + resolved "https://registry.yarnpkg.com/regexp.prototype.flags/-/regexp.prototype.flags-1.3.0.tgz#7aba89b3c13a64509dabcf3ca8d9fbb9bdf5cb75" + integrity sha512-2+Q0C5g951OlYlJz6yu5/M33IcsESLlLfsyIaLJaG4FA2r4yP8MvVMJUUP/fVBkSpbbbZlS5gynbEWLipiiXiQ== dependencies: - define-properties "^1.1.2" + define-properties "^1.1.3" + es-abstract "^1.17.0-next.1" regexpp@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-2.0.1.tgz#8d19d31cf632482b589049f8281f93dbcba4d07f" integrity sha512-lv0M6+TkDVniA3aD1Eg0DVpfU/booSu7Eev3TDO/mZKHBfVjgCGTV4t4buppESEYDtkArYFOxTJWv6S5C+iaNw== -regexpu-core@^4.6.0: - version "4.6.0" - resolved "https://registry.yarnpkg.com/regexpu-core/-/regexpu-core-4.6.0.tgz#2037c18b327cfce8a6fea2a4ec441f2432afb8b6" - integrity sha512-YlVaefl8P5BnFYOITTNzDvan1ulLOiXJzCNZxduTIosN17b87h3bvG9yHMoHaRuo88H4mQ06Aodj5VtYGGGiTg== +regexpp@^3.0.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/regexpp/-/regexpp-3.1.0.tgz#206d0ad0a5648cffbdb8ae46438f3dc51c9f78e2" + integrity sha512-ZOIzd8yVsQQA7j8GCSlPGXwg5PfmA1mrq0JP4nGhh54LaKN3xdai/vHUDu74pKwV8OxseMS65u2NImosQcSD0Q== + +regexpu-core@^4.7.0: + version "4.7.0" + resolved "https://registry.yarnpkg.com/regexpu-core/-/regexpu-core-4.7.0.tgz#fcbf458c50431b0bb7b45d6967b8192d91f3d938" + integrity sha512-TQ4KXRnIn6tz6tjnrXEkD/sshygKH/j5KzK86X8MkeHyZ8qst/LZ89j3X4/8HEIfHANTFIP/AbXakeRhWIl5YQ== dependencies: regenerate "^1.4.0" - regenerate-unicode-properties "^8.1.0" - regjsgen "^0.5.0" - regjsparser "^0.6.0" + regenerate-unicode-properties "^8.2.0" + regjsgen "^0.5.1" + regjsparser "^0.6.4" unicode-match-property-ecmascript "^1.0.4" - unicode-match-property-value-ecmascript "^1.1.0" + unicode-match-property-value-ecmascript "^1.2.0" registry-auth-token@^3.0.1: version "3.4.0" @@ -10158,15 +10483,15 @@ registry-url@^3.0.3: dependencies: rc "^1.0.1" -regjsgen@^0.5.0: - version "0.5.0" - resolved "https://registry.yarnpkg.com/regjsgen/-/regjsgen-0.5.0.tgz#a7634dc08f89209c2049adda3525711fb97265dd" - integrity sha512-RnIrLhrXCX5ow/E5/Mh2O4e/oa1/jW0eaBKTSy3LaCj+M3Bqvm97GWDp2yUtzIs4LEn65zR2yiYGFqb2ApnzDA== +regjsgen@^0.5.1: + version "0.5.2" + resolved "https://registry.yarnpkg.com/regjsgen/-/regjsgen-0.5.2.tgz#92ff295fb1deecbf6ecdab2543d207e91aa33733" + integrity sha512-OFFT3MfrH90xIW8OOSyUrk6QHD5E9JOTeGodiJeBS3J6IwlgzJMNE/1bZklWz5oTg+9dCMyEetclvCVXOPoN3A== -regjsparser@^0.6.0: - version "0.6.0" - resolved "https://registry.yarnpkg.com/regjsparser/-/regjsparser-0.6.0.tgz#f1e6ae8b7da2bae96c99399b868cd6c933a2ba9c" - integrity sha512-RQ7YyokLiQBomUJuUG8iGVvkgOLxwyZM8k6d3q5SAXpg4r5TZJZigKFvC6PpD+qQ98bCDC5YelPeA3EucDoNeQ== +regjsparser@^0.6.4: + version "0.6.4" + resolved "https://registry.yarnpkg.com/regjsparser/-/regjsparser-0.6.4.tgz#a769f8684308401a66e9b529d2436ff4d0666272" + integrity sha512-64O87/dPDgfk8/RQqC4gkZoGyyWFIEUTTh80CU6CWuK5vkCGyekIx+oKcEIYtP/RAxSQltCZHCNu/mdd7fqlJw== dependencies: jsesc "~0.5.0" @@ -10208,26 +10533,26 @@ repeating@^2.0.0: dependencies: is-finite "^1.0.0" -request-promise-core@1.1.2: - version "1.1.2" - resolved "https://registry.yarnpkg.com/request-promise-core/-/request-promise-core-1.1.2.tgz#339f6aababcafdb31c799ff158700336301d3346" - integrity sha512-UHYyq1MO8GsefGEt7EprS8UrXsm1TxEvFUX1IMTuSLU2Rh7fTIdFtl8xD7JiEYiWU2dl+NYAjCTksTehQUxPag== +request-promise-core@1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/request-promise-core/-/request-promise-core-1.1.3.tgz#e9a3c081b51380dfea677336061fea879a829ee9" + integrity sha512-QIs2+ArIGQVp5ZYbWD5ZLCY29D5CfWizP8eWnm8FoGD1TX61veauETVQbrV60662V0oFBkrDOuaBI8XgtuyYAQ== dependencies: - lodash "^4.17.11" + lodash "^4.17.15" request-promise-native@^1.0.5: - version "1.0.7" - resolved "https://registry.yarnpkg.com/request-promise-native/-/request-promise-native-1.0.7.tgz#a49868a624bdea5069f1251d0a836e0d89aa2c59" - integrity sha512-rIMnbBdgNViL37nZ1b3L/VfPOpSi0TqVDQPAvO6U14lMzOLrt5nilxCQqtDKhZeDiW0/hkCXGoQjhgJd/tCh6w== + version "1.0.8" + resolved "https://registry.yarnpkg.com/request-promise-native/-/request-promise-native-1.0.8.tgz#a455b960b826e44e2bf8999af64dff2bfe58cb36" + integrity sha512-dapwLGqkHtwL5AEbfenuzjTYg35Jd6KPytsC2/TLkVMz8rm+tNt72MGUWT1RP/aYawMpN6HqbNGBQaRcBtjQMQ== dependencies: - request-promise-core "1.1.2" + request-promise-core "1.1.3" stealthy-require "^1.1.1" tough-cookie "^2.3.3" request@^2.87.0, request@^2.88.0: - version "2.88.0" - resolved "https://registry.yarnpkg.com/request/-/request-2.88.0.tgz#9c2fca4f7d35b592efe57c7f0a55e81052124fef" - integrity sha512-NAqBSrijGLZdM0WZNsInLJpkJokL72XYjUpnB0iwsRgxh7dB6COrHnTBNwN0E+lHDAJzu7kLAkDeY08z2/A0hg== + version "2.88.2" + resolved "https://registry.yarnpkg.com/request/-/request-2.88.2.tgz#d73c918731cb5a87da047e207234146f664d12b3" + integrity sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw== dependencies: aws-sign2 "~0.7.0" aws4 "^1.8.0" @@ -10236,7 +10561,7 @@ request@^2.87.0, request@^2.88.0: extend "~3.0.2" forever-agent "~0.6.1" form-data "~2.3.2" - har-validator "~5.1.0" + har-validator "~5.1.3" http-signature "~1.2.0" is-typedarray "~1.0.0" isstream "~0.1.2" @@ -10246,7 +10571,7 @@ request@^2.87.0, request@^2.88.0: performance-now "^2.1.0" qs "~6.5.2" safe-buffer "^5.1.2" - tough-cookie "~2.4.3" + tough-cookie "~2.5.0" tunnel-agent "^0.6.0" uuid "^3.3.2" @@ -10321,13 +10646,20 @@ resolve@1.1.7: resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.1.7.tgz#203114d82ad2c5ed9e8e0411b3932875e889e97b" integrity sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs= -resolve@1.12.0, resolve@1.x, resolve@^1.10.0, resolve@^1.10.1, resolve@^1.11.0, resolve@^1.12.0, resolve@^1.3.2, resolve@^1.5.0, resolve@^1.8.1: +resolve@1.12.0: version "1.12.0" resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.12.0.tgz#3fc644a35c84a48554609ff26ec52b66fa577df6" integrity sha512-B/dOmuoAik5bKcD6s6nXDCjzUKnaDvdkRyAk6rsmsKLipWj4797iothd7jmmUhWTfinVMU+wc56rYKsit2Qy4w== dependencies: path-parse "^1.0.6" +resolve@1.x, resolve@^1.10.0, resolve@^1.10.1, resolve@^1.11.0, resolve@^1.12.0, resolve@^1.13.1, resolve@^1.3.2, resolve@^1.8.1: + version "1.17.0" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.17.0.tgz#b25941b54968231cc2d1bb76a79cb7f2c0bf8444" + integrity sha512-ic+7JYiV8Vi2yzQGFWOkiZD5Z9z7O2Zhm9XMaTxdJExKasieFCr+yXZ/WmXsckHiKl12ar0y6XiXDx3m4RHn1w== + dependencies: + path-parse "^1.0.6" + response-time@^2.3.2: version "2.3.2" resolved "https://registry.yarnpkg.com/response-time/-/response-time-2.3.2.tgz#ffa71bab952d62f7c1d49b7434355fbc68dffc5a" @@ -10344,6 +10676,14 @@ restore-cursor@^2.0.0: onetime "^2.0.0" signal-exit "^3.0.2" +restore-cursor@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/restore-cursor/-/restore-cursor-3.1.0.tgz#39f67c54b3a7a58cea5236d95cf0034239631f7e" + integrity sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA== + dependencies: + onetime "^5.1.0" + signal-exit "^3.0.2" + ret@~0.1.10: version "0.1.15" resolved "https://registry.yarnpkg.com/ret/-/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc" @@ -10407,12 +10747,10 @@ rsvp@^4.8.4: resolved "https://registry.yarnpkg.com/rsvp/-/rsvp-4.8.5.tgz#c8f155311d167f68f21e168df71ec5b083113734" integrity sha512-nfMOlASu9OnRJo1mbEk2cz0D56a1MBNrJ7orjRZQG10XDyuvwksKbuXNp6qa+kbn839HwjwhBzhFmdsaEAfauA== -run-async@^2.2.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.3.0.tgz#0371ab4ae0bdd720d4166d7dfda64ff7a445a6c0" - integrity sha1-A3GrSuC91yDUFm19/aZP96RFpsA= - dependencies: - is-promise "^2.1.0" +run-async@^2.2.0, run-async@^2.4.0: + version "2.4.1" + resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.4.1.tgz#8440eccf99ea3e70bd409d49aab88e10c189a455" + integrity sha512-tvVnVv01b8c1RrA6Ep7JkStj85Guv/YrMcwqYQnwjsAS2cTmmPGBBjAjpCW7RrSodNSoE2/qg9O4bceNvUuDgQ== run-queue@^1.0.0, run-queue@^1.0.3: version "1.0.3" @@ -10427,9 +10765,9 @@ rx@^4.1.0: integrity sha1-pfE/957zt0D+MKqAP7CfmIBdR4I= rxjs@^6.4.0, rxjs@^6.5.3: - version "6.5.3" - resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.5.3.tgz#510e26317f4db91a7eb1de77d9dd9ba0a4899a3a" - integrity sha512-wuYsAYYFdWTAnAaPoKGNhfpWwKZbJW+HgAJ+mImp+Epl7BG8oNWBCTyRM8gba9k4lk8BgWdoYm21Mo/RYhhbgA== + version "6.5.5" + resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.5.5.tgz#c5c884e3094c8cfee31bf27eb87e54ccfc87f9ec" + integrity sha512-WfQI+1gohdf0Dai/Bbmk5L5ItH5tYqm3ki2c5GdWhKjalzjg93N3avFjVStyZZz+A2Em+ZxKH5bNghw9UeylGQ== dependencies: tslib "^1.9.0" @@ -10438,10 +10776,10 @@ safe-buffer@5.1.2, safe-buffer@~5.1.0, safe-buffer@~5.1.1: resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== -safe-buffer@>=5.1.0, safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@^5.1.1, safe-buffer@^5.1.2, safe-buffer@~5.2.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.0.tgz#b74daec49b1148f88c64b68d49b1e815c1f2f519" - integrity sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg== +safe-buffer@>=5.1.0, safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@^5.1.1, safe-buffer@^5.1.2, safe-buffer@^5.2.0, safe-buffer@~5.2.0: + version "5.2.1" + resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" + integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== safe-regex@^1.1.0: version "1.1.0" @@ -10471,30 +10809,30 @@ sane@^4.0.3: walker "~1.0.5" sanitize-html@^1.20.1: - version "1.20.1" - resolved "https://registry.yarnpkg.com/sanitize-html/-/sanitize-html-1.20.1.tgz#f6effdf55dd398807171215a62bfc21811bacf85" - integrity sha512-txnH8TQjaQvg2Q0HY06G6CDJLVYCpbnxrdO0WN8gjCKaU5J0KbyGYhZxx5QJg3WLZ1lB7XU9kDkfrCXUozqptA== + version "1.24.0" + resolved "https://registry.yarnpkg.com/sanitize-html/-/sanitize-html-1.24.0.tgz#9cd42f236512bfcf6259424e958551148c165a7f" + integrity sha512-TAIFx39V/y06jDd4YUz7ntCdMUXN5Z28pSG7sTP2BCLXwHA9+ermacDpQs35Evo4p6YSgmaPdSbGiX4Fgptuuw== dependencies: chalk "^2.4.1" - htmlparser2 "^3.10.0" + htmlparser2 "^4.1.0" lodash.clonedeep "^4.5.0" lodash.escaperegexp "^4.1.2" lodash.isplainobject "^4.0.6" lodash.isstring "^4.0.1" - lodash.mergewith "^4.6.1" - postcss "^7.0.5" - srcset "^1.0.0" + lodash.mergewith "^4.6.2" + postcss "^7.0.27" + srcset "^2.0.1" xtend "^4.0.1" -sass-graph@^2.2.4: - version "2.2.4" - resolved "https://registry.yarnpkg.com/sass-graph/-/sass-graph-2.2.4.tgz#13fbd63cd1caf0908b9fd93476ad43a51d1e0b49" - integrity sha1-E/vWPNHK8JCLn9k0dq1DpR0eC0k= +sass-graph@2.2.5: + version "2.2.5" + resolved "https://registry.yarnpkg.com/sass-graph/-/sass-graph-2.2.5.tgz#a981c87446b8319d96dce0671e487879bd24c2e8" + integrity sha512-VFWDAHOe6mRuT4mZRd4eKE+d8Uedrk6Xnh7Sh9b4NGufQLQjOrvf/MQoOdx+0s92L89FeyUUNfU597j/3uNpag== dependencies: glob "^7.0.0" lodash "^4.0.0" scss-tokenizer "^0.2.3" - yargs "^7.0.0" + yargs "^13.3.2" sass-loader@7.2.0: version "7.2.0" @@ -10519,10 +10857,10 @@ saxes@^3.1.9: dependencies: xmlchars "^2.1.1" -scheduler@^0.16.2: - version "0.16.2" - resolved "https://registry.yarnpkg.com/scheduler/-/scheduler-0.16.2.tgz#f74cd9d33eff6fc554edfb79864868e4819132c1" - integrity sha512-BqYVWqwz6s1wZMhjFvLfVR5WXP7ZY32M/wYPo04CcuPM7XZEbV2TBNW7Z0UkguPTl0dWMA59VbNXxK6q+pHItg== +scheduler@^0.19.1: + version "0.19.1" + resolved "https://registry.yarnpkg.com/scheduler/-/scheduler-0.19.1.tgz#4f3e2ed2c1a7d65681f4c854fa8c5a1ccb40f196" + integrity sha512-n/zwRWRYSUj0/3g/otKDRPMh6qv2SYMWNq85IEa8iZyAv8od9zDYpGSnpBEjNgcMNq6Scbu5KfIPxNF72R/2EA== dependencies: loose-envify "^1.1.0" object-assign "^4.1.1" @@ -10537,11 +10875,11 @@ schema-utils@^1.0.0: ajv-keywords "^3.1.0" schema-utils@^2.0.0, schema-utils@^2.0.1, schema-utils@^2.2.0: - version "2.4.1" - resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-2.4.1.tgz#e89ade5d056dc8bcaca377574bb4a9c4e1b8be56" - integrity sha512-RqYLpkPZX5Oc3fw/kHHHyP56fg5Y+XBpIpV8nCg0znIALfq3OH+Ea9Hfeac9BAMwG5IICltiZ0vxFvJQONfA5w== + version "2.6.6" + resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-2.6.6.tgz#299fe6bd4a3365dc23d99fd446caff8f1d6c330c" + integrity sha512-wHutF/WPSbIi9x6ctjGGk2Hvl0VOz5l3EKEuKbjPlB30mKZUzb9A5k9yEXRX3pwyqVLPvpfZZEllaFq/M718hA== dependencies: - ajv "^6.10.2" + ajv "^6.12.0" ajv-keywords "^3.4.1" scss-tokenizer@^0.2.3: @@ -10571,16 +10909,26 @@ semver-diff@^2.0.0: dependencies: semver "^5.0.3" -"semver@2 || 3 || 4 || 5", semver@^5.0.3, semver@^5.1.0, semver@^5.3.0, semver@^5.4.1, semver@^5.5, semver@^5.5.0, semver@^5.5.1, semver@^5.6.0: +"semver@2 || 3 || 4 || 5", semver@^5.0.3, semver@^5.1.0, semver@^5.4.1, semver@^5.5, semver@^5.5.0, semver@^5.5.1, semver@^5.6.0, semver@^5.7.1: version "5.7.1" resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.1.tgz#a954f931aeba508d307bbf069eff0c01c96116f7" integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== -semver@6.3.0, semver@^6.0.0, semver@^6.1.2, semver@^6.2.0, semver@^6.3.0: +semver@6.3.0, semver@^6.0.0, semver@^6.1.2, semver@^6.2.0: version "6.3.0" resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== +semver@7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.0.0.tgz#5f3ca35761e47e05b206c6daff2cf814f0316b8e" + integrity sha512-+GB6zVA9LWh6zovYQLALHwv5rb2PHGlJi3lfiqIHxR0uuwCgefcOJc59v9fv1w8GbStwxuuqqAjI9NMAOOgq1A== + +semver@^7.3.2: + version "7.3.2" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.3.2.tgz#604962b052b81ed0786aae84389ffba70ffd3938" + integrity sha512-OrOb32TeeambH6UrhtShmF7CRDqhL6/5XpPNp2DuRH6+9QLw/orhp72j87v8Qa1ScDkvrrBNpZcDejAirJmfXQ== + semver@~5.3.0: version "5.3.0" resolved "https://registry.yarnpkg.com/semver/-/semver-5.3.0.tgz#9b2ce5d3de02d17c6012ad326aa6b4d0cf54f94f" @@ -10610,6 +10958,11 @@ serialize-javascript@^1.7.0: resolved "https://registry.yarnpkg.com/serialize-javascript/-/serialize-javascript-1.9.1.tgz#cfc200aef77b600c47da9bb8149c943e798c2fdb" integrity sha512-0Vb/54WJ6k5v8sSWN09S0ora+Hnr+cX40r9F170nT+mSkaxltoE/7R3OrIdBSUv1OoiobH1QoWQbCnAO+e8J1A== +serialize-javascript@^2.1.2: + version "2.1.2" + resolved "https://registry.yarnpkg.com/serialize-javascript/-/serialize-javascript-2.1.2.tgz#ecec53b0e0317bdc95ef76ab7074b7384785fa61" + integrity sha512-rs9OggEUF0V4jUSecXazOYsLfu7OGK2qIn3c7IPBiffz32XniEp/TX9Xmc9LQfK2nQ2QKHvZ2oygKUGU0lG4jQ== + serve-index@^1.7.2: version "1.9.1" resolved "https://registry.yarnpkg.com/serve-index/-/serve-index-1.9.1.tgz#d3768d69b1e7d82e5ce050fff5b453bea12a9239" @@ -10711,9 +11064,9 @@ shellwords@^0.1.1: integrity sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww== signal-exit@^3.0.0, signal-exit@^3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d" - integrity sha1-tf3AjxKH6hF4Yo5BXiUTK3NkbG0= + version "3.0.3" + resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.3.tgz#a1410c2edd8f077b08b4e253c8eacfcaf057461c" + integrity sha512-VUJ49FC8U1OxwZLxIbTTrDvLnf/6TDgxZcK8wxR8zs13xpx7xbG60ndBlhNrFi2EMuFRoeDoJO7wthSLq42EjA== simple-swizzle@^0.2.2: version "0.2.2" @@ -10722,10 +11075,10 @@ simple-swizzle@^0.2.2: dependencies: is-arrayish "^0.3.1" -sisteransi@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/sisteransi/-/sisteransi-1.0.3.tgz#98168d62b79e3a5e758e27ae63c4a053d748f4eb" - integrity sha512-SbEG75TzH8G7eVXFSN5f9EExILKfly7SUvVY5DhhYLvfhKqhDFY0OzevWa/zwak0RLRfWS5AvfMWpd9gJvr5Yg== +sisteransi@^1.0.4: + version "1.0.5" + resolved "https://registry.yarnpkg.com/sisteransi/-/sisteransi-1.0.5.tgz#134d681297756437cc05ca01370d3a7a571075ed" + integrity sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg== slash@^1.0.0: version "1.0.0" @@ -10836,20 +11189,20 @@ source-list-map@^2.0.0: integrity sha512-qnQ7gVMxGNxsiL4lEuJwe/To8UnK7fAnmbGEEH8RpLouuKbeEm0lhbQVFIrNSuB+G7tVrAlVsZgETT5nljf+Iw== source-map-resolve@^0.5.0, source-map-resolve@^0.5.2: - version "0.5.2" - resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.2.tgz#72e2cc34095543e43b2c62b2c4c10d4a9054f259" - integrity sha512-MjqsvNwyz1s0k81Goz/9vRBe9SZdB09Bdw+/zYyO+3CuPk6fouTaxscHkgtE8jKvf01kVfl8riHzERQ/kefaSA== + version "0.5.3" + resolved "https://registry.yarnpkg.com/source-map-resolve/-/source-map-resolve-0.5.3.tgz#190866bece7553e1f8f267a2ee82c606b5509a1a" + integrity sha512-Htz+RnsXWk5+P2slx5Jh3Q66vhQj1Cllm0zvnaY98+NFx+Dv2CF/f5O/t8x+KaNdrdIAsruNzoh/KpialbqAnw== dependencies: - atob "^2.1.1" + atob "^2.1.2" decode-uri-component "^0.2.0" resolve-url "^0.2.1" source-map-url "^0.4.0" urix "^0.1.0" -source-map-support@^0.5.13, source-map-support@^0.5.6, source-map-support@~0.5.12: - version "0.5.13" - resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.13.tgz#31b24a9c2e73c2de85066c0feb7d44767ed52932" - integrity sha512-SHSKFHadjVA5oR4PPqhtAVdcBWwRYVd6g6cAXnIbRiIwc2EhPrTuKUBdSLvlEKyIP3GCf89fltvcZiP9MMFA1w== +source-map-support@^0.5.16, source-map-support@^0.5.17, source-map-support@^0.5.6, source-map-support@~0.5.12: + version "0.5.19" + resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.19.tgz#a98b62f86dcaf4f67399648c085291ab9e8fed61" + integrity sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw== dependencies: buffer-from "^1.0.0" source-map "^0.6.0" @@ -10871,38 +11224,38 @@ source-map@^0.4.2: dependencies: amdefine ">=0.0.4" -source-map@^0.5.0, source-map@^0.5.3, source-map@^0.5.6: +source-map@^0.5.0, source-map@^0.5.6: version "0.5.7" resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.5.7.tgz#8a039d2d1021d22d1ea14c80d8ea468ba2ef3fcc" integrity sha1-igOdLRAh0i0eoUyA2OpGi6LvP8w= -spawnd@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/spawnd/-/spawnd-4.0.0.tgz#b27ee6e7ec55c6ec232c05a21418cf35a77e0409" - integrity sha512-ql3qhJnhAkvXpaqKBWOqou1rUTSQhFRaZkyOT+MTFB4xY3X+brgw6LTWV2wHuE9A6YPhrNe1cbg7S+jAYnbC0Q== +spawnd@^4.4.0: + version "4.4.0" + resolved "https://registry.yarnpkg.com/spawnd/-/spawnd-4.4.0.tgz#bb52c5b34a22e3225ae1d3acb873b2cd58af0886" + integrity sha512-jLPOfB6QOEgMOQY15Z6+lwZEhH3F5ncXxIaZ7WHPIapwNNLyjrs61okj3VJ3K6tmP5TZ6cO0VAu9rEY4MD4YQg== dependencies: exit "^0.1.2" signal-exit "^3.0.2" - tree-kill "^1.2.1" - wait-port "^0.2.2" + tree-kill "^1.2.2" + wait-port "^0.2.7" spdx-correct@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.1.0.tgz#fb83e504445268f154b074e218c87c003cd31df4" - integrity sha512-lr2EZCctC2BNR7j7WzJ2FpDznxky1sjfxvvYEyzxNyb6lZXHODmEoJeFu4JupYlkfha1KZpJyoqiJ7pgA1qq8Q== + version "3.1.1" + resolved "https://registry.yarnpkg.com/spdx-correct/-/spdx-correct-3.1.1.tgz#dece81ac9c1e6713e5f7d1b6f17d468fa53d89a9" + integrity sha512-cOYcUWwhCuHCXi49RhFRCyJEK3iPj1Ziz9DpViV3tbZOwXD49QzIN3MpOLJNxh2qwq2lJJZaKMVw9qNi4jTC0w== dependencies: spdx-expression-parse "^3.0.0" spdx-license-ids "^3.0.0" spdx-exceptions@^2.1.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz#2ea450aee74f2a89bfb94519c07fcd6f41322977" - integrity sha512-2XQACfElKi9SlVb1CYadKDXvoajPgBVPn/gOQLrTvHdElaVhr7ZEbqJaRnJLVNeaI4cMEAgVCeBMKF6MWRDCRA== + version "2.3.0" + resolved "https://registry.yarnpkg.com/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz#3f28ce1a77a00372683eade4a433183527a2163d" + integrity sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A== spdx-expression-parse@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/spdx-expression-parse/-/spdx-expression-parse-3.0.0.tgz#99e119b7a5da00e05491c9fa338b7904823b41d0" - integrity sha512-Yg6D3XpRD4kkOmTpdgbUiEJFKghJH03fiC1OPll5h/0sO6neh2jqRDVHOQ4o/LMea0tgCkbMgea5ip/e+MkWyg== + version "3.0.1" + resolved "https://registry.yarnpkg.com/spdx-expression-parse/-/spdx-expression-parse-3.0.1.tgz#cf70f50482eefdc98e3ce0a6833e4a53ceeba679" + integrity sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q== dependencies: spdx-exceptions "^2.1.0" spdx-license-ids "^3.0.0" @@ -10925,9 +11278,9 @@ spdy-transport@^3.0.0: wbuf "^1.7.3" spdy@^4.0.0: - version "4.0.1" - resolved "https://registry.yarnpkg.com/spdy/-/spdy-4.0.1.tgz#6f12ed1c5db7ea4f24ebb8b89ba58c87c08257f2" - integrity sha512-HeZS3PBdMA+sZSu0qwpCxl3DeALD5ASx8pAX0jZdKXSpPWbQ6SYGnlg3BBmYLx5LtiZrmkAZfErCm2oECBcioA== + version "4.0.2" + resolved "https://registry.yarnpkg.com/spdy/-/spdy-4.0.2.tgz#b74f466203a3eda452c02492b91fb9e84a27677b" + integrity sha512-r46gZQZQV+Kl9oItvl1JZZqJKGr+oEkB08A6BzkiR7593/7IbtuncXHd2YoYeTsG4157ZssMu9KYvUHLcjcDoA== dependencies: debug "^4.1.0" handle-thing "^2.0.0" @@ -10947,13 +11300,10 @@ sprintf-js@~1.0.2: resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" integrity sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw= -srcset@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/srcset/-/srcset-1.0.0.tgz#a5669de12b42f3b1d5e83ed03c71046fc48f41ef" - integrity sha1-pWad4StC87HV6D7QPHEEb8SPQe8= - dependencies: - array-uniq "^1.0.2" - number-is-nan "^1.0.0" +srcset@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/srcset/-/srcset-2.0.1.tgz#8f842d357487eb797f413d9c309de7a5149df5ac" + integrity sha512-00kZI87TdRKwt+P8jj8UZxbfp7mK2ufxcIMWvhAOZNJTRROimpHeruWrGvCZneiuVDLqdyHefVp748ECTnyUBQ== sshpk@^1.7.0: version "1.16.1" @@ -11052,9 +11402,9 @@ stream-http@^2.7.2: xtend "^4.0.0" stream-shift@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/stream-shift/-/stream-shift-1.0.0.tgz#d5c752825e5367e786f78e18e445ea223a155952" - integrity sha1-1cdSgl5TZ+eG944Y5EXqIjoVWVI= + version "1.0.1" + resolved "https://registry.yarnpkg.com/stream-shift/-/stream-shift-1.0.1.tgz#d7088281559ab2778424279b0877da3c392d5a3d" + integrity sha512-AiisoFqQ0vbGcZgQPY1cdP2I76glaVA/RauYR4G4thNFgkTqr90yXTo4LYX60Jl+sIlPNHHdGSwo01AvbKUSVQ== strict-uri-encode@^1.0.0: version "1.1.0" @@ -11077,7 +11427,7 @@ string-length@^3.1.0: astral-regex "^1.0.0" strip-ansi "^5.2.0" -string-width@^1.0.1, string-width@^1.0.2: +string-width@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/string-width/-/string-width-1.0.2.tgz#118bdf5b8cdc51a2a7e70d211e07e2b0b9b107d3" integrity sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M= @@ -11103,21 +11453,48 @@ string-width@^3.0.0, string-width@^3.1.0: is-fullwidth-code-point "^2.0.0" strip-ansi "^5.1.0" -string.prototype.trimleft@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/string.prototype.trimleft/-/string.prototype.trimleft-2.1.0.tgz#6cc47f0d7eb8d62b0f3701611715a3954591d634" - integrity sha512-FJ6b7EgdKxxbDxc79cOlok6Afd++TTs5szo+zJTUyow3ycrRfJVE2pq3vcN53XexvKZu/DJMDfeI/qMiZTrjTw== +string-width@^4.1.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.0.tgz#952182c46cc7b2c313d1596e623992bd163b72b5" + integrity sha512-zUz5JD+tgqtuDjMhwIg5uFVV3dtqZ9yQJlZVfq4I01/K5Paj5UHj7VyrQOJvzawSVlKpObApbfD0Ed6yJc+1eg== dependencies: - define-properties "^1.1.3" - function-bind "^1.1.1" + emoji-regex "^8.0.0" + is-fullwidth-code-point "^3.0.0" + strip-ansi "^6.0.0" -string.prototype.trimright@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/string.prototype.trimright/-/string.prototype.trimright-2.1.0.tgz#669d164be9df9b6f7559fa8e89945b168a5a6c58" - integrity sha512-fXZTSV55dNBwv16uw+hh5jkghxSnc5oHq+5K/gXgizHwAvMetdAJlHqqoFC1FSDVPYWLkAKl2cxpUT41sV7nSg== +string.prototype.trimend@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/string.prototype.trimend/-/string.prototype.trimend-1.0.1.tgz#85812a6b847ac002270f5808146064c995fb6913" + integrity sha512-LRPxFUaTtpqYsTeNKaFOw3R4bxIzWOnbQ837QfBylo8jIxtcbK/A/sMV7Q+OAV/vWo+7s25pOE10KYSjaSO06g== dependencies: define-properties "^1.1.3" - function-bind "^1.1.1" + es-abstract "^1.17.5" + +string.prototype.trimleft@^2.1.1: + version "2.1.2" + resolved "https://registry.yarnpkg.com/string.prototype.trimleft/-/string.prototype.trimleft-2.1.2.tgz#4408aa2e5d6ddd0c9a80739b087fbc067c03b3cc" + integrity sha512-gCA0tza1JBvqr3bfAIFJGqfdRTyPae82+KTnm3coDXkZN9wnuW3HjGgN386D7hfv5CHQYCI022/rJPVlqXyHSw== + dependencies: + define-properties "^1.1.3" + es-abstract "^1.17.5" + string.prototype.trimstart "^1.0.0" + +string.prototype.trimright@^2.1.1: + version "2.1.2" + resolved "https://registry.yarnpkg.com/string.prototype.trimright/-/string.prototype.trimright-2.1.2.tgz#c76f1cef30f21bbad8afeb8db1511496cfb0f2a3" + integrity sha512-ZNRQ7sY3KroTaYjRS6EbNiiHrOkjihL9aQE/8gfQ4DtAC/aEBRHFJa44OmoWxGGqXuJlfKkZW4WcXErGr+9ZFg== + dependencies: + define-properties "^1.1.3" + es-abstract "^1.17.5" + string.prototype.trimend "^1.0.0" + +string.prototype.trimstart@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/string.prototype.trimstart/-/string.prototype.trimstart-1.0.1.tgz#14af6d9f34b053f7cfc89b72f8f2ee14b9039a54" + integrity sha512-XxZn+QpvrBI1FOcg6dIpxUPgWCPuNXvMD72aaRaUQv1eD4e/Qy8i/hFTe0BUmD60p/QA6bh1avmuPTfNjqVWRw== + dependencies: + define-properties "^1.1.3" + es-abstract "^1.17.5" string_decoder@^1.0.0, string_decoder@^1.1.1: version "1.3.0" @@ -11163,6 +11540,13 @@ strip-ansi@^4.0.0: dependencies: ansi-regex "^3.0.0" +strip-ansi@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.0.tgz#0b1571dd7669ccd4f3e06e14ef1eed26225ae532" + integrity sha512-AuvKTrTfQNYNIctbR1K/YGTR1756GycPsg7b9bdV9Duqur4gv6aKqHXah67Z8ImS7WEz5QVcOtlfW2rZEugt6w== + dependencies: + ansi-regex "^5.0.0" + strip-bom@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/strip-bom/-/strip-bom-2.0.0.tgz#6219a85616520491f35788bdbf1447a99c7e6b0e" @@ -11196,9 +11580,9 @@ strip-indent@^1.0.1: get-stdin "^4.0.1" strip-json-comments@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.0.1.tgz#85713975a91fb87bf1b305cca77395e40d2a64a7" - integrity sha512-VTyMAUfdm047mwKl+u79WIdrZxtFtn+nBxHeb844XBQ9uMNTuTHdx2hc5RiAJYqwTj3wc/xe5HLSdJSkJ+WfZw== + version "3.1.0" + resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.0.tgz#7638d31422129ecf4457440009fba03f9f9ac180" + integrity sha512-e6/d0eBu7gHtdCqFt0xJr642LdToM5/cN4Qb9DbHjVx1CP5RyeM+zH7pbecEmDv/lBqb0QH+6Uqq75rxFPkM0w== strip-json-comments@~2.0.1: version "2.0.1" @@ -11218,10 +11602,10 @@ style-loader@1.0.0: loader-utils "^1.2.3" schema-utils "^2.0.1" -styled-components@^4.4.0: - version "4.4.0" - resolved "https://registry.yarnpkg.com/styled-components/-/styled-components-4.4.0.tgz#4e381e2dab831d0e6ea431c2840a96323e84e21b" - integrity sha512-xQ6vTI/0zNjZ1BBDRxyjvBddrxhQ3DxjeCdaLM1lSn5FDnkTOQgRkmWvcUiTajqc5nJqKVl+7sUioMqktD0+Zw== +styled-components@^4.4.0, styled-components@^4.4.1: + version "4.4.1" + resolved "https://registry.yarnpkg.com/styled-components/-/styled-components-4.4.1.tgz#e0631e889f01db67df4de576fedaca463f05c2f2" + integrity sha512-RNqj14kYzw++6Sr38n7197xG33ipEOktGElty4I70IKzQF1jzaD1U4xQ+Ny/i03UUhHlC5NWEO+d8olRCDji6g== dependencies: "@babel/helper-module-imports" "^7.0.0" "@babel/traverse" "^7.0.0" @@ -11261,7 +11645,7 @@ supports-color@^2.0.0: resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7" integrity sha1-U10EXOa2Nj+kARcIRimZXp3zJMc= -supports-color@^5.2.0, supports-color@^5.3.0, supports-color@^5.5.0: +supports-color@^5.3.0, supports-color@^5.5.0: version "5.5.0" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== @@ -11275,22 +11659,29 @@ supports-color@^6.1.0: dependencies: has-flag "^3.0.0" +supports-color@^7.1.0: + version "7.1.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.1.0.tgz#68e32591df73e25ad1c4b49108a2ec507962bfd1" + integrity sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g== + dependencies: + has-flag "^4.0.0" + svg-parser@^2.0.0: - version "2.0.2" - resolved "https://registry.yarnpkg.com/svg-parser/-/svg-parser-2.0.2.tgz#d134cc396fa2681dc64f518330784e98bd801ec8" - integrity sha512-1gtApepKFweigFZj3sGO8KT8LvVZK8io146EzXrpVuWCDAbISz/yMucco3hWTkpZNoPabM+dnMOpy6Swue68Zg== + version "2.0.4" + resolved "https://registry.yarnpkg.com/svg-parser/-/svg-parser-2.0.4.tgz#fdc2e29e13951736140b76cb122c8ee6630eb6b5" + integrity sha512-e4hG1hRwoOdRb37cIMSgzNsxyzKfayW6VOflrwvR+/bzrkyxY/31WkbgnQpgtrNp1SdpJvpUAGTa/ZoiPNDuRQ== svgo@^1.0.0, svgo@^1.2.2: - version "1.3.0" - resolved "https://registry.yarnpkg.com/svgo/-/svgo-1.3.0.tgz#bae51ba95ded9a33a36b7c46ce9c359ae9154313" - integrity sha512-MLfUA6O+qauLDbym+mMZgtXCGRfIxyQoeH6IKVcFslyODEe/ElJNwr0FohQ3xG4C6HK6bk3KYPPXwHVJk3V5NQ== + version "1.3.2" + resolved "https://registry.yarnpkg.com/svgo/-/svgo-1.3.2.tgz#b6dc511c063346c9e415b81e43401145b96d4167" + integrity sha512-yhy/sQYxR5BkC98CY7o31VGsg014AKLEPxdfhora76l36hD9Rdy5NZA/Ocn6yayNPgSamYdtX2rFJdcv07AYVw== dependencies: chalk "^2.4.1" coa "^2.0.2" css-select "^2.0.0" css-select-base-adapter "^0.1.1" - css-tree "1.0.0-alpha.33" - csso "^3.5.1" + css-tree "1.0.0-alpha.37" + csso "^4.0.2" js-yaml "^3.13.1" mkdirp "~0.5.1" object.values "^1.1.0" @@ -11333,19 +11724,6 @@ tar@^2.0.0: fstream "^1.0.12" inherits "2" -tar@^4: - version "4.4.13" - resolved "https://registry.yarnpkg.com/tar/-/tar-4.4.13.tgz#43b364bc52888d555298637b10d60790254ab525" - integrity sha512-w2VwSrBoHa5BsSyH+KxEqeQBAllHhccyMFVHtGtdMpF4W7IRWfZjFiQceJPChOeTsSDVUpER2T8FA93pr0L+QA== - dependencies: - chownr "^1.1.1" - fs-minipass "^1.2.5" - minipass "^2.8.6" - minizlib "^1.2.1" - mkdirp "^0.5.0" - safe-buffer "^5.1.2" - yallist "^3.0.3" - tdigest@^0.1.1: version "0.1.1" resolved "https://registry.yarnpkg.com/tdigest/-/tdigest-0.1.1.tgz#2e3cb2c39ea449e55d1e6cd91117accca4588021" @@ -11353,16 +11731,16 @@ tdigest@^0.1.1: dependencies: bintrees "1.0.1" -teeny-request@^5.2.1: - version "5.3.0" - resolved "https://registry.yarnpkg.com/teeny-request/-/teeny-request-5.3.0.tgz#c80287b5a51a7c25eef2347ff5467c95e07dac5a" - integrity sha512-sN9E3JvEBe2CFqB/jpJpw1erWD1C7MxyYCxogHFCQSyZfkHYcdf4wzVQSw7FZxbwcfnS+FP0W9BS0mp6SEOKjg== +teeny-request@^6.0.0: + version "6.0.3" + resolved "https://registry.yarnpkg.com/teeny-request/-/teeny-request-6.0.3.tgz#b617f9d5b7ba95c76a3f257f6ba2342b70228b1f" + integrity sha512-TZG/dfd2r6yeji19es1cUIwAlVD8y+/svB1kAC2Y0bjEyysrfbO8EZvJBRwIE6WkwmUoB7uvWLwTIhJbMXZ1Dw== dependencies: - http-proxy-agent "^2.1.0" - https-proxy-agent "^3.0.0" + http-proxy-agent "^4.0.0" + https-proxy-agent "^5.0.0" node-fetch "^2.2.0" stream-events "^1.0.5" - uuid "^3.3.2" + uuid "^7.0.0" term-size@^1.2.0: version "1.2.0" @@ -11371,7 +11749,7 @@ term-size@^1.2.0: dependencies: execa "^0.7.0" -terser-webpack-plugin@1.4.1, terser-webpack-plugin@^1.4.1: +terser-webpack-plugin@1.4.1: version "1.4.1" resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-1.4.1.tgz#61b18e40eaee5be97e771cdbb10ed1280888c2b4" integrity sha512-ZXmmfiwtCLfz8WKZyYUuuHf3dMYEjg8NrjHMb0JqHVHVOSkzp3cW2/XG1fP3tRhqEqSzMwzzRQGtAPbs4Cncxg== @@ -11386,10 +11764,25 @@ terser-webpack-plugin@1.4.1, terser-webpack-plugin@^1.4.1: webpack-sources "^1.4.0" worker-farm "^1.7.0" +terser-webpack-plugin@^1.4.1: + version "1.4.3" + resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-1.4.3.tgz#5ecaf2dbdc5fb99745fd06791f46fc9ddb1c9a7c" + integrity sha512-QMxecFz/gHQwteWwSo5nTc6UaICqN1bMedC5sMtUc7y3Ha3Q8y6ZO0iCR8pq4RJC8Hjf0FEPEHZqcMB/+DFCrA== + dependencies: + cacache "^12.0.2" + find-cache-dir "^2.1.0" + is-wsl "^1.1.0" + schema-utils "^1.0.0" + serialize-javascript "^2.1.2" + source-map "^0.6.1" + terser "^4.1.2" + webpack-sources "^1.4.0" + worker-farm "^1.7.0" + terser@^4.1.2: - version "4.3.8" - resolved "https://registry.yarnpkg.com/terser/-/terser-4.3.8.tgz#707f05f3f4c1c70c840e626addfdb1c158a17136" - integrity sha512-otmIRlRVmLChAWsnSFNO0Bfk6YySuBp6G9qrHiJwlLDd4mxe2ta4sjI7TzIR+W1nBMjilzrMcPOz9pSusgx3hQ== + version "4.7.0" + resolved "https://registry.yarnpkg.com/terser/-/terser-4.7.0.tgz#15852cf1a08e3256a80428e865a2fa893ffba006" + integrity sha512-Lfb0RiZcjRDXCC3OSHJpEkxJ9Qeqs6mp2v4jf2MHfy8vGERmVDuvjXdd/EnP5Deme5F2yBRBymKmKHCBg2echw== dependencies: commander "^2.20.0" source-map "~0.6.1" @@ -11441,9 +11834,9 @@ through@^2.3.6: integrity sha1-DdTJ/6q8NXlgsbckEV1+Doai4fU= thunky@^1.0.2: - version "1.0.3" - resolved "https://registry.yarnpkg.com/thunky/-/thunky-1.0.3.tgz#f5df732453407b09191dae73e2a8cc73f381a826" - integrity sha512-YwT8pjmNcAXBZqrubu22P4FYsh2D4dxRmnWBOL8Jk8bUcRUtc5326kx32tuTmFDAZtLOGEVNl8POAR8j896Iow== + version "1.1.0" + resolved "https://registry.yarnpkg.com/thunky/-/thunky-1.1.0.tgz#5abaf714a9405db0504732bbccd2cedd9ef9537d" + integrity sha512-eHY7nBftgThBqOyHGVN+l8gF0BucP09fMo0oO/Lb0w1OF80dJv+lDVpXG60WMQvkcxAkNybKsrEIE3ZtKGmPrA== timed-out@^4.0.0: version "4.0.1" @@ -11535,7 +11928,7 @@ touch@^3.1.0: dependencies: nopt "~1.0.10" -tough-cookie@^2.3.3, tough-cookie@^2.3.4, tough-cookie@^2.5.0: +tough-cookie@^2.3.3, tough-cookie@^2.3.4, tough-cookie@^2.5.0, tough-cookie@~2.5.0: version "2.5.0" resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.5.0.tgz#cd9fb2a0aa1d5a12b473bd9fb96fa3dcff65ade2" integrity sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g== @@ -11543,14 +11936,6 @@ tough-cookie@^2.3.3, tough-cookie@^2.3.4, tough-cookie@^2.5.0: psl "^1.1.28" punycode "^2.1.1" -tough-cookie@~2.4.3: - version "2.4.3" - resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.4.3.tgz#53f36da3f47783b0925afa06ff9f3b165280f781" - integrity sha512-Q5srk/4vDM54WJsJio3XNn6K2sCG+CQ8G5Wz6bZhRZoAe/+TxjWB/GlFAnYEbkYVlON9FMk/fE3h2RLpPXo4lQ== - dependencies: - psl "^1.1.24" - punycode "^1.4.1" - tr46@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/tr46/-/tr46-1.0.1.tgz#a8b13fd6bfd2489519674ccde55ba3693b706d09" @@ -11558,10 +11943,10 @@ tr46@^1.0.1: dependencies: punycode "^2.1.0" -tree-kill@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/tree-kill/-/tree-kill-1.2.1.tgz#5398f374e2f292b9dcc7b2e71e30a5c3bb6c743a" - integrity sha512-4hjqbObwlh2dLyW4tcz0Ymw0ggoaVDMveUB9w8kFSQScdRLo0gxO9J7WFcUBo+W3C1TLdFIEwNOWebgZZ0RH9Q== +tree-kill@^1.2.2: + version "1.2.2" + resolved "https://registry.yarnpkg.com/tree-kill/-/tree-kill-1.2.2.tgz#4ca09a9092c88b73a7cdc5e8a01b507b0790a0cc" + integrity sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A== trim-newlines@^1.0.0: version "1.0.0" @@ -11581,9 +11966,9 @@ triple-beam@^1.2.0, triple-beam@^1.3.0: glob "^7.1.2" ts-jest@^24.1.0: - version "24.1.0" - resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-24.1.0.tgz#2eaa813271a2987b7e6c3fefbda196301c131734" - integrity sha512-HEGfrIEAZKfu1pkaxB9au17b1d9b56YZSqz5eCVE8mX68+5reOvlM93xGOzzCREIov9mdH7JBG+s0UyNAqr0tQ== + version "24.3.0" + resolved "https://registry.yarnpkg.com/ts-jest/-/ts-jest-24.3.0.tgz#b97814e3eab359ea840a1ac112deae68aa440869" + integrity sha512-Hb94C/+QRIgjVZlJyiWwouYUF+siNJHJHknyspaOcZ+OQAIdFG/UrdQVXw/0B8Z3No34xkUXZJpOTy9alOWdVQ== dependencies: bs-logger "0.x" buffer-from "1.x" @@ -11597,21 +11982,26 @@ ts-jest@^24.1.0: yargs-parser "10.x" ts-node@^8.4.1: - version "8.4.1" - resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-8.4.1.tgz#270b0dba16e8723c9fa4f9b4775d3810fd994b4f" - integrity sha512-5LpRN+mTiCs7lI5EtbXmF/HfMeCjzt7DH9CZwtkr6SywStrNQC723wG+aOWFiLNn7zT3kD/RnFqi3ZUfr4l5Qw== + version "8.10.1" + resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-8.10.1.tgz#77da0366ff8afbe733596361d2df9a60fc9c9bd3" + integrity sha512-bdNz1L4ekHiJul6SHtZWs1ujEKERJnHs4HxN7rjTyyVOFf3HaJ6sLqe6aPG62XTzAB/63pKRh5jTSWL0D7bsvw== dependencies: arg "^4.1.0" diff "^4.0.1" make-error "^1.1.1" - source-map-support "^0.5.6" - yn "^3.0.0" + source-map-support "^0.5.17" + yn "3.1.1" -ts-pnp@1.1.4, ts-pnp@^1.1.2: +ts-pnp@1.1.4: version "1.1.4" resolved "https://registry.yarnpkg.com/ts-pnp/-/ts-pnp-1.1.4.tgz#ae27126960ebaefb874c6d7fa4729729ab200d90" integrity sha512-1J/vefLC+BWSo+qe8OnJQfWTYRS6ingxjwqmHMqaMxXMj7kFtKLgAaYW3JeX3mktjgUL+etlU8/B4VUAUI9QGw== +ts-pnp@^1.1.2: + version "1.2.0" + resolved "https://registry.yarnpkg.com/ts-pnp/-/ts-pnp-1.2.0.tgz#a500ad084b0798f1c3071af391e65912c86bca92" + integrity sha512-csd+vJOb/gkzvcCHgTGSChYpy5f1/XKNsmvBGO4JXS+z1v2HobugDz4s1IeFXM3wZB44uczs+eazB5Q/ccdhQw== + tsconfig-paths@^3.9.0: version "3.9.0" resolved "https://registry.yarnpkg.com/tsconfig-paths/-/tsconfig-paths-3.9.0.tgz#098547a6c4448807e8fcb8eae081064ee9a3c90b" @@ -11623,9 +12013,9 @@ tsconfig-paths@^3.9.0: strip-bom "^3.0.0" tslib@^1.8.1, tslib@^1.9.0: - version "1.10.0" - resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.10.0.tgz#c3c19f95973fb0a62973fb09d90d961ee43e5c8a" - integrity sha512-qOebF53frne81cf0S9B41ByenJ3/IuH8yJKngAX35CmiZySA0khhkovshKK+jGCaMnVomla7gVlIcc3EvKPbTQ== + version "1.13.0" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.13.0.tgz#c881e13cc7015894ed914862d276436fa9a47043" + integrity sha512-i/6DQjL8Xf3be4K/E6Wgpekn5Qasl1usyw++dAA35Ue5orEn65VIxOA+YvNNl9HV3qv70T7CNwjODHZrLwvd1Q== tsutils@^3.17.1: version "3.17.1" @@ -11658,10 +12048,15 @@ type-check@~0.3.2: dependencies: prelude-ls "~1.1.2" -type-fest@^0.5.2: - version "0.5.2" - resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.5.2.tgz#d6ef42a0356c6cd45f49485c3b6281fc148e48a2" - integrity sha512-DWkS49EQKVX//Tbupb9TFa19c7+MK1XmzkrZUR8TAktmE/DizXoaoJV6TZ/tSIPXipqNiRI6CyAe7x69Jb6RSw== +type-fest@^0.11.0: + version "0.11.0" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.11.0.tgz#97abf0872310fed88a5c466b25681576145e33f1" + integrity sha512-OdjXJxnCN1AvyLSzeKIgXTXxV+99ZuXl3Hpo9XpJAv9MBcHrrJOQ5kV7ypXOuQie+AmWG25hLbiKdwYTifzcfQ== + +type-fest@^0.8.1: + version "0.8.1" + resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.8.1.tgz#09e249ebde851d3b1e48d27c105444667f17b83d" + integrity sha512-4dbzIzqvjtgiM5rw1k5rEHtBANKmdudhGyBEajN01fEyhaAIhsoKNy6y7+IN93IfpFtwY9iqi7kD+xwKhQsNJA== type-is@~1.6.17, type-is@~1.6.18: version "1.6.18" @@ -11676,6 +12071,11 @@ type@^1.0.1: resolved "https://registry.yarnpkg.com/type/-/type-1.2.0.tgz#848dd7698dafa3e54a6c479e759c4bc3f18847a0" integrity sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg== +type@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/type/-/type-2.0.0.tgz#5f16ff6ef2eb44f260494dae271033b29c09a9c3" + integrity sha512-KBt58xCHry4Cejnc2ISQAF7QY+ORngsWfxezO68+12hKV6lQY8P/psIkcbjeHWn7MqcgciWJyCCevFMJdIXpow== + typedarray-to-buffer@^3.1.5: version "3.1.5" resolved "https://registry.yarnpkg.com/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz#a97ee7a9ff42691b9f783ff1bc5112fe3fca9080" @@ -11688,11 +12088,16 @@ typedarray@^0.0.6: resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c= -typescript@3.6.4, typescript@~3.6.3: +typescript@3.6.4: version "3.6.4" resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.6.4.tgz#b18752bb3792bc1a0281335f7f6ebf1bbfc5b91d" integrity sha512-unoCll1+l+YK4i4F8f22TaNVPRHcD9PA3yCuZ8g5e0qGqlVlJ/8FSateOLLSagn+Yg5+ZwuPkL8LFUc0Jcvksg== +typescript@~3.6.3: + version "3.6.5" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.6.5.tgz#dae20114a7b4ff4bd642db9c8c699f2953e8bbdb" + integrity sha512-BEjlc0Z06ORZKbtcxGrIvvwYs5hAnuo6TKdNFL55frVDlB+na3z5bsLhFaIxmT+dPWgBIjMo6aNnTOgHHmHgiQ== + uglify-js@3.4.x: version "3.4.10" resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.4.10.tgz#9ad9563d8eb3acdfb8d38597d2af1d815f6a755f" @@ -11701,18 +12106,10 @@ uglify-js@3.4.x: commander "~2.19.0" source-map "~0.6.1" -uglify-js@^3.1.4: - version "3.6.1" - resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.6.1.tgz#ae7688c50e1bdcf2f70a0e162410003cf9798311" - integrity sha512-+dSJLJpXBb6oMHP+Yvw8hUgElz4gLTh82XuX68QiJVTXaE5ibl6buzhNkQdYhBlIhozWOC9ge16wyRmjG4TwVQ== - dependencies: - commander "2.20.0" - source-map "~0.6.1" - undefsafe@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/undefsafe/-/undefsafe-2.0.2.tgz#225f6b9e0337663e0d8e7cfd686fc2836ccace76" - integrity sha1-Il9rngM3Zj4Njnz9aG/Cg2zKznY= + version "2.0.3" + resolved "https://registry.yarnpkg.com/undefsafe/-/undefsafe-2.0.3.tgz#6b166e7094ad46313b2202da7ecc2cd7cc6e7aae" + integrity sha512-nrXZwwXrD/T/JXeygJqdCO6NZZ1L66HrxM/Z7mIq2oPanoN0F1nLx3lwJMu6AwJY69hdixaFQOuoYsMjE5/C2A== dependencies: debug "^2.2.0" @@ -11729,15 +12126,15 @@ unicode-match-property-ecmascript@^1.0.4: unicode-canonical-property-names-ecmascript "^1.0.4" unicode-property-aliases-ecmascript "^1.0.4" -unicode-match-property-value-ecmascript@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-1.1.0.tgz#5b4b426e08d13a80365e0d657ac7a6c1ec46a277" - integrity sha512-hDTHvaBk3RmFzvSl0UVrUmC3PuW9wKVnpoUDYH0JDkSIovzw+J5viQmeYHxVSBptubnr7PbH2e0fnpDRQnQl5g== +unicode-match-property-value-ecmascript@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/unicode-match-property-value-ecmascript/-/unicode-match-property-value-ecmascript-1.2.0.tgz#0d91f600eeeb3096aa962b1d6fc88876e64ea531" + integrity sha512-wjuQHGQVofmSJv1uVISKLE5zO2rNGzM/KCYZch/QQvez7C1hUhBIuZ701fYXExuufJFMPhv2SyL8CyoIfMLbIQ== unicode-property-aliases-ecmascript@^1.0.4: - version "1.0.5" - resolved "https://registry.yarnpkg.com/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-1.0.5.tgz#a9cc6cc7ce63a0a3023fc99e341b94431d405a57" - integrity sha512-L5RAqCfXqAwR3RriF8pM0lU0w4Ryf/GgzONwi6KnL1taJQa7x1TCxdJnILX59WIGOwR57IVxn7Nej0fz1Ny6fw== + version "1.1.0" + resolved "https://registry.yarnpkg.com/unicode-property-aliases-ecmascript/-/unicode-property-aliases-ecmascript-1.1.0.tgz#dd57a99f6207bedff4628abefb94c50db941c8f4" + integrity sha512-PqSoPh/pWetQ2phoj5RLiaqIk4kCNwoV3CI+LfGmWLKI3rE3kl1h59XpX2BjgDrmbxD9ARtQobPGU1SguCYuQg== union-value@^1.0.0: version "1.0.1" @@ -11900,7 +12297,7 @@ util-deprecate@^1.0.1, util-deprecate@~1.0.1: resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" integrity sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8= -util.promisify@1.0.0, util.promisify@^1.0.0, util.promisify@~1.0.0: +util.promisify@1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/util.promisify/-/util.promisify-1.0.0.tgz#440f7165a459c9a16dc145eb8e72f35687097030" integrity sha512-i+6qA2MPhvoKLuxnJNpXAGhg7HphQOSUq2LKMZD0m15EiskXUkMvKdF4Uui0WYeCUGea+o2cw/ZuwehtfsrNkA== @@ -11908,6 +12305,16 @@ util.promisify@1.0.0, util.promisify@^1.0.0, util.promisify@~1.0.0: define-properties "^1.1.2" object.getownpropertydescriptors "^2.0.3" +util.promisify@^1.0.0, util.promisify@~1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/util.promisify/-/util.promisify-1.0.1.tgz#6baf7774b80eeb0f7520d8b81d07982a59abbaee" + integrity sha512-g9JpC/3He3bm38zsLupWryXHoEcS22YHthuPQSJdMy6KNrzIRzWqcsHzD/WUnqe45whVou4VIsPew37DoXWNrA== + dependencies: + define-properties "^1.1.3" + es-abstract "^1.17.2" + has-symbols "^1.0.1" + object.getownpropertydescriptors "^2.1.0" + util@0.10.3: version "0.10.3" resolved "https://registry.yarnpkg.com/util/-/util-0.10.3.tgz#7afb1afe50805246489e3db7fe0ed379336ac0f9" @@ -11933,9 +12340,14 @@ utils-merge@1.0.1: integrity sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM= uuid@^3.0.1, uuid@^3.3.2: - version "3.3.3" - resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.3.3.tgz#4568f0216e78760ee1dbf3a4d2cf53e224112866" - integrity sha512-pW0No1RGHgzlpHJO1nsVrHKpOEIxkGg1xB+v0ZmdNH5OAeAwzAVrCnI2/6Mtx+Uys6iaylxa+D3g4j63IKKjSQ== + version "3.4.0" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.4.0.tgz#b23e4358afa8a202fe7a100af1f5f883f02007ee" + integrity sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A== + +uuid@^7.0.0: + version "7.0.3" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-7.0.3.tgz#c5c9f2c8cf25dc0a372c4df1441c41f5bd0c680b" + integrity sha512-DPSke0pXhTZgoF/d+WSt2QaKMCFSfx7QegxEWT+JOuHF5aWrKEn0G+ztjuJg/gG8/ItK+rbPCD/yNv8yyih6Cg== v8-compile-cache@^2.0.3: version "2.1.0" @@ -11956,9 +12368,9 @@ vary@^1, vary@~1.1.2: integrity sha1-IpnwLG3tMNSllhsLn3RSShj2NPw= vendors@^1.0.0: - version "1.0.3" - resolved "https://registry.yarnpkg.com/vendors/-/vendors-1.0.3.tgz#a6467781abd366217c050f8202e7e50cc9eef8c0" - integrity sha512-fOi47nsJP5Wqefa43kyWSg80qF+Q3XA6MUkgi7Hp1HQaKDQW4cQrK2D0P7mmbFtsV1N89am55Yru/nyEwRubcw== + version "1.0.4" + resolved "https://registry.yarnpkg.com/vendors/-/vendors-1.0.4.tgz#e2b800a53e7a29b93506c3cf41100d16c4c4ad8e" + integrity sha512-/juG65kTL4Cy2su4P8HjtkTxk6VmJDiOPBufWniqQ6wknac6jNiXS9vU+hO3wgusiyqWlzTbVHi0dyJqRONg3w== verror@1.10.0: version "1.10.0" @@ -11970,16 +12382,16 @@ verror@1.10.0: extsprintf "^1.2.0" vm-browserify@^1.0.1: - version "1.1.0" - resolved "https://registry.yarnpkg.com/vm-browserify/-/vm-browserify-1.1.0.tgz#bd76d6a23323e2ca8ffa12028dc04559c75f9019" - integrity sha512-iq+S7vZJE60yejDYM0ek6zg308+UZsdtPExWP9VZoCFCz1zkJoXFnAX7aZfd/ZwrkidzdUZL0C/ryW+JwAiIGw== + version "1.1.2" + resolved "https://registry.yarnpkg.com/vm-browserify/-/vm-browserify-1.1.2.tgz#78641c488b8e6ca91a75f511e7a3b32a86e5dda0" + integrity sha512-2ham8XPWTONajOR0ohOKOHXkm3+gaBmGut3SRuu75xLd/RRaY6vqgh8NBYYk7+RW3u5AtzPQZG8F10LHkl0lAQ== w3c-hr-time@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/w3c-hr-time/-/w3c-hr-time-1.0.1.tgz#82ac2bff63d950ea9e3189a58a65625fedf19045" - integrity sha1-gqwr/2PZUOqeMYmlimViX+3xkEU= + version "1.0.2" + resolved "https://registry.yarnpkg.com/w3c-hr-time/-/w3c-hr-time-1.0.2.tgz#0a89cdf5cc15822df9c360543676963e0cc308cd" + integrity sha512-z8P5DvDNjKDoFIHK7q8r8lackT6l+jo/Ye3HOle7l9nICP9lf1Ci25fy9vHd0JOWewkIFzXIEig3TdKT7JQ5fQ== dependencies: - browser-process-hrtime "^0.1.2" + browser-process-hrtime "^1.0.0" w3c-xmlserializer@^1.1.2: version "1.1.2" @@ -12001,10 +12413,10 @@ wait-on@^3.3.0: request "^2.88.0" rx "^4.1.0" -wait-port@^0.2.2: - version "0.2.6" - resolved "https://registry.yarnpkg.com/wait-port/-/wait-port-0.2.6.tgz#261e615adb2e10c8b91c836722c85919ccf081cc" - integrity sha512-nXE5Yp0Zs1obhFVc0Da7WVJc3y0LxoCq3j4mtV0NdI5P/ZvRdKp5yhuojvMOcOxSwpQL1hGbOgMNQ+4wpRpwCA== +wait-port@^0.2.7: + version "0.2.7" + resolved "https://registry.yarnpkg.com/wait-port/-/wait-port-0.2.7.tgz#cdb4b78e662328099b187c7bb75fe0aa9cb6eb6c" + integrity sha512-pJ6cSBIa0w1sDg4y/wXN4bmvhM9OneOvwdFHo647L2NShBi/oXG4lRaLic5cO1HaYGbUhEvratPfl/WMlIC+tg== dependencies: chalk "^2.4.2" commander "^3.0.2" @@ -12017,14 +12429,23 @@ walker@^1.0.7, walker@~1.0.5: dependencies: makeerror "1.0.x" -watchpack@^1.6.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-1.6.0.tgz#4bc12c2ebe8aa277a71f1d3f14d685c7b446cd00" - integrity sha512-i6dHe3EyLjMmDlU1/bGQpEw25XSjkJULPuAVKCbNRefQVq48yXKUpwg538F7AZTf9kyr57zj++pQFltUa5H7yA== +watchpack-chokidar2@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/watchpack-chokidar2/-/watchpack-chokidar2-2.0.0.tgz#9948a1866cbbd6cb824dea13a7ed691f6c8ddff0" + integrity sha512-9TyfOyN/zLUbA288wZ8IsMZ+6cbzvsNyEzSBp6e/zkifi6xxbl8SmQ/CxQq32k8NNqrdVEVUVSEf56L4rQ/ZxA== + dependencies: + chokidar "^2.1.8" + +watchpack@^1.6.0: + version "1.7.2" + resolved "https://registry.yarnpkg.com/watchpack/-/watchpack-1.7.2.tgz#c02e4d4d49913c3e7e122c3325365af9d331e9aa" + integrity sha512-ymVbbQP40MFTp+cNMvpyBpBtygHnPzPkHqoIwRRj/0B8KhqQwV8LaKjtbaxF2lK4vl8zN9wCxS46IFCU5K4W0g== dependencies: - chokidar "^2.0.2" graceful-fs "^4.1.2" neo-async "^2.5.0" + optionalDependencies: + chokidar "^3.4.0" + watchpack-chokidar2 "^2.0.0" wbuf@^1.1.0, wbuf@^1.7.3: version "1.7.3" @@ -12141,11 +12562,11 @@ webpack@4.41.0: webpack-sources "^1.4.1" websocket-driver@>=0.5.1: - version "0.7.3" - resolved "https://registry.yarnpkg.com/websocket-driver/-/websocket-driver-0.7.3.tgz#a2d4e0d4f4f116f1e6297eba58b05d430100e9f9" - integrity sha512-bpxWlvbbB459Mlipc5GBzzZwhoZgGEZLuqPaR0INBGnPAY1vdBX6hPnoFXiw+3yWxDuHyQjO2oXTMyS8A5haFg== + version "0.7.4" + resolved "https://registry.yarnpkg.com/websocket-driver/-/websocket-driver-0.7.4.tgz#89ad5295bbf64b480abcba31e4953aca706f5760" + integrity sha512-b17KeDIQVjvb0ssuSDF2cYXSg2iztliJ4B9WdsuB6J952qCPKmnVq4DyW5motImXHDC1cBT/1UezrJVsKw5zjg== dependencies: - http-parser-js ">=0.4.0 <0.4.11" + http-parser-js ">=0.5.1" safe-buffer ">=5.1.0" websocket-extensions ">=0.1.1" @@ -12161,7 +12582,7 @@ whatwg-encoding@^1.0.1, whatwg-encoding@^1.0.3, whatwg-encoding@^1.0.5: dependencies: iconv-lite "0.4.24" -whatwg-fetch@3.0.0: +whatwg-fetch@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/whatwg-fetch/-/whatwg-fetch-3.0.0.tgz#fc804e458cc460009b1a2b966bc8817d2578aefb" integrity sha512-9GSJUgz1D4MfyKU7KRqwOjXCXTqWdFNvEr7eUBYchQiVc744mqK/MzXPNR2WsPkmkOa4ywfg8C2n8h+13Bey1Q== @@ -12181,19 +12602,14 @@ whatwg-url@^6.4.1: webidl-conversions "^4.0.2" whatwg-url@^7.0.0: - version "7.0.0" - resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-7.0.0.tgz#fde926fa54a599f3adf82dff25a9f7be02dc6edd" - integrity sha512-37GeVSIJ3kn1JgKyjiYNmSLP1yzbpb29jdmwBSgkD9h40/hyrR/OifpVUndji3tmwGgD8qpw7iQu3RSbCrBpsQ== + version "7.1.0" + resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-7.1.0.tgz#c2c492f1eca612988efd3d2266be1b9fc6170d06" + integrity sha512-WUu7Rg1DroM7oQvGWfOiAK21n74Gg+T4elXEQYkOhtyLeWiJFoOGLXPKI/9gzIie9CtwVLm8wtw6YJdKyxSjeg== dependencies: lodash.sortby "^4.7.0" tr46 "^1.0.1" webidl-conversions "^4.0.2" -which-module@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/which-module/-/which-module-1.0.0.tgz#bba63ca861948994ff307736089e3b96026c2a4f" - integrity sha1-u6Y8qGGUiZT/MHc2CJ47lgJsKk8= - which-module@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/which-module/-/which-module-2.0.0.tgz#d9ef07dce77b9902b8a3a8fa4b31c3e3f7e6e87a" @@ -12243,15 +12659,10 @@ winston@*, winston@^3.0.0, winston@^3.2.1: triple-beam "^1.3.0" winston-transport "^4.3.0" -wordwrap@~0.0.2: - version "0.0.3" - resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-0.0.3.tgz#a3d5da6cd5c0bc0008d37234bbaf1bed63059107" - integrity sha1-o9XabNXAvAAI03I0u68b7WMFkQc= - -wordwrap@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/wordwrap/-/wordwrap-1.0.0.tgz#27584810891456a4171c8d0226441ade90cbcaeb" - integrity sha1-J1hIEIkUVqQXHI0CJkQa3pDLyus= +word-wrap@~1.2.3: + version "1.2.3" + resolved "https://registry.yarnpkg.com/word-wrap/-/word-wrap-1.2.3.tgz#610636f6b1f703891bd34771ccb17fb93b47079c" + integrity sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ== workbox-background-sync@^4.3.1: version "4.3.1" @@ -12443,9 +12854,9 @@ write-file-atomic@^2.0.0: signal-exit "^3.0.2" write-file-atomic@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-3.0.1.tgz#558328352e673b5bb192cf86500d60b230667d4b" - integrity sha512-JPStrIyyVJ6oCSz/691fAjFtefZ6q+fP6tm+OS4Qw6o+TGQxNp1ziY2PgS+X/m0V8OWhZiO/m4xSj+Pr4RrZvw== + version "3.0.3" + resolved "https://registry.yarnpkg.com/write-file-atomic/-/write-file-atomic-3.0.3.tgz#56bd5c5a5c70481cd19c571bd39ab965a5de56e8" + integrity sha512-AvHcyZ5JnSfq3ioSyjrBkH9yW4m7Ayk8/9My/DD9onKeu/94fwrMocemO2QAJFAlnnDN+ZDS+ZjAR5ua1/PV/Q== dependencies: imurmurhash "^0.1.4" is-typedarray "^1.0.0" @@ -12510,11 +12921,6 @@ xtend@^4.0.0, xtend@^4.0.1, xtend@~4.0.1: resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== -y18n@^3.2.1: - version "3.2.1" - resolved "https://registry.yarnpkg.com/y18n/-/y18n-3.2.1.tgz#6d15fba884c08679c0d77e88e7759e811e07fa41" - integrity sha1-bRX7qITAhnnA136I53WegR4H+kE= - "y18n@^3.2.1 || ^4.0.0", y18n@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/y18n/-/y18n-4.0.0.tgz#95ef94f85ecc81d007c264e190a120f0a3c8566b" @@ -12525,11 +12931,16 @@ yallist@^2.1.2: resolved "https://registry.yarnpkg.com/yallist/-/yallist-2.1.2.tgz#1c11f9218f076089a47dd512f93c6699a6a81d52" integrity sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI= -yallist@^3.0.0, yallist@^3.0.2, yallist@^3.0.3: +yallist@^3.0.2: version "3.1.1" resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.1.1.tgz#dbb7daf9bfd8bac9ab45ebf602b8cbad0d5d08fd" integrity sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g== +yaml@^1.7.2: + version "1.10.0" + resolved "https://registry.yarnpkg.com/yaml/-/yaml-1.10.0.tgz#3b593add944876077d4d683fee01081bd9fff31e" + integrity sha512-yr2icI4glYaNG+KWONODapy2/jDdMSDnrONSjblABjD9B4Z5LgiircSt8m8sRZFNi08kG9Sm0uSHtEmP3zaEGg== + yamljs@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/yamljs/-/yamljs-0.3.0.tgz#dc060bf267447b39f7304e9b2bfbe8b5a7ddb03b" @@ -12545,21 +12956,14 @@ yargs-parser@10.x, yargs-parser@^10.1.0: dependencies: camelcase "^4.1.0" -yargs-parser@^13.1.1: - version "13.1.1" - resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-13.1.1.tgz#d26058532aa06d365fe091f6a1fc06b2f7e5eca0" - integrity sha512-oVAVsHz6uFrg3XQheFII8ESO2ssAf9luWuAd6Wexsu4F3OtIW0o8IribPXYrD4WC24LWtPrJlGy87y5udK+dxQ== +yargs-parser@^13.1.2: + version "13.1.2" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-13.1.2.tgz#130f09702ebaeef2650d54ce6e3e5706f7a4fb38" + integrity sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg== dependencies: camelcase "^5.0.0" decamelize "^1.2.0" -yargs-parser@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-5.0.0.tgz#275ecf0d7ffe05c77e64e7c86e4cd94bf0e1228a" - integrity sha1-J17PDX/+Bcd+ZOfIbkzZS/DhIoo= - dependencies: - camelcase "^3.0.0" - yargs@12.0.2: version "12.0.2" resolved "https://registry.yarnpkg.com/yargs/-/yargs-12.0.2.tgz#fe58234369392af33ecbef53819171eff0f5aadc" @@ -12578,10 +12982,10 @@ yargs@12.0.2: y18n "^3.2.1 || ^4.0.0" yargs-parser "^10.1.0" -yargs@^13.3.0: - version "13.3.0" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-13.3.0.tgz#4c657a55e07e5f2cf947f8a366567c04a0dedc83" - integrity sha512-2eehun/8ALW8TLoIl7MVaRUrg+yCnenu8B4kBlRxj3GJGDKU1Og7sMXPNm1BYyM1DOJmTZ4YeN/Nwxv+8XJsUA== +yargs@^13.3.0, yargs@^13.3.2: + version "13.3.2" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-13.3.2.tgz#ad7ffefec1aa59565ac915f82dccb38a9c31a2dd" + integrity sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw== dependencies: cliui "^5.0.0" find-up "^3.0.0" @@ -12592,35 +12996,17 @@ yargs@^13.3.0: string-width "^3.0.0" which-module "^2.0.0" y18n "^4.0.0" - yargs-parser "^13.1.1" + yargs-parser "^13.1.2" -yargs@^7.0.0: - version "7.1.0" - resolved "https://registry.yarnpkg.com/yargs/-/yargs-7.1.0.tgz#6ba318eb16961727f5d284f8ea003e8d6154d0c8" - integrity sha1-a6MY6xaWFyf10oT46gA+jWFU0Mg= +yauzl@^2.10.0: + version "2.10.0" + resolved "https://registry.yarnpkg.com/yauzl/-/yauzl-2.10.0.tgz#c7eb17c93e112cb1086fa6d8e51fb0667b79a5f9" + integrity sha1-x+sXyT4RLLEIb6bY5R+wZnt5pfk= dependencies: - camelcase "^3.0.0" - cliui "^3.2.0" - decamelize "^1.1.1" - get-caller-file "^1.0.1" - os-locale "^1.4.0" - read-pkg-up "^1.0.1" - require-directory "^2.1.1" - require-main-filename "^1.0.1" - set-blocking "^2.0.0" - string-width "^1.0.2" - which-module "^1.0.0" - y18n "^3.2.1" - yargs-parser "^5.0.0" + buffer-crc32 "~0.2.3" + fd-slicer "~1.1.0" -yauzl@2.4.1: - version "2.4.1" - resolved "https://registry.yarnpkg.com/yauzl/-/yauzl-2.4.1.tgz#9528f442dab1b2284e58b4379bb194e22e0c4005" - integrity sha1-lSj0QtqxsihOWLQ3m7GU4i4MQAU= - dependencies: - fd-slicer "~1.0.1" - -yn@^3.0.0: +yn@3.1.1: version "3.1.1" resolved "https://registry.yarnpkg.com/yn/-/yn-3.1.1.tgz#1e87401a09d767c1d5eab26a6e4c185182d2eb50" integrity sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q== diff --git a/vendors/Red-Black_Trees/PolySet.ml b/vendors/Red-Black_Trees/PolySet.ml index ab26380f2..1dc3c12b0 100644 --- a/vendors/Red-Black_Trees/PolySet.ml +++ b/vendors/Red-Black_Trees/PolySet.ml @@ -23,6 +23,17 @@ let find elt set = let find_opt elt set = RB.find_opt ~cmp:set.cmp elt set.tree +let mem elt set = match RB.find_opt ~cmp:set.cmp elt set.tree with None -> false | Some _ -> true + +type 'a added = {set : 'a set; duplicates : 'a list; added : 'a list} + +let add_list elts set = + let aux = fun {set ; duplicates ; added} elt -> + if mem elt set + then {set; duplicates = elt :: duplicates ; added} + else {set = add elt set; duplicates; added = elt :: added} in + List.fold_left aux {set; duplicates=[]; added = []} elts + let elements set = RB.elements set.tree let iter f set = RB.iter f set.tree diff --git a/vendors/Red-Black_Trees/PolySet.mli b/vendors/Red-Black_Trees/PolySet.mli index c8eb4b6d4..589a1374b 100644 --- a/vendors/Red-Black_Trees/PolySet.mli +++ b/vendors/Red-Black_Trees/PolySet.mli @@ -46,10 +46,28 @@ val find : 'elt -> 'elt t -> 'elt val find_opt : 'elt -> 'elt t -> 'elt option +(* The value of the call [mem elt set] is [true] if there exists an + element [y] of set [set] such that [cmp y elt = true], where [cmp] + is the comparison function of [set] (see [create]). If [elt] is not + in [set], then [false] is returned instead. *) + +val mem : 'elt -> 'elt t -> bool + (* The value of the call [element set] is the list of elements of the set [set] in increasing order (with respect to the total comparison function used to create the set). *) +(* The value of the call [add_list element_list set] is a record of + type ['a added]. The elements from the [element_list] are added to + the [set] starting from the head of the list. The elements which + are already part of the [set] at the point at which they are added + are gathered in the [duplicates] list (and the [set] is not updated + for these elements, i.e. it keeps the pre-existing version of the + element). The elements which are not already members of the set are + added to the [set], and gathered in the [added] list. *) +type 'a added = {set : 'a set; duplicates : 'a list; added : 'a list} +val add_list : 'a list -> 'a set -> 'a added + val elements : 'elt t -> 'elt list (* The side-effect of evaluating the call [iter f set] is the diff --git a/vendors/ligo-utils/simple-utils/location.ml b/vendors/ligo-utils/simple-utils/location.ml index 7087fe899..32411d072 100644 --- a/vendors/ligo-utils/simple-utils/location.ml +++ b/vendors/ligo-utils/simple-utils/location.ml @@ -17,6 +17,12 @@ let pp = fun ppf t -> | Virtual s -> Format.fprintf ppf "%s" s | File f -> Format.fprintf ppf "%s" (f#to_string `Point) +let compare a b = match a,b with + | (File a, File b) -> Region.compare a b + | (File _, Virtual _) -> -1 + | (Virtual _, File _) -> 1 + | (Virtual a, Virtual b) -> String.compare a b + let make (start_pos:Lexing.position) (end_pos:Lexing.position) : t = (* TODO: give correct unicode offsets (the random number is here so @@ -35,6 +41,11 @@ type 'a wrap = { location : t ; } +let compare_wrap ~compare:compare_content { wrap_content = wca ; location = la } { wrap_content = wcb ; location = lb } = + match compare_content wca wcb with + | 0 -> compare la lb + | c -> c + let wrap ?(loc = generated) wrap_content = { wrap_content ; location = loc } let get_location x = x.location let unwrap { wrap_content ; _ } = wrap_content diff --git a/vendors/ligo-utils/simple-utils/region.ml b/vendors/ligo-utils/simple-utils/region.ml index a90c51604..dac76ec93 100644 --- a/vendors/ligo-utils/simple-utils/region.ml +++ b/vendors/ligo-utils/simple-utils/region.ml @@ -136,6 +136,11 @@ let lt r1 r2 = && Pos.lt r1#start r2#start && Pos.lt r1#stop r2#stop +let compare r1 r2 = + if equal r1 r2 then 0 + else if lt r1 r2 then -1 + else 1 + let cover r1 r2 = if r1#is_ghost then r2 diff --git a/vendors/ligo-utils/simple-utils/region.mli b/vendors/ligo-utils/simple-utils/region.mli index 378830350..415dc770d 100644 --- a/vendors/ligo-utils/simple-utils/region.mli +++ b/vendors/ligo-utils/simple-utils/region.mli @@ -135,6 +135,11 @@ val equal : t -> t -> bool [r2]. (See {! Pos.lt}.) *) val lt : t -> t -> bool +(** The call [compare r1 r2] has the value 0 if [equal r1 r2] returns + [true]. Otherwise it returns -1 if [lt r1 r2] returns [true], and 1 + if [lt r1 r2] returns [false]. *) +val compare : t -> t -> int + (** Given two regions [r1] and [r2], we may want the region [cover r1 r2] that covers [r1] and [r2]. We have the property [equal (cover r1 r2) (cover r2 r1)]. (In a sense, it is the maximum region, but diff --git a/vendors/ligo-utils/simple-utils/x_list.ml b/vendors/ligo-utils/simple-utils/x_list.ml index 4b74c0261..38e48ff21 100644 --- a/vendors/ligo-utils/simple-utils/x_list.ml +++ b/vendors/ligo-utils/simple-utils/x_list.ml @@ -178,6 +178,17 @@ let rec assoc_opt ?compare:cmp x = [] -> None | (a,b)::l -> if compare a x = 0 then Some b else assoc_opt ~compare x l +let rec compare ?compare:cmp a b = + let cmp = unopt ~default:Pervasives.compare cmp in + match a,b with + [], [] -> 0 + | [], _::_ -> -1 + | _::_, [] -> 1 + | ha::ta, hb::tb -> + (match cmp ha hb with + 0 -> compare ta tb + | c -> c) + module Ne = struct diff --git a/vendors/ligo-utils/simple-utils/x_string.ml b/vendors/ligo-utils/simple-utils/x_string.ml index f7155375c..0f316ac26 100644 --- a/vendors/ligo-utils/simple-utils/x_string.ml +++ b/vendors/ligo-utils/simple-utils/x_string.ml @@ -6,6 +6,12 @@ let pp ppf = function Standard s -> Format.fprintf ppf "%S" s | Verbatim v -> Format.fprintf ppf "{|%s|}" v +let compare ?(compare=compare) a b = match a,b with + (Standard a, Standard b) -> compare a b + | (Standard _, Verbatim _) -> -1 + | (Verbatim _, Standard _) -> 1 + | (Verbatim a, Verbatim b) -> compare a b + let extract = function Standard s -> s | Verbatim v -> v diff --git a/vendors/ligo-utils/simple-utils/x_string.mli b/vendors/ligo-utils/simple-utils/x_string.mli index 5ded5f73f..14b8159f8 100644 --- a/vendors/ligo-utils/simple-utils/x_string.mli +++ b/vendors/ligo-utils/simple-utils/x_string.mli @@ -7,5 +7,6 @@ type t = Standard of string | Verbatim of string +val compare : ?compare:(string->string->int) -> t -> t -> int val pp : Format.formatter -> t -> unit val extract : t -> string