diff options
author | Son Ho | 2023-11-21 10:22:51 +0100 |
---|---|---|
committer | Son Ho | 2023-11-21 10:22:51 +0100 |
commit | dcd34ceed0c52738b1bb8139e7130db9bad1a774 (patch) | |
tree | 50dae3ab70a5b22c5751d891893aff87e734d724 /compiler/ExtractName.ml | |
parent | db58a6bcc95c66febc70e90af928feae7dddf56c (diff) |
Fix issues with the builtin names
Diffstat (limited to '')
-rw-r--r-- | compiler/ExtractName.ml | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/compiler/ExtractName.ml b/compiler/ExtractName.ml index 4f5ca0d1..6d50ed73 100644 --- a/compiler/ExtractName.ml +++ b/compiler/ExtractName.ml @@ -35,7 +35,7 @@ end *) let pattern_to_extract_name (is_trait_impl : bool) (name : pattern) : string list = - let c = { tgt_kind = TkName } in + let c = { tgt = TkName } in let is_var (g : generic_arg) : bool = match g with | GExpr (EVar _) -> true @@ -83,11 +83,13 @@ let pattern_to_trait_impl_extract_name = pattern_to_extract_name true names we derive from the patterns (for the builtin definitions) are consistent with the extraction names we derive from the Rust names *) let name_to_simple_name (ctx : ctx) (n : Types.name) : string list = - pattern_to_extract_name false (name_to_pattern ctx n) + let c : to_pat_config = { tgt = TkName } in + pattern_to_extract_name false (name_to_pattern ctx c n) let name_with_generics_to_simple_name (ctx : ctx) (n : Types.name) (p : Types.generic_params) (g : Types.generic_args) : string list = - pattern_to_extract_name true (name_with_generics_to_pattern ctx n p g) + let c : to_pat_config = { tgt = TkName } in + pattern_to_extract_name true (name_with_generics_to_pattern ctx c n p g) (* (* Prepare a name. |