diff options
author | Son Ho | 2023-11-15 22:03:21 +0100 |
---|---|---|
committer | Son Ho | 2023-11-15 22:03:21 +0100 |
commit | 21e3b719f2338f4d4a65c91edc0eb83d0b22393e (patch) | |
tree | d3cf2a846a2c5a767090dc0c418026ea8a239cad /compiler/ExtractBuiltin.ml | |
parent | 4192258b7e5e3ed034ac16a326c455fe75fe6df4 (diff) |
Start updating the name type, cleanup the names and the module abbrevs
Diffstat (limited to 'compiler/ExtractBuiltin.ml')
-rw-r--r-- | compiler/ExtractBuiltin.ml | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/compiler/ExtractBuiltin.ml b/compiler/ExtractBuiltin.ml index a54ab604..db942ff0 100644 --- a/compiler/ExtractBuiltin.ml +++ b/compiler/ExtractBuiltin.ml @@ -4,14 +4,21 @@ TODO: there misses trait **implementations** *) -open Names open Config +open Types type simple_name = string list [@@deriving show, ord] +(* TODO: update *) let name_to_simple_name (s : name) : simple_name = - (* We simply ignore the disambiguators *) - List.filter_map (function Ident id -> Some id | Disambiguator _ -> None) s + (* We simply ignore the disambiguators - TODO: update *) + List.map + (function + | PeIdent (id, _) -> id + | PeImpl i -> + (* TODO *) + show_impl_elem i) + s (** Small helper which cuts a string at the occurrences of "::" *) let string_to_simple_name (s : string) : simple_name = |