package merlin-lib

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type

Helpers to produce Parsetree fragments

Warning This module is unstable and part of compiler-libs.

type 'a with_loc = 'a Location.loc
type loc = Location.t
type str = string with_loc
type str_opt = string option with_loc
type attrs = Parsetree.attribute list
val const_string : string -> Parsetree.constant

Default locations

val default_loc : loc Stdlib.ref

Default value for all optional location arguments.

val with_default_loc : loc -> (unit -> 'a) -> 'a

Set the default_loc within the scope of the execution of the provided function.

Constants

module Const : sig ... end
module Attr : sig ... end

Core language

module Typ : sig ... end

Type expressions

module Pat : sig ... end

Patterns

module Exp : sig ... end

Expressions

module Val : sig ... end

Value declarations

module Type : sig ... end

Type declarations

module Te : sig ... end

Type extensions

Module language

module Mty : sig ... end

Module type expressions

module Mod : sig ... end

Module expressions

module Sig : sig ... end

Signature items

module Str : sig ... end

Structure items

module Md : sig ... end

Module declarations

module Ms : sig ... end

Module substitutions

module Mtd : sig ... end

Module type declarations

module Mb : sig ... end

Module bindings

module Opn : sig ... end

Opens

module Incl : sig ... end

Includes

module Vb : sig ... end

Value bindings

Class language

module Cty : sig ... end

Class type expressions

module Ctf : sig ... end

Class type fields

module Cl : sig ... end

Class expressions

module Cf : sig ... end

Class fields

module Ci : sig ... end

Classes

module Csig : sig ... end

Class signatures

module Cstr : sig ... end

Class structures

module Rf : sig ... end

Row fields

module Of : sig ... end

Object fields

merlin: refactored out of Parser

type let_binding = {
  1. lb_pattern : Parsetree.pattern;
  2. lb_expression : Parsetree.expression;
  3. lb_is_pun : bool;
  4. lb_attributes : Parsetree.attributes;
  5. lb_docs : Docstrings.docs Stdlib.Lazy.t;
  6. lb_text : Docstrings.text Stdlib.Lazy.t;
  7. lb_loc : Location.t;
}
type let_bindings = {
  1. lbs_bindings : let_binding list;
  2. lbs_rec : Asttypes.rec_flag;
  3. lbs_extension : string Asttypes.loc option;
}
val no_label : Asttypes.arg_label
val extract_str_payload : Parsetree.payload -> (string * Location.t) option
val hole_txt : string
OCaml

Innovation. Community. Security.