package saltoIL

  1. Overview
  2. Docs

Module Salto_id.IdSource

Sourcetype t

Type of expression and pattern identifiers used by the analyzer, which can thus be (potentially pathed) identifiers recovered from the typed OCaml AST, or identifiers internally generated by the analyzer

Sourceval equal : t -> t -> bool

Equality test between identifiers

Sourceval compare : t -> t -> int

Total ordering over identifiers. compare id1 id2 return the result of the comparison between id1 and id2 if they are comparible, if not an arbitrary ordering on the different type of identifiers

Sourceval from_ident : Ident.t -> t

Constructor of identifier, without known name, recovered from the typed OCaml AST

Sourceval from_named_id : string Location.loc -> Ident.t -> t

Constructor of identifier, with a known name, recovered from the typed OCaml AST

Sourceval internal : string -> t

Constructor of internally generated identifiers, which uniqueness are guaranteed by an incrementing counter

Sourceval name : t -> string

name id return the name of the identifier id

Sourceval name_loc : t -> string Location.loc

name_loc id return the name of the identifier id

Sourceval lident_loc : t -> Longident.t Location.loc

lident_loc id return the identifier id as a longident

Sourceval ocaml_ident : t -> Ident.t

ocaml_ident id return the original identifier of id from the typed AST. Fails on internal indentifiers.

Sourceval is_internal : t -> bool

is_internal id checks if the identifier id is internal to the Salto AST

Sourceval is_persistent : t -> bool

is_persistent id checks if id is a persistent identifier

Sourceval pp : Format.formatter -> t -> unit

Formatter of Salto identifiers

fold function for hash computation on salto identifiers